@@ -33,16 +33,16 @@ CREATE TABLE `classicmodels`.`Customer` (
33
33
` contactFirstName` varchar (50 ) NOT NULL ,
34
34
` phone` varchar (50 ) NOT NULL ,
35
35
` addressLine1` varchar (50 ) NOT NULL ,
36
- ` addressLine2` varchar (50 ) DEFAULT NULL ,
36
+ ` addressLine2` varchar (50 ),
37
37
` city` varchar (50 ) NOT NULL ,
38
- ` state` varchar (50 ) DEFAULT NULL ,
39
- ` postalCode` varchar (15 ) DEFAULT NULL ,
38
+ ` state` varchar (50 ),
39
+ ` postalCode` varchar (15 ),
40
40
` country` varchar (50 ) NOT NULL ,
41
- ` salesRepEmployeeNumber` int (11 ) DEFAULT NULL ,
42
- ` creditLimit` double DEFAULT NULL ,
41
+ ` salesRepEmployeeNumber` int (11 ),
42
+ ` creditLimit` double,
43
43
` missingProductCode` varchar (50 ) NULL ,
44
44
PRIMARY KEY (` customerNumber` )
45
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
45
+ );
46
46
INSERT INTO ` classicmodels` .` Customer` (` customerNumber` ,` customerName` ,` contactLastName` ,` contactFirstName` ,` phone` ,` addressLine1` ,` addressLine2` ,` city` ,` state` ,` postalCode` ,` country` ,` salesRepEmployeeNumber` ,` creditLimit` ) VALUES
47
47
(103 ,' Atelier graphique' ,' Schmitt' ,' Carine ' ,' 40.32.2555' ,' 54, rue Royale' ,NULL ,' Nantes' ,NULL ,' 44000' ,' France' ,1370 ,21000 ),
48
48
(112 ,' Signal Gift Stores' ,' King' ,' Sue' ,' 7025551838' ,' 8489 Strong St.' ,NULL ,' Las Vegas' ,' NV' ,' 83030' ,' USA' ,1166 ,71800 ),
@@ -168,7 +168,7 @@ INSERT INTO `classicmodels`.`Customer` (`customerNumber`,`customerName`,`contact
168
168
(496 ,' Kellys Gift Shop' ,' Snowden' ,' Tony' ,' +64 9 5555500' ,' Arenales 1938 3A' ,NULL ,' Auckland ' ,NULL ,' ' ,' New Zealand' ,1612 ,110000 );
169
169
INSERT INTO ` classicmodels` .` Customer` (` customerNumber` ,` customerName` ,` contactLastName` ,` contactFirstName` ,` phone` ,` addressLine1` ,` addressLine2` ,` city` ,` state` ,` postalCode` ,` country` ,` salesRepEmployeeNumber` ,` creditLimit` , ` missingProductCode` ) VALUES
170
170
(500 ,' Customer with valid product' ,' Schmitt' ,' Carine ' ,' 40.32.2555' ,' 54, rue Royale' ,NULL ,' Nantes' ,NULL ,' 44000' ,' France' ,1370 ,21000 , ' S10_1678' ),
171
- (501 ,' Customer with invalid product' ,' Schmitt' ,' Carine ' ,' 40.32.2555' ,' 54, rue Royale' ,NULL ,' Nantes' ,NULL ,' 44000' ,' France' ,1370 ,21000 , ' X10_1678' ),
171
+ (501 ,' Customer with invalid product' ,' Schmitt' ,' Carine ' ,' 40.32.2555' ,' 54, rue Royale' ,NULL ,' Nantes' ,NULL ,' 44000' ,' France' ,1370 ,21000 , ' X10_1678' );
172
172
173
173
DROP TABLE IF EXISTS ` classicmodels` .` Employee` ;
174
174
CREATE TABLE `classicmodels `.` Employee` (
@@ -178,10 +178,10 @@ CREATE TABLE `classicmodels`.`Employee` (
178
178
` extension` varchar (10 ) NOT NULL ,
179
179
` email` varchar (100 ) NOT NULL ,
180
180
` officeCode` varchar (50 ) NOT NULL ,
181
- ` reportsTo` int (11 ) DEFAULT NULL ,
181
+ ` reportsTo` int (11 ),
182
182
` jobTitle` varchar (50 ) NOT NULL ,
183
183
PRIMARY KEY (` employeeNumber` )
184
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
184
+ );
185
185
INSERT INTO ` classicmodels` .` Employee` (` employeeNumber` ,` lastName` ,` firstName` ,` extension` ,` email` ,` officeCode` ,` reportsTo` ,` jobTitle` ) VALUES
186
186
(1002 ,' Murphy' ,' Diane' ,' x5800' ,' dmurphy@classicmodelcars.com' ,' 1' ,NULL ,' President' ),
187
187
(1056 ,' Patterson' ,' Mary' ,' x4611' ,' mpatterso@classicmodelcars.com' ,' 1' ,1002 ,' VP Sales' ),
@@ -213,13 +213,13 @@ CREATE TABLE `classicmodels`.`Office` (
213
213
` city` varchar (50 ) NOT NULL ,
214
214
` phone` varchar (50 ) NOT NULL ,
215
215
` addressLine1` varchar (50 ) NOT NULL ,
216
- ` addressLine2` varchar (50 ) DEFAULT NULL ,
217
- ` state` varchar (50 ) DEFAULT NULL ,
216
+ ` addressLine2` varchar (50 ),
217
+ ` state` varchar (50 ),
218
218
` country` varchar (50 ) NOT NULL ,
219
219
` postalCode` varchar (10 ) NOT NULL ,
220
220
` territory` varchar (10 ) NOT NULL ,
221
221
PRIMARY KEY (` officeCode` )
222
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
222
+ );
223
223
INSERT INTO ` classicmodels` .` Office` (` officeCode` ,` city` ,` phone` ,` addressLine1` ,` addressLine2` ,` state` ,` country` ,` postalCode` ,` territory` ) VALUES
224
224
(' 1' ,' San Francisco' ,' +1 650 219 4782' ,' 100 Market Street' ,' Suite 300' ,' CA' ,' USA' ,' 94080' ,' NA' ),
225
225
(' 2' ,' Boston' ,' +1 215 837 0825' ,' 1550 Court Place' ,' Suite 102' ,' MA' ,' USA' ,' 02107' ,' NA' ),
@@ -234,12 +234,12 @@ CREATE TABLE `classicmodels`.`Order` (
234
234
` orderNumber` int (11 ) NOT NULL ,
235
235
` orderDate` datetime NOT NULL ,
236
236
` requiredDate` datetime NOT NULL ,
237
- ` shippedDate` datetime DEFAULT NULL ,
237
+ ` shippedDate` datetime,
238
238
` status` varchar (15 ) NOT NULL ,
239
239
` comments` text ,
240
240
` customerNumber` int (11 ) NOT NULL ,
241
241
PRIMARY KEY (` orderNumber` )
242
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
242
+ );
243
243
INSERT INTO ` classicmodels` .` Order` (` orderNumber` ,` orderDate` ,` requiredDate` ,` shippedDate` ,` status` ,` comments` ,` customerNumber` ) VALUES
244
244
(10100 ,' 2003-01-06 00:00:00' ,' 2003-01-13 00:00:00' ,' 2003-01-10 00:00:00' ,' Shipped' ,NULL ,363 ),
245
245
(10101 ,' 2003-01-09 00:00:00' ,' 2003-01-18 00:00:00' ,' 2003-01-11 00:00:00' ,' Shipped' ,' Check on availability.' ,128 ),
@@ -576,7 +576,7 @@ CREATE TABLE `classicmodels`.`OrderDetail` (
576
576
` priceEach` double NOT NULL ,
577
577
` orderLineNumber` smallint (6 ) NOT NULL ,
578
578
PRIMARY KEY (` orderNumber` ,` productCode` )
579
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
579
+ );
580
580
INSERT INTO ` classicmodels` .` OrderDetail` (` orderNumber` ,` productCode` ,` quantityOrdered` ,` priceEach` ,` orderLineNumber` ) VALUES
581
581
(10100 ,' S18_1749' ,30 ,171 .7 ,3 ),
582
582
(10100 ,' S18_2248' ,50 ,67 .8 ,2 ),
@@ -3583,7 +3583,7 @@ CREATE TABLE `classicmodels`.`Payment` (
3583
3583
` paymentDate` datetime NOT NULL ,
3584
3584
` amount` double NOT NULL ,
3585
3585
PRIMARY KEY (` customerNumber` ,` checkNumber` )
3586
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
3586
+ );
3587
3587
INSERT INTO ` classicmodels` .` Payment` (` customerNumber` ,` checkNumber` ,` paymentDate` ,` amount` ) VALUES
3588
3588
(103 ,' HQ336336' ,' 2004-10-19 00:00:00' ,5307 .98 ),
3589
3589
(103 ,' JM555205' ,' 2003-06-05 00:00:00' ,16560 .3 ),
@@ -3870,7 +3870,7 @@ CREATE TABLE `classicmodels`.`Product` (
3870
3870
` buyPrice` double NOT NULL ,
3871
3871
` MSRP` double NOT NULL ,
3872
3872
PRIMARY KEY (` productCode` )
3873
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
3873
+ );
3874
3874
INSERT INTO ` classicmodels` .` Product` (` productCode` ,` productName` ,` productLine` ,` productScale` ,` productVendor` ,` productDescription` ,` quantityInStock` ,` buyPrice` ,` MSRP` ) VALUES
3875
3875
(' S10_1678' ,' 1969 Harley Davidson Ultimate Chopper' ,' Motorcycles' ,' 1:10' ,' Min Lin Diecast' ,' This replica features working kickstand, front suspension, gear-shift lever, footbrake lever, drive chain, wheels and steering. All parts are particularly delicate due to their precise scale and require special care and attention.' ,7933 ,48 .81 ,95 .7 ),
3876
3876
(' S10_1949' ,' 1952 Alpine Renault 1300' ,' Classic Cars' ,' 1:10' ,' Classic Metal Creations' ,' Turnable front wheels; steering function; detailed interior; detailed engine; opening hood; opening trunk; opening doors; and detailed chassis.' ,7305 ,98 .58 ,214 .3 ),
@@ -3989,7 +3989,7 @@ CREATE TABLE `classicmodels`.`Contrato` (
3989
3989
` id` numeric (10 ) NOT NULL ,
3990
3990
` numero_contrato` varchar (50 ) NOT NULL ,
3991
3991
PRIMARY KEY (` id` )
3992
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
3992
+ );
3993
3993
INSERT INTO ` classicmodels` .` Contrato` (` id` ,` numero_contrato` ) VALUES
3994
3994
(1 , ' 100001-9' );
3995
3995
@@ -3999,7 +3999,7 @@ CREATE TABLE `classicmodels`.`Parcela` (
3999
3999
` numero_parcela` numeric (10 ) NOT NULL ,
4000
4000
` contrato_id` numeric (10 ) NOT NULL ,
4001
4001
PRIMARY KEY (` id` )
4002
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
4002
+ );
4003
4003
INSERT INTO ` classicmodels` .` Parcela` (` id` ,` numero_parcela` ,` contrato_id` ) VALUES
4004
4004
(1 , 1 , 1 );
4005
4005
@@ -4010,13 +4010,11 @@ CREATE TABLE `classicmodels`.`Liquidacao` (
4010
4010
` contrato_id` numeric (10 ) NOT NULL ,
4011
4011
` parcela_id` numeric (10 ) NULL ,
4012
4012
PRIMARY KEY (` id` )
4013
- ) DEFAULT CHARSET = utf8 COLLATE = utf8_unicode_ci ;
4013
+ );
4014
4014
INSERT INTO ` classicmodels` .` Liquidacao` (` id` ,` valor_total` ,` contrato_id` , ` parcela_id` ) VALUES
4015
4015
(1 , 10000 , 1 , 1 );
4016
4016
4017
4017
4018
-
4019
-
4020
4018
-- Return to H2 regular mode
4021
4019
SET MODE REGULAR;
4022
4020
0 commit comments