-- https://www.phpmyadmin.net/
--
-- Gép: 127.0.0.1
-- Létrehozás ideje: 2022. Aug 28. 20:31
-- Kiszolgáló verziója: 10.4.24-MariaDB
-- PHP verzió: 8.1.6

START TRANSACTION;



--
-- Adatbázis: `entertainmentagencyexample`
--

DELIMITER $$
--
-- Eljárások
--
CREATE DEFINER=`root`@`localhost` PROCEDURE `CH15_Calculate_Entertainment_ContractPrice` ()   UPDATE    Engagements
SET       ContractPrice = ROUND(1.15 * (DateDiff(EndDate, StartDate) + 1) *
                          (SELECT     EntPricePerDay
                            FROM          Entertainers
                            WHERE      Entertainers.EntertainerID = Engagements.EntertainerID), 0)$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH15_Discount_Good_Customers_October` ()   UPDATE    Engagements
SET       ContractPrice = ROUND(ContractPrice * 0.98, 0)
WHERE     (CustomerID IN
                          (SELECT     Engagements.CustomerID
                            FROM          Engagements
                            WHERE      (Engagements.StartDate <= '10/31/2007') AND (Engagements.EndDate >= '10/1/2007')
                            GROUP BY Engagements.CustomerID
                            HAVING      SUM(Engagements.ContractPrice) > 3000))$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH15_Give_Agents_6Percent_Raise` ()   UPDATE    Agents
SET       Salary = ROUND(Salary * 1.06, 0)$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH15_Reward_Good_Agents` ()   UPDATE    Agents
SET       CommissionRate = CommissionRate + 0.005
WHERE     (AgentID IN
                          (SELECT     AgentID
                            FROM          Engagements
                            GROUP BY AgentID
                            HAVING      SUM(ContractPrice) > 20000))$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH16_Add_Customer` ()   INSERT INTO Customers (CustFirstName, CustLastName, CustStreetAddress, CustCity, CustState, CustZipCode, CustPhoneNumber)
VALUES     ('Kendra', 'Hernandez', '457 211th St NE', 'Bothell', 'WA', '98200', '555-3945')$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH16_Add_Engagement` ()   INSERT INTO Engagements (CustomerID, EntertainerID, StartDate, EndDate, StartTime, StopTime, ContractPrice, AgentID)
SELECT     Customers.CustomerID, Entertainers.EntertainerID, '8/15/2008', '8/16/2008', '19:00:00', '23:00:00', 
                      ROUND(Entertainers.EntPricePerDay * 2 * 1.15, 0) Expr5, Agents.AgentID
FROM         Customers CROSS JOIN
                      Entertainers CROSS JOIN
                      Agents
WHERE     (Customers.CustFirstName = 'Matt') AND (Customers.CustLastName = 'Berg') AND (Entertainers.EntStageName = 'Jazz Persuasion') AND 
                      (Agents.AgtFirstName = 'Karen') AND (Agents.AgtLastName = 'Smith')$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH16_Add_Style` ()   INSERT INTO Musical_Styles (StyleName)
VALUES     ('New Age')$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH16_Archive_Engagements` ()   INSERT INTO Engagements_Archive (EngagementNumber, StartDate, EndDate, StartTime, StopTime, ContractPrice, CustomerID, AgentID, EntertainerID) 
SELECT Engagements.EngagementNumber, Engagements.StartDate, Engagements.EndDate, Engagements.StartTime, Engagements.StopTime, Engagements.ContractPrice, Engagements.CustomerID, Engagements.AgentID, Engagements.EntertainerID
FROM Engagements
WHERE Engagements.EndDate < '01/01/2008'$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH16_Copy_Agent_To_Customer` ()   INSERT INTO Customers (CustFirstName, CustLastName, CustStreetAddress, CustCity, CustState, CustZipCode, CustPhoneNumber)
SELECT     AgtFirstName, AgtLastName, AgtStreetAddress, AgtCity, AgtState, AgtZipCode, AgtPhoneNumber
FROM         Agents
WHERE     (AgtFirstName = 'Marianne') AND (AgtLastName = 'Wier')$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH16_Duplicate_Engagement` ()   INSERT INTO Engagements (StartDate, EndDate, StartTime, StopTime, ContractPrice, CustomerID, AgentID, EntertainerID)
SELECT     '8/1/2008', '8/4/2008', Engagements.StartTime, Engagements.StopTime, Engagements.ContractPrice, 
                      Engagements.CustomerID, Engagements.AgentID, Engagements.EntertainerID
FROM         Customers INNER JOIN
                      Engagements ON Customers.CustomerID = Engagements.CustomerID
WHERE     (Customers.CustFirstName = 'Doris') AND (Customers.CustLastName = 'Hartwig') AND (Engagements.StartDate = '12/1/2007')$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH17_Delete_Customers_Never_Booked` ()   DELETE FROM Customers
WHERE (CustomerID NOT IN
  (SELECT     CustomerID FROM Engagements))$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH17_Delete_Entertainers_Not_Booked1` ()   DELETE FROM Entertainer_Members
WHERE  (EntertainerID NOT IN
  (SELECT     EntertainerID FROM Engagements))$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH17_Delete_Entertainers_Not_Booked2` ()   DELETE FROM Entertainers
WHERE     (EntertainerID NOT IN
  (SELECT     EntertainerID FROM Engagements))$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH17_Delete_Members_Not_In_Group` ()   DELETE FROM Members
WHERE     (MemberID NOT IN
  (SELECT     MemberID FROM Entertainer_Members))$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH17_Delete_Styles_No_Entertainer` ()   DELETE FROM Musical_Styles
WHERE     (StyleID NOT IN
  (SELECT     StyleID FROM Entertainer_Styles))$$

CREATE DEFINER=`root`@`localhost` PROCEDURE `CH17_Remove_Archived_Engagements` ()   DELETE FROM Engagements
WHERE     (EngagementNumber IN
  (SELECT     EngagementNumber FROM Engagements_Archive))$$

DELIMITER ;

-- --------------------------------------------------------

--
-- Tábla szerkezet ehhez a táblához `agents`
--

CREATE TABLE `agents` (
  `AgentID` int(11) NOT NULL,
  `AgtFirstName` varchar(25) CHARACTER SET utf8 DEFAULT NULL,
  `AgtLastName` varchar(25) CHARACTER SET utf8 DEFAULT NULL,
  `AgtStreetAddress` varchar(50) CHARACTER SET utf8 DEFAULT NULL,
  `AgtCity` varchar(30) CHARACTER SET utf8 DEFAULT NULL,
  `AgtState` varchar(2) CHARACTER SET utf8 DEFAULT NULL,
  `AgtZipCode` varchar(10) CHARACTER SET utf8 DEFAULT NULL,
  `AgtPhoneNumber` varchar(15) CHARACTER SET utf8 DEFAULT NULL,
  `DateHired` datetime DEFAULT NULL,
  `Salary` decimal(15,2) DEFAULT NULL,
  `CommissionRate` float DEFAULT NULL
) ENGINE=InnoDB AVG_ROW_LENGTH=1820 DEFAULT CHARSET=latin1;

--
-- A tábla adatainak kiíratása `agents`
--

INSERT INTO `agents` (`AgentID`, `AgtFirstName`, `AgtLastName`, `AgtStreetAddress`, `AgtCity`, `AgtState`, `AgtZipCode`, `AgtPhoneNumber`, `DateHired`, `Salary`, `CommissionRate`) VALUES
(1, 'William', 'Thompson', '122 Spring River Drive', 'Redmond', 'WA', '98053', '555-2681', '1997-05-15 00:00:00', '35000.00', 0.04),
(2, 'Scott', 'Bishop', '66 Spring Valley Drive', 'Seattle', 'WA', '98125', '555-2666', '1998-02-05 00:00:00', '27000.00', 0.04),
(3, 'Carol', 'Viescas', '667 Red River Road', 'Bellevue', 'WA', '98006', '555-2571', '1997-11-19 00:00:00', '30000.00', 0.05),
(4, 'Karen', 'Smith', '30301 - 166th Ave. N.E.', 'Seattle', 'WA', '98125', '555-2551', '1998-03-05 00:00:00', '22000.00', 0.055),
(5, 'Marianne', 'Wier', '908 W. Capital Way', 'Tacoma', 'WA', '98413', '555-2606', '1998-02-02 00:00:00', '24500.00', 0.045),
(6, 'John', 'Kennedy', '16679 NE 41st Court', 'Seattle', 'WA', '98125', '555-2621', '1997-05-15 00:00:00', '33000.00', 0.06),
(7, 'Caleb', 'Viescas', '4501 Wetland Road', 'Redmond', 'WA', '98052', '555-0037', '1998-02-16 00:00:00', '22100.00', 0.035),
(8, 'Maria', 'Patterson', '3445 Cheyenne Road', 'Bellevue', 'WA', '98006', '555-2291', '1997-09-03 00:00:00', '30000.00', 0.04),
(9, 'Daffy', 'Dumbwit', '1234 Main Street', 'Kirkland', 'WA', '98033', '555-1234', '2000-02-05 00:00:00', '50.00', 0.01);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch04_agent_phone_list`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch04_agent_phone_list` (
`AgtLastName` varchar(25)
,`AgtFirstName` varchar(25)
,`AgtPhoneNumber` varchar(15)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch04_engagement_dates`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch04_engagement_dates` (
`StartDate` datetime
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch04_engagement_information`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch04_engagement_information` (
`EngagementNumber` smallint(6)
,`StartDate` datetime
,`EndDate` datetime
,`StartTime` time
,`StopTime` time
,`ContractPrice` decimal(15,2)
,`CustomerID` int(11)
,`AgentID` int(11)
,`EntertainerID` int(11)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch04_entertainer_locations`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch04_entertainer_locations` (
`EntCity` varchar(30)
,`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch04_scheduled_engagements`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch04_scheduled_engagements` (
`StartDate` datetime
,`EngagementNumber` smallint(6)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch05_customers_by_city`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch05_customers_by_city` (
`City` varchar(30)
,`Customer` varchar(52)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch05_engagement_lengths`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch05_engagement_lengths` (
`EngagementNumber` smallint(6)
,`DueToRun` varchar(15)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch05_entertainer_web_sites`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch05_entertainer_web_sites` (
`Entertainer` varchar(50)
,`Drop_By` varchar(60)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch05_first_performance_review`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch05_first_performance_review` (
`Agent` varchar(52)
,`DateHired` datetime
,`FirstReview` bigint(16)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch05_net_amount_per_contract`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch05_net_amount_per_contract` (
`EngagementNumber` smallint(6)
,`ContractPrice` decimal(15,2)
,`OurFee` decimal(18,4)
,`NetAmount` decimal(19,4)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch06_eastside_entertainers`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch06_eastside_entertainers` (
`EntStageName` varchar(50)
,`EntPhoneNumber` varchar(15)
,`EntCity` varchar(30)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch06_fourday_engagements`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch06_fourday_engagements` (
`EngagementNumber` smallint(6)
,`StartDate` datetime
,`EndDate` datetime
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch06_october_2007_engagements`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch06_october_2007_engagements` (
`EngagementNumber` smallint(6)
,`ContractPrice` decimal(15,2)
,`StartDate` datetime
,`EndDate` datetime
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch06_october_dates_between_noon_and_five`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch06_october_dates_between_noon_and_five` (
`EngagementNumber` smallint(6)
,`StartDate` datetime
,`StartTime` time
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch06_single_day_engagements`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch06_single_day_engagements` (
`EngagementNumber` smallint(6)
,`StartDate` datetime
,`EndDate` datetime
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch08_agents_booked_dates`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch08_agents_booked_dates` (
`AgtFullName` varchar(51)
,`StartDate` datetime
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch08_agents_entertainers_same_postal`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch08_agents_entertainers_same_postal` (
`AgtFullName` varchar(51)
,`EntStageName` varchar(50)
,`AgtZipCode` varchar(10)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch08_customers_booked_entertainers`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch08_customers_booked_entertainers` (
`CustFullName` varchar(51)
,`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch08_entertainers_and_contracts`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch08_entertainers_and_contracts` (
`EntStageName` varchar(50)
,`StartDate` datetime
,`EndDate` datetime
,`ContractPrice` decimal(15,2)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch08_entertainers_berg`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch08_entertainers_berg` (
`EntertainerID` int(11)
,`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch08_entertainers_berg_and_hallmark`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch08_entertainers_berg_and_hallmark` (
`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch08_entertainers_for_berg_or_hallmark`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch08_entertainers_for_berg_or_hallmark` (
`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch08_entertainers_hallmark`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch08_entertainers_hallmark` (
`EntertainerID` int(11)
,`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch09_agents_no_contracts`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch09_agents_no_contracts` (
`AgentID` int(11)
,`AgtFirstName` varchar(25)
,`AgtLastName` varchar(25)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch09_all_entertainers_and_any_engagements`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch09_all_entertainers_and_any_engagements` (
`EntertainerID` int(11)
,`EntStageName` varchar(50)
,`EngagementNumber` smallint(6)
,`StartDate` datetime
,`CustomerID` int(11)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch09_all_styles_and_any_customers`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch09_all_styles_and_any_customers` (
`StyleID` smallint(6)
,`StyleName` varchar(75)
,`CustomerID` int(11)
,`CustFirstName` varchar(25)
,`CustLastName` varchar(25)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch09_customers_no_bookings`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch09_customers_no_bookings` (
`CustomerID` int(11)
,`CustFirstName` varchar(25)
,`CustLastName` varchar(25)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch09_entertainers_never_booked`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch09_entertainers_never_booked` (
`EntertainerID` int(11)
,`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch10_agents_union_entertainers`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch10_agents_union_entertainers` (
`Name` varchar(52)
,`Type` varchar(11)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch10_customers_entertainers_contemporary`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch10_customers_entertainers_contemporary` (
`Name` varchar(51)
,`Type` varchar(11)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch10_customers_union_entertainers`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch10_customers_union_entertainers` (
`Name` varchar(52)
,`Type` varchar(11)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch11_bad_agents`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch11_bad_agents` (
`AgentID` int(11)
,`AgtFirstName` varchar(25)
,`AgtLastName` varchar(25)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch11_customers_last_booking`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch11_customers_last_booking` (
`CustFirstName` varchar(25)
,`CustLastName` varchar(25)
,`LastBooking` datetime
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch11_customers_who_like_country`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch11_customers_who_like_country` (
`CustomerID` int(11)
,`CustFirstName` varchar(25)
,`CustLastName` varchar(25)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch11_entertainers_berg_and_hallmark_exists`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch11_entertainers_berg_and_hallmark_exists` (
`EntertainerID` int(11)
,`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch11_entertainers_berg_or_hallmark_some`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch11_entertainers_berg_or_hallmark_some` (
`EntertainerID` int(11)
,`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch11_entertainer_engagement_count`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch11_entertainer_engagement_count` (
`EntStageName` varchar(50)
,`EngageCount` bigint(21)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch12_average_agent_salary`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch12_average_agent_salary` (
`AverageAgentSalary` decimal(19,6)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch12_contract_price_ge_average_contract_price`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch12_contract_price_ge_average_contract_price` (
`EngagementNumber` smallint(6)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch12_earliest_contracts`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch12_earliest_contracts` (
`EngagementNumber` smallint(6)
,`ContractPrice` decimal(15,2)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch12_number_of_bellevue_entertainers`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch12_number_of_bellevue_entertainers` (
`NumberOfEntertainers` bigint(21)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch12_total_booked_value_for_october_2007`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch12_total_booked_value_for_october_2007` (
`TotalBookedValue` decimal(37,2)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch13_agent_sales_and_commissions`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch13_agent_sales_and_commissions` (
`AgtFirstName` varchar(25)
,`AgtLastName` varchar(25)
,`SumOfContractPrice` decimal(37,2)
,`Commission` double
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch13_aggregate_contract_info_by_customer`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch13_aggregate_contract_info_by_customer` (
`CustLastName` varchar(25)
,`CustFirstName` varchar(25)
,`NumContracts` bigint(21)
,`TotPrice` decimal(37,2)
,`MinPrice` decimal(15,2)
,`MaxPrice` decimal(15,2)
,`AvgPrice` decimal(19,6)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch13_aggregate_contract_info_by_entertainer`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch13_aggregate_contract_info_by_entertainer` (
`EntStageName` varchar(50)
,`NumContracts` bigint(21)
,`TotPrice` decimal(37,2)
,`MinPrice` decimal(15,2)
,`MaxPrice` decimal(15,2)
,`AvgPrice` decimal(19,6)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch13_biggest_big_contract`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch13_biggest_big_contract` (
`CustFirstName` varchar(25)
,`CustLastName` varchar(25)
,`StartDate` datetime
,`ContractPrice` decimal(15,2)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch13_customers_last_booking`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch13_customers_last_booking` (
`CustomerFullName` varchar(52)
,`CustomerFullAddress` varchar(97)
,`LatestDate` datetime
,`TotalContractPrice` decimal(37,2)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch13_entertainers_and_contractprices`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch13_entertainers_and_contractprices` (
`EntStageName` varchar(50)
,`ContractPrice` decimal(15,2)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch13_member_pay`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch13_member_pay` (
`EntertainerID` int(11)
,`MbrFirstName` varchar(25)
,`MbrLastName` varchar(25)
,`MemberPay` decimal(41,6)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch14_agents_book_over_3000_12_2007`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch14_agents_book_over_3000_12_2007` (
`AgtFirstName` varchar(25)
,`AgtLastName` varchar(25)
,`TotalBooked` decimal(37,2)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch14_agent_sales_big_commissions`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch14_agent_sales_big_commissions` (
`AgtFirstName` varchar(25)
,`AgtLastName` varchar(25)
,`SumOfContractPrice` decimal(37,2)
,`Commission` double
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch14_entertainers_morethan_2_overlap`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch14_entertainers_morethan_2_overlap` (
`EntertainerID` int(11)
,`EntStageName` varchar(50)
);

-- --------------------------------------------------------

--
-- A nézet helyettes szerkezete `ch14_jazz_entertainers_more_than_3`
-- (Lásd alább az aktuális nézetet)
--
CREATE TABLE `ch14_jazz_entertainers_more_than_3` (
`EntertainerID` int(11)
,`EntStageName` varchar(50)
,`CountOfEntertainerID` bigint(21)
);

-- --------------------------------------------------------

--
-- Tábla szerkezet ehhez a táblához `customers`
--

CREATE TABLE `customers` (
  `CustomerID` int(11) NOT NULL,
  `CustFirstName` varchar(25) CHARACTER SET utf8 DEFAULT NULL,
  `CustLastName` varchar(25) CHARACTER SET utf8 DEFAULT NULL,
  `CustStreetAddress` varchar(50) CHARACTER SET utf8 DEFAULT NULL,
  `CustCity` varchar(30) CHARACTER SET utf8 DEFAULT NULL,
  `CustState` varchar(2) CHARACTER SET utf8 DEFAULT NULL,
  `CustZipCode` varchar(10) CHARACTER SET utf8 DEFAULT NULL,
  `CustPhoneNumber` varchar(15) CHARACTER SET utf8 DEFAULT NULL
) ENGINE=InnoDB AVG_ROW_LENGTH=1092 DEFAULT CHARSET=latin1;

--
-- A tábla adatainak kiíratása `customers`
--

INSERT INTO `customers` (`CustomerID`, `CustFirstName`, `CustLastName`, `CustStreetAddress`, `CustCity`, `CustState`, `CustZipCode`, `CustPhoneNumber`) VALUES
(10001, 'Doris', 'Hartwig', '4726 - 11th Ave. N.E.', 'Seattle', 'WA', '98105', '555-2671'),
(10002, 'Deb', 'Waldal', '908 W. Capital Way', 'Tacoma', 'WA', '98413', '555-2496'),
(10003, 'Peter', 'Brehm', '722 Moss Bay Blvd.', 'Kirkland', 'WA', '98033', '555-2501'),
(10004, 'Dean', 'McCrae', '4110 Old Redmond Rd.', 'Redmond', 'WA', '98052', '555-2506'),
(10005, 'Elizabeth', 'Hallmark', 'Route 2, Box 203B', 'Auburn', 'WA', '98002', '555-2521'),
(10006, 'Matt', 'Berg', '908 W. Capital Way', 'Tacoma', 'WA', '98413', '555-2581'),
(10007, 'Liz', 'Keyser', '13920 S.E. 40th Street', 'Bellevue', 'WA', '98006', '555-2556'),
(10008, 'Darren', 'Gehring', '2601 Seaview Lane', 'Kirkland', 'WA', '98033', '555-2616'),
(10009, 'Sarah', 'Thompson', '2222 Springer Road', 'Bellevue', 'WA', '98006', '555-2626'),
(10010, 'Zachary', 'Ehrlich', '12330 Kingman Drive', 'Kirkland', 'WA', '98033', '555-2721'),
(10011, 'Joyce', 'Bonnicksen', '2424 Thames Drive', 'Bellevue', 'WA', '98006', '555-2726'),
(10012, 'Kerry', 'Patterson', '777 Fenexet Blvd', 'Redmond', 'WA', '98052', '555-0399'),
(10013, 'Estella', 'Pundt', '2500 Rosales Lane', 'Bellevue', 'WA', '98006', '555-9938'),
(10014, 'Mark', 'Rosales', '323 Advocate Lane', 'Bellevue', 'WA', '98006', '555-2286'),
(10015, 'Carol', 'Viescas', '754 Fourth Ave', 'Seattle', 'WA', '98115', '555-2296');

-- --------------------------------------------------------

--
-- Tábla szerkezet ehhez a táblához `engagements`
--

CREATE TABLE `engagements` (
  `EngagementNumber` smallint(6) NOT NULL,
  `StartDate` datetime DEFAULT NULL,
  `EndDate` datetime DEFAULT NULL,
  `StartTime` time DEFAULT NULL,
  `StopTime` time DEFAULT NULL,
  `ContractPrice` decimal(15,2) DEFAULT NULL,
  `CustomerID` int(11) DEFAULT NULL,
  `AgentID` int(11) DEFAULT NULL,
  `EntertainerID` int(11) DEFAULT NULL
) ENGINE=InnoDB AVG_ROW_LENGTH=147 DEFAULT CHARSET=latin1;

--
-- A tábla adatainak kiíratása `engagements`
--

INSERT INTO `engagements` (`EngagementNumber`, `StartDate`, `EndDate`, `StartTime`, `StopTime`, `ContractPrice`, `CustomerID`, `AgentID`, `EntertainerID`) VALUES
(2, '2007-09-01 00:00:00', '2007-09-05 00:00:00', '13:00:00', '15:00:00', '200.00', 10006, 4, 1004),
(3, '2007-09-10 00:00:00', '2007-09-15 00:00:00', '13:00:00', '15:00:00', '590.00', 10001, 3, 1005),
(4, '2007-09-11 00:00:00', '2007-09-17 00:00:00', '20:00:00', '00:00:00', '470.00', 10007, 3, 1004),
(5, '2007-09-11 00:00:00', '2007-09-14 00:00:00', '16:00:00', '19:00:00', '1130.00', 10006, 5, 1003),
(6, '2007-09-10 00:00:00', '2007-09-14 00:00:00', '15:00:00', '21:00:00', '2300.00', 10014, 7, 1008),
(7, '2007-09-11 00:00:00', '2007-09-18 00:00:00', '17:00:00', '20:00:00', '770.00', 10004, 4, 1002),
(8, '2007-09-18 00:00:00', '2007-09-25 00:00:00', '20:00:00', '23:00:00', '1850.00', 10006, 3, 1007),
(9, '2007-09-18 00:00:00', '2007-09-28 00:00:00', '19:00:00', '21:00:00', '1370.00', 10010, 2, 1010),
(10, '2007-09-17 00:00:00', '2007-09-26 00:00:00', '13:00:00', '17:00:00', '3650.00', 10005, 3, 1003),
(11, '2007-09-15 00:00:00', '2007-09-16 00:00:00', '18:00:00', '00:00:00', '950.00', 10005, 4, 1008),
(12, '2007-09-18 00:00:00', '2007-09-26 00:00:00', '18:00:00', '22:00:00', '1670.00', 10014, 8, 1001),
(13, '2007-09-17 00:00:00', '2007-09-20 00:00:00', '20:00:00', '23:00:00', '770.00', 10003, 1, 1006),
(14, '2007-09-24 00:00:00', '2007-09-29 00:00:00', '16:00:00', '22:00:00', '2750.00', 10001, 1, 1008),
(15, '2007-09-24 00:00:00', '2007-09-29 00:00:00', '17:00:00', '19:00:00', '770.00', 10007, 1, 1013),
(16, '2007-10-02 00:00:00', '2007-10-06 00:00:00', '20:00:00', '01:00:00', '1550.00', 10010, 5, 1013),
(17, '2007-09-29 00:00:00', '2007-10-02 00:00:00', '18:00:00', '20:00:00', '530.00', 10002, 8, 1010),
(19, '2007-09-29 00:00:00', '2007-10-05 00:00:00', '20:00:00', '23:00:00', '365.00', 10009, 8, 1004),
(21, '2007-09-30 00:00:00', '2007-10-03 00:00:00', '12:00:00', '16:00:00', '1490.00', 10005, 1, 1003),
(22, '2007-09-30 00:00:00', '2007-10-05 00:00:00', '12:00:00', '15:00:00', '590.00', 10004, 5, 1002),
(23, '2007-09-30 00:00:00', '2007-09-30 00:00:00', '20:00:00', '00:00:00', '290.00', 10012, 4, 1013),
(24, '2007-10-01 00:00:00', '2007-10-07 00:00:00', '12:00:00', '18:00:00', '1940.00', 10001, 4, 1001),
(26, '2007-10-09 00:00:00', '2007-10-14 00:00:00', '17:00:00', '22:00:00', '950.00', 10001, 6, 1002),
(27, '2007-10-07 00:00:00', '2007-10-12 00:00:00', '12:00:00', '16:00:00', '2210.00', 10015, 7, 1003),
(28, '2007-10-06 00:00:00', '2007-10-15 00:00:00', '17:00:00', '22:00:00', '3800.00', 10003, 4, 1007),
(30, '2007-10-06 00:00:00', '2007-10-08 00:00:00', '17:00:00', '22:00:00', '275.00', 10009, 5, 1011),
(31, '2007-10-07 00:00:00', '2007-10-16 00:00:00', '16:00:00', '20:00:00', '2450.00', 10002, 8, 1010),
(32, '2007-10-07 00:00:00', '2007-10-16 00:00:00', '13:00:00', '15:00:00', '1250.00', 10010, 7, 1013),
(34, '2007-10-14 00:00:00', '2007-10-20 00:00:00', '16:00:00', '18:00:00', '680.00', 10004, 8, 1005),
(35, '2007-10-14 00:00:00', '2007-10-15 00:00:00', '19:00:00', '23:00:00', '410.00', 10005, 8, 1001),
(36, '2007-10-13 00:00:00', '2007-10-23 00:00:00', '18:00:00', '22:00:00', '710.00', 10014, 3, 1011),
(37, '2007-10-13 00:00:00', '2007-10-19 00:00:00', '14:00:00', '19:00:00', '2675.00', 10006, 3, 1008),
(38, '2007-10-14 00:00:00', '2007-10-18 00:00:00', '14:00:00', '20:00:00', '1850.00', 10013, 4, 1006),
(41, '2007-10-20 00:00:00', '2007-10-28 00:00:00', '18:00:00', '21:00:00', '860.00', 10013, 3, 1002),
(42, '2007-10-20 00:00:00', '2007-10-26 00:00:00', '17:00:00', '22:00:00', '2150.00', 10002, 1, 1013),
(43, '2007-10-21 00:00:00', '2007-10-21 00:00:00', '14:00:00', '16:00:00', '140.00', 10001, 8, 1001),
(44, '2007-10-22 00:00:00', '2007-10-26 00:00:00', '14:00:00', '19:00:00', '1925.00', 10006, 3, 1008),
(45, '2007-10-21 00:00:00', '2007-10-28 00:00:00', '14:00:00', '18:00:00', '530.00', 10015, 1, 1012),
(46, '2007-10-28 00:00:00', '2007-11-05 00:00:00', '15:00:00', '17:00:00', '1400.00', 10009, 4, 1008),
(48, '2007-11-05 00:00:00', '2007-11-06 00:00:00', '16:00:00', '22:00:00', '950.00', 10002, 1, 1007),
(49, '2007-11-13 00:00:00', '2007-11-19 00:00:00', '12:00:00', '14:00:00', '680.00', 10014, 5, 1001),
(51, '2007-11-13 00:00:00', '2007-11-14 00:00:00', '20:00:00', '01:00:00', '650.00', 10013, 3, 1013),
(52, '2007-11-13 00:00:00', '2007-11-14 00:00:00', '16:00:00', '21:00:00', '650.00', 10010, 3, 1006),
(53, '2007-11-11 00:00:00', '2007-11-12 00:00:00', '17:00:00', '19:00:00', '350.00', 10002, 5, 1007),
(55, '2007-11-19 00:00:00', '2007-11-26 00:00:00', '20:00:00', '02:00:00', '770.00', 10002, 3, 1011),
(56, '2007-11-25 00:00:00', '2007-11-28 00:00:00', '14:00:00', '19:00:00', '1550.00', 10010, 3, 1007),
(58, '2007-12-01 00:00:00', '2007-12-04 00:00:00', '17:00:00', '23:00:00', '770.00', 10001, 2, 1002),
(59, '2007-12-01 00:00:00', '2007-12-04 00:00:00', '15:00:00', '19:00:00', '290.00', 10004, 6, 1012),
(60, '2007-12-02 00:00:00', '2007-12-04 00:00:00', '13:00:00', '17:00:00', '230.00', 10010, 8, 1004),
(61, '2007-12-03 00:00:00', '2007-12-10 00:00:00', '17:00:00', '20:00:00', '410.00', 10015, 8, 1011),
(62, '2007-12-09 00:00:00', '2007-12-10 00:00:00', '20:00:00', '01:00:00', '500.00', 10003, 2, 1005),
(63, '2007-12-18 00:00:00', '2007-12-21 00:00:00', '14:00:00', '16:00:00', '650.00', 10009, 3, 1008),
(64, '2007-12-25 00:00:00', '2008-01-03 00:00:00', '14:00:00', '16:00:00', '1250.00', 10007, 3, 1013),
(66, '2007-12-22 00:00:00', '2007-12-29 00:00:00', '20:00:00', '02:00:00', '2930.00', 10005, 5, 1006),
(68, '2007-12-24 00:00:00', '2007-12-29 00:00:00', '16:00:00', '22:00:00', '1670.00', 10009, 1, 1005),
(69, '2007-12-22 00:00:00', '2007-12-23 00:00:00', '15:00:00', '18:00:00', '500.00', 10004, 7, 1008),
(70, '2007-12-23 00:00:00', '2007-12-26 00:00:00', '13:00:00', '15:00:00', '410.00', 10010, 6, 1001),
(71, '2007-12-22 00:00:00', '2007-12-27 00:00:00', '14:00:00', '17:00:00', '1670.00', 10002, 1, 1003),
(72, '2007-12-22 00:00:00', '2008-01-01 00:00:00', '20:00:00', '01:00:00', '875.00', 10012, 4, 1011),
(73, '2007-12-29 00:00:00', '2008-01-07 00:00:00', '19:00:00', '22:00:00', '1400.00', 10014, 5, 1001),
(74, '2008-01-01 00:00:00', '2008-01-06 00:00:00', '13:00:00', '15:00:00', '590.00', 10004, 1, 1005),
(75, '2008-01-01 00:00:00', '2008-01-11 00:00:00', '17:00:00', '20:00:00', '2525.00', 10001, 7, 1007),
(76, '2007-12-30 00:00:00', '2008-01-03 00:00:00', '16:00:00', '22:00:00', '500.00', 10005, 7, 1012),
(77, '2007-12-30 00:00:00', '2008-01-04 00:00:00', '17:00:00', '20:00:00', '1670.00', 10015, 5, 1003),
(78, '2008-01-01 00:00:00', '2008-01-03 00:00:00', '16:00:00', '20:00:00', '770.00', 10010, 4, 1010),
(79, '2007-12-30 00:00:00', '2008-01-03 00:00:00', '12:00:00', '17:00:00', '1550.00', 10006, 8, 1006),
(80, '2007-12-31 00:00:00', '2008-01-01 00:00:00', '17:00:00', '21:00:00', '650.00', 10002, 5, 1008),
(81, '2008-01-01 00:00:00', '2008-01-09 00:00:00', '13:00:00', '17:00:00', '1130.00', 10013, 4, 1002),
(82, '2008-01-08 00:00:00', '2008-01-09 00:00:00', '20:00:00', '01:00:00', '950.00', 10014, 8, 1003),
(83, '2008-01-06 00:00:00', '2008-01-10 00:00:00', '13:00:00', '15:00:00', '650.00', 10010, 2, 1006),
(84, '2008-01-06 00:00:00', '2008-01-11 00:00:00', '17:00:00', '19:00:00', '230.00', 10007, 3, 1012),
(85, '2008-01-06 00:00:00', '2008-01-08 00:00:00', '14:00:00', '19:00:00', '1175.00', 10015, 4, 1008),
(87, '2008-01-04 00:00:00', '2008-01-06 00:00:00', '16:00:00', '19:00:00', '275.00', 10007, 6, 1008),
(88, '2008-01-07 00:00:00', '2008-01-17 00:00:00', '12:00:00', '14:00:00', '1370.00', 10004, 8, 1013),
(89, '2008-01-06 00:00:00', '2008-01-07 00:00:00', '14:00:00', '16:00:00', '290.00', 10003, 8, 1010),
(90, '2008-01-08 00:00:00', '2008-01-08 00:00:00', '20:00:00', '02:00:00', '320.00', 10006, 5, 1001),
(91, '2008-01-05 00:00:00', '2008-01-12 00:00:00', '13:00:00', '19:00:00', '770.00', 10009, 3, 1004),
(92, '2008-01-12 00:00:00', '2008-01-16 00:00:00', '19:00:00', '00:00:00', '1925.00', 10012, 6, 1008),
(95, '2008-01-15 00:00:00', '2008-01-18 00:00:00', '20:00:00', '01:00:00', '1550.00', 10010, 6, 1007),
(96, '2008-01-22 00:00:00', '2008-01-31 00:00:00', '15:00:00', '17:00:00', '950.00', 10009, 6, 1005),
(97, '2008-01-19 00:00:00', '2008-01-19 00:00:00', '17:00:00', '21:00:00', '110.00', 10012, 8, 1004),
(98, '2008-01-20 00:00:00', '2008-01-27 00:00:00', '20:00:00', '02:00:00', '2930.00', 10012, 2, 1010),
(99, '2008-01-22 00:00:00', '2008-02-22 00:00:00', '14:00:00', '20:00:00', '14105.00', 10005, 6, 1008),
(100, '2008-01-19 00:00:00', '2008-01-23 00:00:00', '12:00:00', '18:00:00', '1850.00', 10015, 3, 1006),
(101, '2008-01-22 00:00:00', '2008-01-30 00:00:00', '14:00:00', '18:00:00', '1670.00', 10004, 5, 1001),
(102, '2008-01-22 00:00:00', '2008-01-31 00:00:00', '12:00:00', '15:00:00', '2300.00', 10013, 5, 1007),
(103, '2008-01-21 00:00:00', '2008-01-27 00:00:00', '12:00:00', '17:00:00', '575.00', 10010, 4, 1011),
(104, '2008-01-28 00:00:00', '2008-02-01 00:00:00', '13:00:00', '16:00:00', '1400.00', 10010, 6, 1003),
(105, '2008-01-27 00:00:00', '2008-02-01 00:00:00', '12:00:00', '17:00:00', '1850.00', 10002, 4, 1013),
(106, '2008-01-29 00:00:00', '2008-02-01 00:00:00', '15:00:00', '18:00:00', '770.00', 10003, 6, 1006),
(107, '2008-01-29 00:00:00', '2008-01-30 00:00:00', '16:00:00', '21:00:00', '200.00', 10007, 4, 1004),
(108, '2008-02-02 00:00:00', '2008-02-04 00:00:00', '18:00:00', '00:00:00', '320.00', 10004, 5, 1012),
(109, '2008-02-11 00:00:00', '2008-02-15 00:00:00', '13:00:00', '19:00:00', '1850.00', 10014, 5, 1010),
(110, '2008-02-11 00:00:00', '2008-02-19 00:00:00', '15:00:00', '19:00:00', '1670.00', 10006, 8, 1001),
(111, '2008-02-12 00:00:00', '2008-02-14 00:00:00', '15:00:00', '18:00:00', '185.00', 10012, 1, 1004),
(112, '2008-02-19 00:00:00', '2008-02-24 00:00:00', '18:00:00', '22:00:00', '410.00', 10015, 7, 1011),
(114, '2008-02-19 00:00:00', '2008-02-28 00:00:00', '12:00:00', '17:00:00', '1550.00', 10005, 1, 1002),
(115, '2008-02-19 00:00:00', '2008-02-22 00:00:00', '12:00:00', '18:00:00', '1490.00', 10007, 5, 1013),
(116, '2008-02-16 00:00:00', '2008-02-25 00:00:00', '14:00:00', '19:00:00', '800.00', 10003, 6, 1012),
(118, '2008-02-18 00:00:00', '2008-02-18 00:00:00', '19:00:00', '00:00:00', '350.00', 10014, 1, 1010),
(119, '2008-02-19 00:00:00', '2008-02-28 00:00:00', '18:00:00', '21:00:00', '500.00', 10012, 2, 1004),
(120, '2008-02-17 00:00:00', '2008-02-20 00:00:00', '20:00:00', '23:00:00', '950.00', 10002, 7, 1008),
(121, '2008-02-16 00:00:00', '2008-02-22 00:00:00', '17:00:00', '23:00:00', '2570.00', 10004, 3, 1006),
(122, '2008-02-24 00:00:00', '2008-02-27 00:00:00', '15:00:00', '19:00:00', '1010.00', 10014, 5, 1010),
(123, '2008-02-25 00:00:00', '2008-02-28 00:00:00', '16:00:00', '20:00:00', '770.00', 10013, 1, 1001),
(124, '2008-02-23 00:00:00', '2008-03-01 00:00:00', '14:00:00', '17:00:00', '1850.00', 10006, 1, 1008),
(125, '2008-02-23 00:00:00', '2008-02-28 00:00:00', '13:00:00', '15:00:00', '1130.00', 10001, 3, 1003),
(126, '2008-02-24 00:00:00', '2008-03-02 00:00:00', '18:00:00', '20:00:00', '1010.00', 10009, 6, 1006),
(127, '2008-02-24 00:00:00', '2008-02-28 00:00:00', '20:00:00', '22:00:00', '500.00', 10010, 4, 1005),
(128, '2008-02-26 00:00:00', '2008-02-28 00:00:00', '19:00:00', '01:00:00', '320.00', 10003, 4, 1011),
(129, '2008-02-24 00:00:00', '2008-03-04 00:00:00', '17:00:00', '21:00:00', '2450.00', 10004, 5, 1013),
(131, '2008-03-02 00:00:00', '2008-03-11 00:00:00', '15:00:00', '17:00:00', '1850.00', 10014, 1, 1003);

-- --------------------------------------------------------

--
-- Tábla szerkezet ehhez a táblához `entertainers`
--

CREATE TABLE `entertainers` (
  `EntertainerID` int(11) NOT NULL,
  `EntStageName` varchar(50) CHARACTER SET utf8 DEFAULT NULL,
  `EntSSN` varchar(12) CHARACTER SET utf8 DEFAULT NULL,
  `EntStreetAddress` varchar(50) CHARACTER SET utf8 DEFAULT NULL,
  `EntCity` varchar(30) CHARACTER SET utf8 DEFAULT NULL,
  `EntState` varchar(2) CHARACTER SET utf8 DEFAULT NULL,
  `EntZipCode` varchar(10) CHARACTER SET utf8 DEFAULT NULL,
  `EntPhoneNumber` varchar(15) CHARACTER SET utf8 DEFAULT NULL,
  `EntWebPage` varchar(50) CHARACTER SET utf8 DEFAULT NULL,
  `EntEMailAddress` varchar(50) CHARACTER SET utf8 DEFAULT NULL,
  `DateEntered` datetime DEFAULT NULL
) ENGINE=InnoDB AVG_ROW_LENGTH=1260 DEFAULT CHARSET=latin1;

--
-- A tábla adatainak kiíratása `entertainers`
--

INSERT INTO `entertainers` (`EntertainerID`, `EntStageName`, `EntSSN`, `EntStreetAddress`, `EntCity`, `EntState`, `EntZipCode`, `EntPhoneNumber`, `EntWebPage`, `EntEMailAddress`, `DateEntered`) VALUES
(1001, 'Carol Peacock Trio', '888-90-1121', '4110 Old Redmond Rd.', 'Redmond', 'WA', '98052', '555-2691', 'www.cptrio.com', 'carolp@cptrio.com', '1997-05-24 00:00:00'),
(1002, 'Topazz', '888-50-1061', '16 Maple Lane', 'Auburn', 'WA', '98002', '555-2591', 'www.topazz.com', NULL, '1996-02-14 00:00:00'),
(1003, 'JV & the Deep Six', '888-18-1013', '15127 NE 24th, #383', 'Redmond', 'WA', '98052', '555-2511', 'www.jvd6.com', 'jv@myspring.com', '1998-03-18 00:00:00'),
(1004, 'Jim Glynn', '888-26-1025', '13920 S.E. 40th Street', 'Bellevue', 'WA', '98009', '555-2531', NULL, NULL, '1996-04-01 00:00:00'),
(1005, 'Jazz Persuasion', '888-30-1031', '233 West Valley Hwy', 'Bellevue', 'WA', '98005', '555-2541', 'www.jazzper.com', NULL, '1997-05-12 00:00:00'),
(1006, 'Modern Dance', '888-66-1085', 'Route 2, Box 203B', 'Woodinville', 'WA', '98072', '555-2631', 'www.moderndance.com', 'mikeh@moderndance.com', '1995-05-16 00:00:00'),
(1007, 'Coldwater Cattle Company', '888-38-1043', '4726 - 11th Ave. N.E.', 'Seattle', 'WA', '98105', '555-2561', 'www.coldwatercows.com', NULL, '1995-11-30 00:00:00'),
(1008, 'Country Feeling', '888-98-1133', 'PO Box 223311', 'Seattle', 'WA', '98125', '555-2711', NULL, NULL, '1996-02-28 00:00:00'),
(1009, 'Katherine Ehrlich', '888-61-1103', '777 Fenexet Blvd', 'Woodinville', 'WA', '98072', '555-0399', NULL, 'ke@mzo.com', '1998-09-13 00:00:00'),
(1010, 'Saturday Revue', '888-64-1109', '3887 Easy Street'