~drizzle-trunk/drizzle/development

1 by brian
clean slate
1
#
2
# Find string "NOTE NOTE NOTE" in order to find some 'unsure' tests
3
#
4
5
#
6
# Simple select test
7
#
8
9
--disable_warnings
10
drop table if exists t1,t2,t3,t4,t11;
11
# The following may be left from older tests
12
drop table if exists t1_1,t1_2,t9_1,t9_2,t1aa,t2aa;
13
--enable_warnings
14
15
CREATE TABLE t1 (
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
16
  Period int DEFAULT '0' NOT NULL,
17
  Varor_period int DEFAULT '0' NOT NULL
1 by brian
clean slate
18
);
19
20
INSERT INTO t1 VALUES (9410,9412);
21
  
22
select period from t1;
23
select * from t1;
24
select t1.* from t1;
25
26
#
27
# Create test table
28
#
29
30
CREATE TABLE t2 (
31
  auto int not null auto_increment,
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
32
  fld1 int DEFAULT '0' NOT NULL,
33
  companynr int DEFAULT '0' NOT NULL,
1 by brian
clean slate
34
  fld3 char(30) DEFAULT '' NOT NULL,
35
  fld4 char(35) DEFAULT '' NOT NULL,
36
  fld5 char(35) DEFAULT '' NOT NULL,
37
  fld6 char(4) DEFAULT '' NOT NULL,
38
  UNIQUE fld1 (fld1),
39
  KEY fld3 (fld3),
40
  PRIMARY KEY (auto)
41
);  
42
43
#
44
# Populate table
45
#
46
47
--disable_query_log
48
INSERT INTO t2 VALUES (1,000001,00,'Omaha','teethe','neat','');
49
INSERT INTO t2 VALUES (2,011401,37,'breaking','dreaded','Steinberg','W');
50
INSERT INTO t2 VALUES (3,011402,37,'Romans','scholastics','jarring','');
51
INSERT INTO t2 VALUES (4,011403,37,'intercepted','audiology','tinily','');
52
INSERT INTO t2 VALUES (5,011501,37,'bewilderingly','wallet','balled','');
53
INSERT INTO t2 VALUES (6,011701,37,'astound','parters','persist','W');
54
INSERT INTO t2 VALUES (7,011702,37,'admonishing','eschew','attainments','');
55
INSERT INTO t2 VALUES (8,011703,37,'sumac','quitter','fanatic','');
56
INSERT INTO t2 VALUES (9,012001,37,'flanking','neat','measures','FAS');
57
INSERT INTO t2 VALUES (10,012003,37,'combed','Steinberg','rightfulness','');
58
INSERT INTO t2 VALUES (11,012004,37,'subjective','jarring','capably','');
59
INSERT INTO t2 VALUES (12,012005,37,'scatterbrain','tinily','impulsive','');
60
INSERT INTO t2 VALUES (13,012301,37,'Eulerian','balled','starlet','');
61
INSERT INTO t2 VALUES (14,012302,36,'dubbed','persist','terminators','');
62
INSERT INTO t2 VALUES (15,012303,37,'Kane','attainments','untying','');
63
INSERT INTO t2 VALUES (16,012304,37,'overlay','fanatic','announces','FAS');
64
INSERT INTO t2 VALUES (17,012305,37,'perturb','measures','featherweight','FAS');
65
INSERT INTO t2 VALUES (18,012306,37,'goblins','rightfulness','pessimist','FAS');
66
INSERT INTO t2 VALUES (19,012501,37,'annihilates','capably','daughter','');
67
INSERT INTO t2 VALUES (20,012602,37,'Wotan','impulsive','decliner','FAS');
68
INSERT INTO t2 VALUES (21,012603,37,'snatching','starlet','lawgiver','');
69
INSERT INTO t2 VALUES (22,012604,37,'concludes','terminators','stated','');
70
INSERT INTO t2 VALUES (23,012605,37,'laterally','untying','readable','');
71
INSERT INTO t2 VALUES (24,012606,37,'yelped','announces','attrition','');
72
INSERT INTO t2 VALUES (25,012701,37,'grazing','featherweight','cascade','FAS');
73
INSERT INTO t2 VALUES (26,012702,37,'Baird','pessimist','motors','FAS');
74
INSERT INTO t2 VALUES (27,012703,37,'celery','daughter','interrogate','');
75
INSERT INTO t2 VALUES (28,012704,37,'misunderstander','decliner','pests','W');
76
INSERT INTO t2 VALUES (29,013601,37,'handgun','lawgiver','stairway','');
77
INSERT INTO t2 VALUES (30,013602,37,'foldout','stated','dopers','FAS');
78
INSERT INTO t2 VALUES (31,013603,37,'mystic','readable','testicle','W');
79
INSERT INTO t2 VALUES (32,013604,37,'succumbed','attrition','Parsifal','W');
80
INSERT INTO t2 VALUES (33,013605,37,'Nabisco','cascade','leavings','');
81
INSERT INTO t2 VALUES (34,013606,37,'fingerings','motors','postulation','W');
82
INSERT INTO t2 VALUES (35,013607,37,'aging','interrogate','squeaking','');
83
INSERT INTO t2 VALUES (36,013608,37,'afield','pests','contrasted','');
84
INSERT INTO t2 VALUES (37,013609,37,'ammonium','stairway','leftover','');
85
INSERT INTO t2 VALUES (38,013610,37,'boat','dopers','whiteners','');
86
INSERT INTO t2 VALUES (39,013801,37,'intelligibility','testicle','erases','W');
87
INSERT INTO t2 VALUES (40,013802,37,'Augustine','Parsifal','Punjab','W');
88
INSERT INTO t2 VALUES (41,013803,37,'teethe','leavings','Merritt','');
89
INSERT INTO t2 VALUES (42,013804,37,'dreaded','postulation','Quixotism','');
90
INSERT INTO t2 VALUES (43,013901,37,'scholastics','squeaking','sweetish','FAS');
91
INSERT INTO t2 VALUES (44,016001,37,'audiology','contrasted','dogging','FAS');
92
INSERT INTO t2 VALUES (45,016201,37,'wallet','leftover','scornfully','FAS');
93
INSERT INTO t2 VALUES (46,016202,37,'parters','whiteners','bellow','');
94
INSERT INTO t2 VALUES (47,016301,37,'eschew','erases','bills','');
95
INSERT INTO t2 VALUES (48,016302,37,'quitter','Punjab','cupboard','FAS');
96
INSERT INTO t2 VALUES (49,016303,37,'neat','Merritt','sureties','FAS');
97
INSERT INTO t2 VALUES (50,016304,37,'Steinberg','Quixotism','puddings','');
98
INSERT INTO t2 VALUES (51,018001,37,'jarring','sweetish','tapestry','');
99
INSERT INTO t2 VALUES (52,018002,37,'tinily','dogging','fetters','');
100
INSERT INTO t2 VALUES (53,018003,37,'balled','scornfully','bivalves','');
101
INSERT INTO t2 VALUES (54,018004,37,'persist','bellow','incurring','');
102
INSERT INTO t2 VALUES (55,018005,37,'attainments','bills','Adolph','');
103
INSERT INTO t2 VALUES (56,018007,37,'fanatic','cupboard','pithed','');
104
INSERT INTO t2 VALUES (57,018008,37,'measures','sureties','emergency','');
105
INSERT INTO t2 VALUES (58,018009,37,'rightfulness','puddings','Miles','');
106
INSERT INTO t2 VALUES (59,018010,37,'capably','tapestry','trimmings','');
107
INSERT INTO t2 VALUES (60,018012,37,'impulsive','fetters','tragedies','W');
108
INSERT INTO t2 VALUES (61,018013,37,'starlet','bivalves','skulking','W');
109
INSERT INTO t2 VALUES (62,018014,37,'terminators','incurring','flint','');
110
INSERT INTO t2 VALUES (63,018015,37,'untying','Adolph','flopping','W');
111
INSERT INTO t2 VALUES (64,018016,37,'announces','pithed','relaxing','FAS');
112
INSERT INTO t2 VALUES (65,018017,37,'featherweight','emergency','offload','FAS');
113
INSERT INTO t2 VALUES (66,018018,37,'pessimist','Miles','suites','W');
114
INSERT INTO t2 VALUES (67,018019,37,'daughter','trimmings','lists','FAS');
115
INSERT INTO t2 VALUES (68,018020,37,'decliner','tragedies','animized','FAS');
116
INSERT INTO t2 VALUES (69,018021,37,'lawgiver','skulking','multilayer','W');
117
INSERT INTO t2 VALUES (70,018022,37,'stated','flint','standardizes','FAS');
118
INSERT INTO t2 VALUES (71,018023,37,'readable','flopping','Judas','');
119
INSERT INTO t2 VALUES (72,018024,37,'attrition','relaxing','vacuuming','W');
120
INSERT INTO t2 VALUES (73,018025,37,'cascade','offload','dentally','W');
121
INSERT INTO t2 VALUES (74,018026,37,'motors','suites','humanness','W');
122
INSERT INTO t2 VALUES (75,018027,37,'interrogate','lists','inch','W');
123
INSERT INTO t2 VALUES (76,018028,37,'pests','animized','Weissmuller','W');
124
INSERT INTO t2 VALUES (77,018029,37,'stairway','multilayer','irresponsibly','W');
125
INSERT INTO t2 VALUES (78,018030,37,'dopers','standardizes','luckily','FAS');
126
INSERT INTO t2 VALUES (79,018032,37,'testicle','Judas','culled','W');
127
INSERT INTO t2 VALUES (80,018033,37,'Parsifal','vacuuming','medical','FAS');
128
INSERT INTO t2 VALUES (81,018034,37,'leavings','dentally','bloodbath','FAS');
129
INSERT INTO t2 VALUES (82,018035,37,'postulation','humanness','subschema','W');
130
INSERT INTO t2 VALUES (83,018036,37,'squeaking','inch','animals','W');
131
INSERT INTO t2 VALUES (84,018037,37,'contrasted','Weissmuller','Micronesia','');
132
INSERT INTO t2 VALUES (85,018038,37,'leftover','irresponsibly','repetitions','');
133
INSERT INTO t2 VALUES (86,018039,37,'whiteners','luckily','Antares','');
134
INSERT INTO t2 VALUES (87,018040,37,'erases','culled','ventilate','W');
135
INSERT INTO t2 VALUES (88,018041,37,'Punjab','medical','pityingly','');
136
INSERT INTO t2 VALUES (89,018042,37,'Merritt','bloodbath','interdependent','');
137
INSERT INTO t2 VALUES (90,018043,37,'Quixotism','subschema','Graves','FAS');
138
INSERT INTO t2 VALUES (91,018044,37,'sweetish','animals','neonatal','');
139
INSERT INTO t2 VALUES (92,018045,37,'dogging','Micronesia','scribbled','FAS');
140
INSERT INTO t2 VALUES (93,018046,37,'scornfully','repetitions','chafe','W');
141
INSERT INTO t2 VALUES (94,018048,37,'bellow','Antares','honoring','');
142
INSERT INTO t2 VALUES (95,018049,37,'bills','ventilate','realtor','');
143
INSERT INTO t2 VALUES (96,018050,37,'cupboard','pityingly','elite','');
144
INSERT INTO t2 VALUES (97,018051,37,'sureties','interdependent','funereal','');
145
INSERT INTO t2 VALUES (98,018052,37,'puddings','Graves','abrogating','');
146
INSERT INTO t2 VALUES (99,018053,50,'tapestry','neonatal','sorters','');
147
INSERT INTO t2 VALUES (100,018054,37,'fetters','scribbled','Conley','');
148
INSERT INTO t2 VALUES (101,018055,37,'bivalves','chafe','lectured','');
149
INSERT INTO t2 VALUES (102,018056,37,'incurring','honoring','Abraham','');
150
INSERT INTO t2 VALUES (103,018057,37,'Adolph','realtor','Hawaii','W');
151
INSERT INTO t2 VALUES (104,018058,37,'pithed','elite','cage','');
152
INSERT INTO t2 VALUES (105,018059,36,'emergency','funereal','hushes','');
153
INSERT INTO t2 VALUES (106,018060,37,'Miles','abrogating','Simla','');
154
INSERT INTO t2 VALUES (107,018061,37,'trimmings','sorters','reporters','');
155
INSERT INTO t2 VALUES (108,018101,37,'tragedies','Conley','Dutchman','FAS');
156
INSERT INTO t2 VALUES (109,018102,37,'skulking','lectured','descendants','FAS');
157
INSERT INTO t2 VALUES (110,018103,37,'flint','Abraham','groupings','FAS');
158
INSERT INTO t2 VALUES (111,018104,37,'flopping','Hawaii','dissociate','');
159
INSERT INTO t2 VALUES (112,018201,37,'relaxing','cage','coexist','W');
160
INSERT INTO t2 VALUES (113,018202,37,'offload','hushes','Beebe','');
161
INSERT INTO t2 VALUES (114,018402,37,'suites','Simla','Taoism','');
162
INSERT INTO t2 VALUES (115,018403,37,'lists','reporters','Connally','');
163
INSERT INTO t2 VALUES (116,018404,37,'animized','Dutchman','fetched','FAS');
164
INSERT INTO t2 VALUES (117,018405,37,'multilayer','descendants','checkpoints','FAS');
165
INSERT INTO t2 VALUES (118,018406,37,'standardizes','groupings','rusting','');
166
INSERT INTO t2 VALUES (119,018409,37,'Judas','dissociate','galling','');
167
INSERT INTO t2 VALUES (120,018601,37,'vacuuming','coexist','obliterates','');
168
INSERT INTO t2 VALUES (121,018602,37,'dentally','Beebe','traitor','');
169
INSERT INTO t2 VALUES (122,018603,37,'humanness','Taoism','resumes','FAS');
170
INSERT INTO t2 VALUES (123,018801,37,'inch','Connally','analyzable','FAS');
171
INSERT INTO t2 VALUES (124,018802,37,'Weissmuller','fetched','terminator','FAS');
172
INSERT INTO t2 VALUES (125,018803,37,'irresponsibly','checkpoints','gritty','FAS');
173
INSERT INTO t2 VALUES (126,018804,37,'luckily','rusting','firearm','W');
174
INSERT INTO t2 VALUES (127,018805,37,'culled','galling','minima','');
175
INSERT INTO t2 VALUES (128,018806,37,'medical','obliterates','Selfridge','');
176
INSERT INTO t2 VALUES (129,018807,37,'bloodbath','traitor','disable','');
177
INSERT INTO t2 VALUES (130,018808,37,'subschema','resumes','witchcraft','W');
178
INSERT INTO t2 VALUES (131,018809,37,'animals','analyzable','betroth','W');
179
INSERT INTO t2 VALUES (132,018810,37,'Micronesia','terminator','Manhattanize','');
180
INSERT INTO t2 VALUES (133,018811,37,'repetitions','gritty','imprint','');
181
INSERT INTO t2 VALUES (134,018812,37,'Antares','firearm','peeked','');
182
INSERT INTO t2 VALUES (135,019101,37,'ventilate','minima','swelling','');
183
INSERT INTO t2 VALUES (136,019102,37,'pityingly','Selfridge','interrelationships','W');
184
INSERT INTO t2 VALUES (137,019103,37,'interdependent','disable','riser','');
185
INSERT INTO t2 VALUES (138,019201,37,'Graves','witchcraft','Gandhian','W');
186
INSERT INTO t2 VALUES (139,030501,37,'neonatal','betroth','peacock','A');
187
INSERT INTO t2 VALUES (140,030502,50,'scribbled','Manhattanize','bee','A');
188
INSERT INTO t2 VALUES (141,030503,37,'chafe','imprint','kanji','');
189
INSERT INTO t2 VALUES (142,030504,37,'honoring','peeked','dental','');
190
INSERT INTO t2 VALUES (143,031901,37,'realtor','swelling','scarf','FAS');
191
INSERT INTO t2 VALUES (144,036001,37,'elite','interrelationships','chasm','A');
192
INSERT INTO t2 VALUES (145,036002,37,'funereal','riser','insolence','A');
193
INSERT INTO t2 VALUES (146,036004,37,'abrogating','Gandhian','syndicate','');
194
INSERT INTO t2 VALUES (147,036005,37,'sorters','peacock','alike','');
195
INSERT INTO t2 VALUES (148,038001,37,'Conley','bee','imperial','A');
196
INSERT INTO t2 VALUES (149,038002,37,'lectured','kanji','convulsion','A');
197
INSERT INTO t2 VALUES (150,038003,37,'Abraham','dental','railway','A');
198
INSERT INTO t2 VALUES (151,038004,37,'Hawaii','scarf','validate','A');
199
INSERT INTO t2 VALUES (152,038005,37,'cage','chasm','normalizes','A');
200
INSERT INTO t2 VALUES (153,038006,37,'hushes','insolence','comprehensive','');
201
INSERT INTO t2 VALUES (154,038007,37,'Simla','syndicate','chewing','');
202
INSERT INTO t2 VALUES (155,038008,37,'reporters','alike','denizen','');
203
INSERT INTO t2 VALUES (156,038009,37,'Dutchman','imperial','schemer','');
204
INSERT INTO t2 VALUES (157,038010,37,'descendants','convulsion','chronicle','');
205
INSERT INTO t2 VALUES (158,038011,37,'groupings','railway','Kline','');
206
INSERT INTO t2 VALUES (159,038012,37,'dissociate','validate','Anatole','');
207
INSERT INTO t2 VALUES (160,038013,37,'coexist','normalizes','partridges','');
208
INSERT INTO t2 VALUES (161,038014,37,'Beebe','comprehensive','brunch','');
209
INSERT INTO t2 VALUES (162,038015,37,'Taoism','chewing','recruited','');
210
INSERT INTO t2 VALUES (163,038016,37,'Connally','denizen','dimensions','W');
211
INSERT INTO t2 VALUES (164,038017,37,'fetched','schemer','Chicana','W');
212
INSERT INTO t2 VALUES (165,038018,37,'checkpoints','chronicle','announced','');
213
INSERT INTO t2 VALUES (166,038101,37,'rusting','Kline','praised','FAS');
214
INSERT INTO t2 VALUES (167,038102,37,'galling','Anatole','employing','');
215
INSERT INTO t2 VALUES (168,038103,37,'obliterates','partridges','linear','');
216
INSERT INTO t2 VALUES (169,038104,37,'traitor','brunch','quagmire','');
217
INSERT INTO t2 VALUES (170,038201,37,'resumes','recruited','western','A');
218
INSERT INTO t2 VALUES (171,038202,37,'analyzable','dimensions','relishing','');
219
INSERT INTO t2 VALUES (172,038203,37,'terminator','Chicana','serving','A');
220
INSERT INTO t2 VALUES (173,038204,37,'gritty','announced','scheduling','');
221
INSERT INTO t2 VALUES (174,038205,37,'firearm','praised','lore','');
222
INSERT INTO t2 VALUES (175,038206,37,'minima','employing','eventful','');
223
INSERT INTO t2 VALUES (176,038208,37,'Selfridge','linear','arteriole','A');
224
INSERT INTO t2 VALUES (177,042801,37,'disable','quagmire','disentangle','');
225
INSERT INTO t2 VALUES (178,042802,37,'witchcraft','western','cured','A');
226
INSERT INTO t2 VALUES (179,046101,37,'betroth','relishing','Fenton','W');
227
INSERT INTO t2 VALUES (180,048001,37,'Manhattanize','serving','avoidable','A');
228
INSERT INTO t2 VALUES (181,048002,37,'imprint','scheduling','drains','A');
229
INSERT INTO t2 VALUES (182,048003,37,'peeked','lore','detectably','FAS');
230
INSERT INTO t2 VALUES (183,048004,37,'swelling','eventful','husky','');
231
INSERT INTO t2 VALUES (184,048005,37,'interrelationships','arteriole','impelling','');
232
INSERT INTO t2 VALUES (185,048006,37,'riser','disentangle','undoes','');
233
INSERT INTO t2 VALUES (186,048007,37,'Gandhian','cured','evened','');
234
INSERT INTO t2 VALUES (187,048008,37,'peacock','Fenton','squeezes','');
235
INSERT INTO t2 VALUES (188,048101,37,'bee','avoidable','destroyer','FAS');
236
INSERT INTO t2 VALUES (189,048102,37,'kanji','drains','rudeness','');
237
INSERT INTO t2 VALUES (190,048201,37,'dental','detectably','beaner','FAS');
238
INSERT INTO t2 VALUES (191,048202,37,'scarf','husky','boorish','');
239
INSERT INTO t2 VALUES (192,048203,37,'chasm','impelling','Everhart','');
240
INSERT INTO t2 VALUES (193,048204,37,'insolence','undoes','encompass','A');
241
INSERT INTO t2 VALUES (194,048205,37,'syndicate','evened','mushrooms','');
242
INSERT INTO t2 VALUES (195,048301,37,'alike','squeezes','Alison','A');
243
INSERT INTO t2 VALUES (196,048302,37,'imperial','destroyer','externally','FAS');
244
INSERT INTO t2 VALUES (197,048303,37,'convulsion','rudeness','pellagra','');
245
INSERT INTO t2 VALUES (198,048304,37,'railway','beaner','cult','');
246
INSERT INTO t2 VALUES (199,048305,37,'validate','boorish','creek','A');
247
INSERT INTO t2 VALUES (200,048401,37,'normalizes','Everhart','Huffman','');
248
INSERT INTO t2 VALUES (201,048402,37,'comprehensive','encompass','Majorca','FAS');
249
INSERT INTO t2 VALUES (202,048403,37,'chewing','mushrooms','governing','A');
250
INSERT INTO t2 VALUES (203,048404,37,'denizen','Alison','gadfly','FAS');
251
INSERT INTO t2 VALUES (204,048405,37,'schemer','externally','reassigned','FAS');
252
INSERT INTO t2 VALUES (205,048406,37,'chronicle','pellagra','intentness','W');
253
INSERT INTO t2 VALUES (206,048407,37,'Kline','cult','craziness','');
254
INSERT INTO t2 VALUES (207,048408,37,'Anatole','creek','psychic','');
255
INSERT INTO t2 VALUES (208,048409,37,'partridges','Huffman','squabbled','');
256
INSERT INTO t2 VALUES (209,048410,37,'brunch','Majorca','burlesque','');
257
INSERT INTO t2 VALUES (210,048411,37,'recruited','governing','capped','');
258
INSERT INTO t2 VALUES (211,048412,37,'dimensions','gadfly','extracted','A');
259
INSERT INTO t2 VALUES (212,048413,37,'Chicana','reassigned','DiMaggio','');
260
INSERT INTO t2 VALUES (213,048601,37,'announced','intentness','exclamation','FAS');
261
INSERT INTO t2 VALUES (214,048602,37,'praised','craziness','subdirectory','');
262
INSERT INTO t2 VALUES (215,048603,37,'employing','psychic','fangs','');
263
INSERT INTO t2 VALUES (216,048604,37,'linear','squabbled','buyer','A');
264
INSERT INTO t2 VALUES (217,048801,37,'quagmire','burlesque','pithing','A');
265
INSERT INTO t2 VALUES (218,050901,37,'western','capped','transistorizing','A');
266
INSERT INTO t2 VALUES (219,051201,37,'relishing','extracted','nonbiodegradable','');
267
INSERT INTO t2 VALUES (220,056002,37,'serving','DiMaggio','dislocate','');
268
INSERT INTO t2 VALUES (221,056003,37,'scheduling','exclamation','monochromatic','FAS');
269
INSERT INTO t2 VALUES (222,056004,37,'lore','subdirectory','batting','');
270
INSERT INTO t2 VALUES (223,056102,37,'eventful','fangs','postcondition','A');
271
INSERT INTO t2 VALUES (224,056203,37,'arteriole','buyer','catalog','FAS');
272
INSERT INTO t2 VALUES (225,056204,37,'disentangle','pithing','Remus','');
273
INSERT INTO t2 VALUES (226,058003,37,'cured','transistorizing','devices','A');
274
INSERT INTO t2 VALUES (227,058004,37,'Fenton','nonbiodegradable','bike','A');
275
INSERT INTO t2 VALUES (228,058005,37,'avoidable','dislocate','qualify','');
276
INSERT INTO t2 VALUES (229,058006,37,'drains','monochromatic','detained','');
277
INSERT INTO t2 VALUES (230,058007,37,'detectably','batting','commended','');
278
INSERT INTO t2 VALUES (231,058101,37,'husky','postcondition','civilize','');
279
INSERT INTO t2 VALUES (232,058102,37,'impelling','catalog','Elmhurst','');
280
INSERT INTO t2 VALUES (233,058103,37,'undoes','Remus','anesthetizing','');
281
INSERT INTO t2 VALUES (234,058105,37,'evened','devices','deaf','');
282
INSERT INTO t2 VALUES (235,058111,37,'squeezes','bike','Brigham','');
283
INSERT INTO t2 VALUES (236,058112,37,'destroyer','qualify','title','');
284
INSERT INTO t2 VALUES (237,058113,37,'rudeness','detained','coarse','');
285
INSERT INTO t2 VALUES (238,058114,37,'beaner','commended','combinations','');
286
INSERT INTO t2 VALUES (239,058115,37,'boorish','civilize','grayness','');
287
INSERT INTO t2 VALUES (240,058116,37,'Everhart','Elmhurst','innumerable','FAS');
288
INSERT INTO t2 VALUES (241,058117,37,'encompass','anesthetizing','Caroline','A');
289
INSERT INTO t2 VALUES (242,058118,37,'mushrooms','deaf','fatty','FAS');
290
INSERT INTO t2 VALUES (243,058119,37,'Alison','Brigham','eastbound','');
291
INSERT INTO t2 VALUES (244,058120,37,'externally','title','inexperienced','');
292
INSERT INTO t2 VALUES (245,058121,37,'pellagra','coarse','hoarder','A');
293
INSERT INTO t2 VALUES (246,058122,37,'cult','combinations','scotch','W');
294
INSERT INTO t2 VALUES (247,058123,37,'creek','grayness','passport','A');
295
INSERT INTO t2 VALUES (248,058124,37,'Huffman','innumerable','strategic','FAS');
296
INSERT INTO t2 VALUES (249,058125,37,'Majorca','Caroline','gated','');
297
INSERT INTO t2 VALUES (250,058126,37,'governing','fatty','flog','');
298
INSERT INTO t2 VALUES (251,058127,37,'gadfly','eastbound','Pipestone','');
299
INSERT INTO t2 VALUES (252,058128,37,'reassigned','inexperienced','Dar','');
300
INSERT INTO t2 VALUES (253,058201,37,'intentness','hoarder','Corcoran','');
301
INSERT INTO t2 VALUES (254,058202,37,'craziness','scotch','flyers','A');
302
INSERT INTO t2 VALUES (255,058303,37,'psychic','passport','competitions','W');
303
INSERT INTO t2 VALUES (256,058304,37,'squabbled','strategic','suppliers','FAS');
304
INSERT INTO t2 VALUES (257,058602,37,'burlesque','gated','skips','');
305
INSERT INTO t2 VALUES (258,058603,37,'capped','flog','institutes','');
306
INSERT INTO t2 VALUES (259,058604,37,'extracted','Pipestone','troop','A');
307
INSERT INTO t2 VALUES (260,058605,37,'DiMaggio','Dar','connective','W');
308
INSERT INTO t2 VALUES (261,058606,37,'exclamation','Corcoran','denies','');
309
INSERT INTO t2 VALUES (262,058607,37,'subdirectory','flyers','polka','');
310
INSERT INTO t2 VALUES (263,060401,36,'fangs','competitions','observations','FAS');
311
INSERT INTO t2 VALUES (264,061701,36,'buyer','suppliers','askers','');
312
INSERT INTO t2 VALUES (265,066201,36,'pithing','skips','homeless','FAS');
313
INSERT INTO t2 VALUES (266,066501,36,'transistorizing','institutes','Anna','');
314
INSERT INTO t2 VALUES (267,068001,36,'nonbiodegradable','troop','subdirectories','W');
315
INSERT INTO t2 VALUES (268,068002,36,'dislocate','connective','decaying','FAS');
316
INSERT INTO t2 VALUES (269,068005,36,'monochromatic','denies','outwitting','W');
317
INSERT INTO t2 VALUES (270,068006,36,'batting','polka','Harpy','W');
318
INSERT INTO t2 VALUES (271,068007,36,'postcondition','observations','crazed','');
319
INSERT INTO t2 VALUES (272,068008,36,'catalog','askers','suffocate','');
320
INSERT INTO t2 VALUES (273,068009,36,'Remus','homeless','provers','FAS');
321
INSERT INTO t2 VALUES (274,068010,36,'devices','Anna','technically','');
322
INSERT INTO t2 VALUES (275,068011,36,'bike','subdirectories','Franklinizations','');
323
INSERT INTO t2 VALUES (276,068202,36,'qualify','decaying','considered','');
324
INSERT INTO t2 VALUES (277,068302,36,'detained','outwitting','tinnily','');
325
INSERT INTO t2 VALUES (278,068303,36,'commended','Harpy','uninterruptedly','');
326
INSERT INTO t2 VALUES (279,068401,36,'civilize','crazed','whistled','A');
327
INSERT INTO t2 VALUES (280,068501,36,'Elmhurst','suffocate','automate','');
328
INSERT INTO t2 VALUES (281,068502,36,'anesthetizing','provers','gutting','W');
329
INSERT INTO t2 VALUES (282,068503,36,'deaf','technically','surreptitious','');
330
INSERT INTO t2 VALUES (283,068602,36,'Brigham','Franklinizations','Choctaw','');
331
INSERT INTO t2 VALUES (284,068603,36,'title','considered','cooks','');
332
INSERT INTO t2 VALUES (285,068701,36,'coarse','tinnily','millivolt','FAS');
333
INSERT INTO t2 VALUES (286,068702,36,'combinations','uninterruptedly','counterpoise','');
334
INSERT INTO t2 VALUES (287,068703,36,'grayness','whistled','Gothicism','');
335
INSERT INTO t2 VALUES (288,076001,36,'innumerable','automate','feminine','');
336
INSERT INTO t2 VALUES (289,076002,36,'Caroline','gutting','metaphysically','W');
337
INSERT INTO t2 VALUES (290,076101,36,'fatty','surreptitious','sanding','A');
338
INSERT INTO t2 VALUES (291,076102,36,'eastbound','Choctaw','contributorily','');
339
INSERT INTO t2 VALUES (292,076103,36,'inexperienced','cooks','receivers','FAS');
340
INSERT INTO t2 VALUES (293,076302,36,'hoarder','millivolt','adjourn','');
341
INSERT INTO t2 VALUES (294,076303,36,'scotch','counterpoise','straggled','A');
342
INSERT INTO t2 VALUES (295,076304,36,'passport','Gothicism','druggists','');
343
INSERT INTO t2 VALUES (296,076305,36,'strategic','feminine','thanking','FAS');
344
INSERT INTO t2 VALUES (297,076306,36,'gated','metaphysically','ostrich','');
345
INSERT INTO t2 VALUES (298,076307,36,'flog','sanding','hopelessness','FAS');
346
INSERT INTO t2 VALUES (299,076402,36,'Pipestone','contributorily','Eurydice','');
347
INSERT INTO t2 VALUES (300,076501,36,'Dar','receivers','excitation','W');
348
INSERT INTO t2 VALUES (301,076502,36,'Corcoran','adjourn','presumes','FAS');
349
INSERT INTO t2 VALUES (302,076701,36,'flyers','straggled','imaginable','FAS');
350
INSERT INTO t2 VALUES (303,078001,36,'competitions','druggists','concoct','W');
351
INSERT INTO t2 VALUES (304,078002,36,'suppliers','thanking','peering','W');
352
INSERT INTO t2 VALUES (305,078003,36,'skips','ostrich','Phelps','FAS');
353
INSERT INTO t2 VALUES (306,078004,36,'institutes','hopelessness','ferociousness','FAS');
354
INSERT INTO t2 VALUES (307,078005,36,'troop','Eurydice','sentences','');
355
INSERT INTO t2 VALUES (308,078006,36,'connective','excitation','unlocks','');
356
INSERT INTO t2 VALUES (309,078007,36,'denies','presumes','engrossing','W');
357
INSERT INTO t2 VALUES (310,078008,36,'polka','imaginable','Ruth','');
358
INSERT INTO t2 VALUES (311,078101,36,'observations','concoct','tying','');
359
INSERT INTO t2 VALUES (312,078103,36,'askers','peering','exclaimers','');
360
INSERT INTO t2 VALUES (313,078104,36,'homeless','Phelps','synergy','');
361
INSERT INTO t2 VALUES (314,078105,36,'Anna','ferociousness','Huey','W');
362
INSERT INTO t2 VALUES (315,082101,36,'subdirectories','sentences','merging','');
363
INSERT INTO t2 VALUES (316,083401,36,'decaying','unlocks','judges','A');
364
INSERT INTO t2 VALUES (317,084001,36,'outwitting','engrossing','Shylock','W');
365
INSERT INTO t2 VALUES (318,084002,36,'Harpy','Ruth','Miltonism','');
366
INSERT INTO t2 VALUES (319,086001,36,'crazed','tying','hen','W');
367
INSERT INTO t2 VALUES (320,086102,36,'suffocate','exclaimers','honeybee','FAS');
368
INSERT INTO t2 VALUES (321,086201,36,'provers','synergy','towers','');
369
INSERT INTO t2 VALUES (322,088001,36,'technically','Huey','dilutes','W');
370
INSERT INTO t2 VALUES (323,088002,36,'Franklinizations','merging','numerals','FAS');
371
INSERT INTO t2 VALUES (324,088003,36,'considered','judges','democracy','FAS');
372
INSERT INTO t2 VALUES (325,088004,36,'tinnily','Shylock','Ibero-','');
373
INSERT INTO t2 VALUES (326,088101,36,'uninterruptedly','Miltonism','invalids','');
374
INSERT INTO t2 VALUES (327,088102,36,'whistled','hen','behavior','');
375
INSERT INTO t2 VALUES (328,088103,36,'automate','honeybee','accruing','');
376
INSERT INTO t2 VALUES (329,088104,36,'gutting','towers','relics','A');
377
INSERT INTO t2 VALUES (330,088105,36,'surreptitious','dilutes','rackets','');
378
INSERT INTO t2 VALUES (331,088106,36,'Choctaw','numerals','Fischbein','W');
379
INSERT INTO t2 VALUES (332,088201,36,'cooks','democracy','phony','W');
380
INSERT INTO t2 VALUES (333,088203,36,'millivolt','Ibero-','cross','FAS');
381
INSERT INTO t2 VALUES (334,088204,36,'counterpoise','invalids','cleanup','');
382
INSERT INTO t2 VALUES (335,088302,37,'Gothicism','behavior','conspirator','');
383
INSERT INTO t2 VALUES (336,088303,37,'feminine','accruing','label','FAS');
384
INSERT INTO t2 VALUES (337,088305,37,'metaphysically','relics','university','');
385
INSERT INTO t2 VALUES (338,088402,37,'sanding','rackets','cleansed','FAS');
386
INSERT INTO t2 VALUES (339,088501,36,'contributorily','Fischbein','ballgown','');
387
INSERT INTO t2 VALUES (340,088502,36,'receivers','phony','starlet','');
388
INSERT INTO t2 VALUES (341,088503,36,'adjourn','cross','aqueous','');
389
INSERT INTO t2 VALUES (342,098001,58,'straggled','cleanup','portrayal','A');
390
INSERT INTO t2 VALUES (343,098002,58,'druggists','conspirator','despising','W');
391
INSERT INTO t2 VALUES (344,098003,58,'thanking','label','distort','W');
392
INSERT INTO t2 VALUES (345,098004,58,'ostrich','university','palmed','');
393
INSERT INTO t2 VALUES (346,098005,58,'hopelessness','cleansed','faced','');
394
INSERT INTO t2 VALUES (347,098006,58,'Eurydice','ballgown','silverware','');
395
INSERT INTO t2 VALUES (348,141903,29,'excitation','starlet','assessor','');
396
INSERT INTO t2 VALUES (349,098008,58,'presumes','aqueous','spiders','');
397
INSERT INTO t2 VALUES (350,098009,58,'imaginable','portrayal','artificially','');
398
INSERT INTO t2 VALUES (351,098010,58,'concoct','despising','reminiscence','');
399
INSERT INTO t2 VALUES (352,098011,58,'peering','distort','Mexican','');
400
INSERT INTO t2 VALUES (353,098012,58,'Phelps','palmed','obnoxious','');
401
INSERT INTO t2 VALUES (354,098013,58,'ferociousness','faced','fragile','');
402
INSERT INTO t2 VALUES (355,098014,58,'sentences','silverware','apprehensible','');
403
INSERT INTO t2 VALUES (356,098015,58,'unlocks','assessor','births','');
404
INSERT INTO t2 VALUES (357,098016,58,'engrossing','spiders','garages','');
405
INSERT INTO t2 VALUES (358,098017,58,'Ruth','artificially','panty','');
406
INSERT INTO t2 VALUES (359,098018,58,'tying','reminiscence','anteater','');
407
INSERT INTO t2 VALUES (360,098019,58,'exclaimers','Mexican','displacement','A');
408
INSERT INTO t2 VALUES (361,098020,58,'synergy','obnoxious','drovers','A');
409
INSERT INTO t2 VALUES (362,098021,58,'Huey','fragile','patenting','A');
410
INSERT INTO t2 VALUES (363,098022,58,'merging','apprehensible','far','A');
411
INSERT INTO t2 VALUES (364,098023,58,'judges','births','shrieks','');
412
INSERT INTO t2 VALUES (365,098024,58,'Shylock','garages','aligning','W');
413
INSERT INTO t2 VALUES (366,098025,37,'Miltonism','panty','pragmatism','');
414
INSERT INTO t2 VALUES (367,106001,36,'hen','anteater','fevers','W');
415
INSERT INTO t2 VALUES (368,108001,36,'honeybee','displacement','reexamines','A');
416
INSERT INTO t2 VALUES (369,108002,36,'towers','drovers','occupancies','');
417
INSERT INTO t2 VALUES (370,108003,36,'dilutes','patenting','sweats','FAS');
418
INSERT INTO t2 VALUES (371,108004,36,'numerals','far','modulators','');
419
INSERT INTO t2 VALUES (372,108005,36,'democracy','shrieks','demand','W');
420
INSERT INTO t2 VALUES (373,108007,36,'Ibero-','aligning','Madeira','');
421
INSERT INTO t2 VALUES (374,108008,36,'invalids','pragmatism','Viennese','W');
422
INSERT INTO t2 VALUES (375,108009,36,'behavior','fevers','chillier','W');
423
INSERT INTO t2 VALUES (376,108010,36,'accruing','reexamines','wildcats','FAS');
424
INSERT INTO t2 VALUES (377,108011,36,'relics','occupancies','gentle','');
425
INSERT INTO t2 VALUES (378,108012,36,'rackets','sweats','Angles','W');
426
INSERT INTO t2 VALUES (379,108101,36,'Fischbein','modulators','accuracies','');
427
INSERT INTO t2 VALUES (380,108102,36,'phony','demand','toggle','');
428
INSERT INTO t2 VALUES (381,108103,36,'cross','Madeira','Mendelssohn','W');
429
INSERT INTO t2 VALUES (382,108111,50,'cleanup','Viennese','behaviorally','');
430
INSERT INTO t2 VALUES (383,108105,36,'conspirator','chillier','Rochford','');
431
INSERT INTO t2 VALUES (384,108106,36,'label','wildcats','mirror','W');
432
INSERT INTO t2 VALUES (385,108107,36,'university','gentle','Modula','');
433
INSERT INTO t2 VALUES (386,108108,50,'cleansed','Angles','clobbering','');
434
INSERT INTO t2 VALUES (387,108109,36,'ballgown','accuracies','chronography','');
435
INSERT INTO t2 VALUES (388,108110,36,'starlet','toggle','Eskimoizeds','');
436
INSERT INTO t2 VALUES (389,108201,36,'aqueous','Mendelssohn','British','W');
437
INSERT INTO t2 VALUES (390,108202,36,'portrayal','behaviorally','pitfalls','');
438
INSERT INTO t2 VALUES (391,108203,36,'despising','Rochford','verify','W');
439
INSERT INTO t2 VALUES (392,108204,36,'distort','mirror','scatter','FAS');
440
INSERT INTO t2 VALUES (393,108205,36,'palmed','Modula','Aztecan','');
441
INSERT INTO t2 VALUES (394,108301,36,'faced','clobbering','acuity','W');
442
INSERT INTO t2 VALUES (395,108302,36,'silverware','chronography','sinking','W');
443
INSERT INTO t2 VALUES (396,112101,36,'assessor','Eskimoizeds','beasts','FAS');
444
INSERT INTO t2 VALUES (397,112102,36,'spiders','British','Witt','W');
445
INSERT INTO t2 VALUES (398,113701,36,'artificially','pitfalls','physicists','FAS');
446
INSERT INTO t2 VALUES (399,116001,36,'reminiscence','verify','folksong','A');
447
INSERT INTO t2 VALUES (400,116201,36,'Mexican','scatter','strokes','FAS');
448
INSERT INTO t2 VALUES (401,116301,36,'obnoxious','Aztecan','crowder','');
449
INSERT INTO t2 VALUES (402,116302,36,'fragile','acuity','merry','');
450
INSERT INTO t2 VALUES (403,116601,36,'apprehensible','sinking','cadenced','');
451
INSERT INTO t2 VALUES (404,116602,36,'births','beasts','alimony','A');
452
INSERT INTO t2 VALUES (405,116603,36,'garages','Witt','principled','A');
453
INSERT INTO t2 VALUES (406,116701,36,'panty','physicists','golfing','');
454
INSERT INTO t2 VALUES (407,116702,36,'anteater','folksong','undiscovered','');
455
INSERT INTO t2 VALUES (408,118001,36,'displacement','strokes','irritates','');
456
INSERT INTO t2 VALUES (409,118002,36,'drovers','crowder','patriots','A');
457
INSERT INTO t2 VALUES (410,118003,36,'patenting','merry','rooms','FAS');
458
INSERT INTO t2 VALUES (411,118004,36,'far','cadenced','towering','W');
459
INSERT INTO t2 VALUES (412,118005,36,'shrieks','alimony','displease','');
460
INSERT INTO t2 VALUES (413,118006,36,'aligning','principled','photosensitive','');
461
INSERT INTO t2 VALUES (414,118007,36,'pragmatism','golfing','inking','');
462
INSERT INTO t2 VALUES (415,118008,36,'fevers','undiscovered','gainers','');
463
INSERT INTO t2 VALUES (416,118101,36,'reexamines','irritates','leaning','A');
464
INSERT INTO t2 VALUES (417,118102,36,'occupancies','patriots','hydrant','A');
465
INSERT INTO t2 VALUES (418,118103,36,'sweats','rooms','preserve','');
466
INSERT INTO t2 VALUES (419,118202,36,'modulators','towering','blinded','A');
467
INSERT INTO t2 VALUES (420,118203,36,'demand','displease','interactions','A');
468
INSERT INTO t2 VALUES (421,118204,36,'Madeira','photosensitive','Barry','');
469
INSERT INTO t2 VALUES (422,118302,36,'Viennese','inking','whiteness','A');
470
INSERT INTO t2 VALUES (423,118304,36,'chillier','gainers','pastimes','W');
471
INSERT INTO t2 VALUES (424,118305,36,'wildcats','leaning','Edenization','');
472
INSERT INTO t2 VALUES (425,118306,36,'gentle','hydrant','Muscat','');
473
INSERT INTO t2 VALUES (426,118307,36,'Angles','preserve','assassinated','');
474
INSERT INTO t2 VALUES (427,123101,36,'accuracies','blinded','labeled','');
475
INSERT INTO t2 VALUES (428,123102,36,'toggle','interactions','glacial','A');
476
INSERT INTO t2 VALUES (429,123301,36,'Mendelssohn','Barry','implied','W');
477
INSERT INTO t2 VALUES (430,126001,36,'behaviorally','whiteness','bibliographies','W');
478
INSERT INTO t2 VALUES (431,126002,36,'Rochford','pastimes','Buchanan','');
479
INSERT INTO t2 VALUES (432,126003,36,'mirror','Edenization','forgivably','FAS');
480
INSERT INTO t2 VALUES (433,126101,36,'Modula','Muscat','innuendo','A');
481
INSERT INTO t2 VALUES (434,126301,36,'clobbering','assassinated','den','FAS');
482
INSERT INTO t2 VALUES (435,126302,36,'chronography','labeled','submarines','W');
483
INSERT INTO t2 VALUES (436,126402,36,'Eskimoizeds','glacial','mouthful','A');
484
INSERT INTO t2 VALUES (437,126601,36,'British','implied','expiring','');
485
INSERT INTO t2 VALUES (438,126602,36,'pitfalls','bibliographies','unfulfilled','FAS');
486
INSERT INTO t2 VALUES (439,126702,36,'verify','Buchanan','precession','');
487
INSERT INTO t2 VALUES (440,128001,36,'scatter','forgivably','nullified','');
488
INSERT INTO t2 VALUES (441,128002,36,'Aztecan','innuendo','affects','');
489
INSERT INTO t2 VALUES (442,128003,36,'acuity','den','Cynthia','');
490
INSERT INTO t2 VALUES (443,128004,36,'sinking','submarines','Chablis','A');
491
INSERT INTO t2 VALUES (444,128005,36,'beasts','mouthful','betterments','FAS');
492
INSERT INTO t2 VALUES (445,128007,36,'Witt','expiring','advertising','');
493
INSERT INTO t2 VALUES (446,128008,36,'physicists','unfulfilled','rubies','A');
494
INSERT INTO t2 VALUES (447,128009,36,'folksong','precession','southwest','FAS');
495
INSERT INTO t2 VALUES (448,128010,36,'strokes','nullified','superstitious','A');
496
INSERT INTO t2 VALUES (449,128011,36,'crowder','affects','tabernacle','W');
497
INSERT INTO t2 VALUES (450,128012,36,'merry','Cynthia','silk','A');
498
INSERT INTO t2 VALUES (451,128013,36,'cadenced','Chablis','handsomest','A');
499
INSERT INTO t2 VALUES (452,128014,36,'alimony','betterments','Persian','A');
500
INSERT INTO t2 VALUES (453,128015,36,'principled','advertising','analog','W');
501
INSERT INTO t2 VALUES (454,128016,36,'golfing','rubies','complex','W');
502
INSERT INTO t2 VALUES (455,128017,36,'undiscovered','southwest','Taoist','');
503
INSERT INTO t2 VALUES (456,128018,36,'irritates','superstitious','suspend','');
504
INSERT INTO t2 VALUES (457,128019,36,'patriots','tabernacle','relegated','');
505
INSERT INTO t2 VALUES (458,128020,36,'rooms','silk','awesome','W');
506
INSERT INTO t2 VALUES (459,128021,36,'towering','handsomest','Bruxelles','');
507
INSERT INTO t2 VALUES (460,128022,36,'displease','Persian','imprecisely','A');
508
INSERT INTO t2 VALUES (461,128023,36,'photosensitive','analog','televise','');
509
INSERT INTO t2 VALUES (462,128101,36,'inking','complex','braking','');
510
INSERT INTO t2 VALUES (463,128102,36,'gainers','Taoist','true','FAS');
511
INSERT INTO t2 VALUES (464,128103,36,'leaning','suspend','disappointing','FAS');
512
INSERT INTO t2 VALUES (465,128104,36,'hydrant','relegated','navally','W');
513
INSERT INTO t2 VALUES (466,128106,36,'preserve','awesome','circus','');
514
INSERT INTO t2 VALUES (467,128107,36,'blinded','Bruxelles','beetles','');
515
INSERT INTO t2 VALUES (468,128108,36,'interactions','imprecisely','trumps','');
516
INSERT INTO t2 VALUES (469,128202,36,'Barry','televise','fourscore','W');
517
INSERT INTO t2 VALUES (470,128203,36,'whiteness','braking','Blackfoots','');
518
INSERT INTO t2 VALUES (471,128301,36,'pastimes','true','Grady','');
519
INSERT INTO t2 VALUES (472,128302,36,'Edenization','disappointing','quiets','FAS');
520
INSERT INTO t2 VALUES (473,128303,36,'Muscat','navally','floundered','FAS');
521
INSERT INTO t2 VALUES (474,128304,36,'assassinated','circus','profundity','W');
522
INSERT INTO t2 VALUES (475,128305,36,'labeled','beetles','Garrisonian','W');
523
INSERT INTO t2 VALUES (476,128307,36,'glacial','trumps','Strauss','');
524
INSERT INTO t2 VALUES (477,128401,36,'implied','fourscore','cemented','FAS');
525
INSERT INTO t2 VALUES (478,128502,36,'bibliographies','Blackfoots','contrition','A');
526
INSERT INTO t2 VALUES (479,128503,36,'Buchanan','Grady','mutations','');
527
INSERT INTO t2 VALUES (480,128504,36,'forgivably','quiets','exhibits','W');
528
INSERT INTO t2 VALUES (481,128505,36,'innuendo','floundered','tits','');
529
INSERT INTO t2 VALUES (482,128601,36,'den','profundity','mate','A');
530
INSERT INTO t2 VALUES (483,128603,36,'submarines','Garrisonian','arches','');
531
INSERT INTO t2 VALUES (484,128604,36,'mouthful','Strauss','Moll','');
532
INSERT INTO t2 VALUES (485,128702,36,'expiring','cemented','ropers','');
533
INSERT INTO t2 VALUES (486,128703,36,'unfulfilled','contrition','bombast','');
534
INSERT INTO t2 VALUES (487,128704,36,'precession','mutations','difficultly','A');
535
INSERT INTO t2 VALUES (488,138001,36,'nullified','exhibits','adsorption','');
536
INSERT INTO t2 VALUES (489,138002,36,'affects','tits','definiteness','FAS');
537
INSERT INTO t2 VALUES (490,138003,36,'Cynthia','mate','cultivation','A');
538
INSERT INTO t2 VALUES (491,138004,36,'Chablis','arches','heals','A');
539
INSERT INTO t2 VALUES (492,138005,36,'betterments','Moll','Heusen','W');
540
INSERT INTO t2 VALUES (493,138006,36,'advertising','ropers','target','FAS');
541
INSERT INTO t2 VALUES (494,138007,36,'rubies','bombast','cited','A');
542
INSERT INTO t2 VALUES (495,138008,36,'southwest','difficultly','congresswoman','W');
543
INSERT INTO t2 VALUES (496,138009,36,'superstitious','adsorption','Katherine','');
544
INSERT INTO t2 VALUES (497,138102,36,'tabernacle','definiteness','titter','A');
545
INSERT INTO t2 VALUES (498,138103,36,'silk','cultivation','aspire','A');
546
INSERT INTO t2 VALUES (499,138104,36,'handsomest','heals','Mardis','');
547
INSERT INTO t2 VALUES (500,138105,36,'Persian','Heusen','Nadia','W');
548
INSERT INTO t2 VALUES (501,138201,36,'analog','target','estimating','FAS');
549
INSERT INTO t2 VALUES (502,138302,36,'complex','cited','stuck','A');
550
INSERT INTO t2 VALUES (503,138303,36,'Taoist','congresswoman','fifteenth','A');
551
INSERT INTO t2 VALUES (504,138304,36,'suspend','Katherine','Colombo','');
552
INSERT INTO t2 VALUES (505,138401,29,'relegated','titter','survey','A');
553
INSERT INTO t2 VALUES (506,140102,29,'awesome','aspire','staffing','');
554
INSERT INTO t2 VALUES (507,140103,29,'Bruxelles','Mardis','obtain','');
555
INSERT INTO t2 VALUES (508,140104,29,'imprecisely','Nadia','loaded','');
556
INSERT INTO t2 VALUES (509,140105,29,'televise','estimating','slaughtered','');
557
INSERT INTO t2 VALUES (510,140201,29,'braking','stuck','lights','A');
558
INSERT INTO t2 VALUES (511,140701,29,'true','fifteenth','circumference','');
559
INSERT INTO t2 VALUES (512,141501,29,'disappointing','Colombo','dull','A');
560
INSERT INTO t2 VALUES (513,141502,29,'navally','survey','weekly','A');
561
INSERT INTO t2 VALUES (514,141901,29,'circus','staffing','wetness','');
562
INSERT INTO t2 VALUES (515,141902,29,'beetles','obtain','visualized','');
563
INSERT INTO t2 VALUES (516,142101,29,'trumps','loaded','Tannenbaum','');
564
INSERT INTO t2 VALUES (517,142102,29,'fourscore','slaughtered','moribund','');
565
INSERT INTO t2 VALUES (518,142103,29,'Blackfoots','lights','demultiplex','');
566
INSERT INTO t2 VALUES (519,142701,29,'Grady','circumference','lockings','');
567
INSERT INTO t2 VALUES (520,143001,29,'quiets','dull','thugs','FAS');
568
INSERT INTO t2 VALUES (521,143501,29,'floundered','weekly','unnerves','');
569
INSERT INTO t2 VALUES (522,143502,29,'profundity','wetness','abut','');
570
INSERT INTO t2 VALUES (523,148001,29,'Garrisonian','visualized','Chippewa','A');
571
INSERT INTO t2 VALUES (524,148002,29,'Strauss','Tannenbaum','stratifications','A');
572
INSERT INTO t2 VALUES (525,148003,29,'cemented','moribund','signaled','');
573
INSERT INTO t2 VALUES (526,148004,29,'contrition','demultiplex','Italianizes','A');
574
INSERT INTO t2 VALUES (527,148005,29,'mutations','lockings','algorithmic','A');
575
INSERT INTO t2 VALUES (528,148006,29,'exhibits','thugs','paranoid','FAS');
576
INSERT INTO t2 VALUES (529,148007,29,'tits','unnerves','camping','A');
577
INSERT INTO t2 VALUES (530,148009,29,'mate','abut','signifying','A');
578
INSERT INTO t2 VALUES (531,148010,29,'arches','Chippewa','Patrice','W');
579
INSERT INTO t2 VALUES (532,148011,29,'Moll','stratifications','search','A');
580
INSERT INTO t2 VALUES (533,148012,29,'ropers','signaled','Angeles','A');
581
INSERT INTO t2 VALUES (534,148013,29,'bombast','Italianizes','semblance','');
582
INSERT INTO t2 VALUES (535,148023,36,'difficultly','algorithmic','taxed','');
583
INSERT INTO t2 VALUES (536,148015,29,'adsorption','paranoid','Beatrice','');
584
INSERT INTO t2 VALUES (537,148016,29,'definiteness','camping','retrace','');
585
INSERT INTO t2 VALUES (538,148017,29,'cultivation','signifying','lockout','');
586
INSERT INTO t2 VALUES (539,148018,29,'heals','Patrice','grammatic','');
587
INSERT INTO t2 VALUES (540,148019,29,'Heusen','search','helmsman','');
588
INSERT INTO t2 VALUES (541,148020,29,'target','Angeles','uniform','W');
589
INSERT INTO t2 VALUES (542,148021,29,'cited','semblance','hamming','');
590
INSERT INTO t2 VALUES (543,148022,29,'congresswoman','taxed','disobedience','');
591
INSERT INTO t2 VALUES (544,148101,29,'Katherine','Beatrice','captivated','A');
592
INSERT INTO t2 VALUES (545,148102,29,'titter','retrace','transferals','A');
593
INSERT INTO t2 VALUES (546,148201,29,'aspire','lockout','cartographer','A');
594
INSERT INTO t2 VALUES (547,148401,29,'Mardis','grammatic','aims','FAS');
595
INSERT INTO t2 VALUES (548,148402,29,'Nadia','helmsman','Pakistani','');
596
INSERT INTO t2 VALUES (549,148501,29,'estimating','uniform','burglarized','FAS');
597
INSERT INTO t2 VALUES (550,148502,29,'stuck','hamming','saucepans','A');
598
INSERT INTO t2 VALUES (551,148503,29,'fifteenth','disobedience','lacerating','A');
599
INSERT INTO t2 VALUES (552,148504,29,'Colombo','captivated','corny','');
600
INSERT INTO t2 VALUES (553,148601,29,'survey','transferals','megabytes','FAS');
601
INSERT INTO t2 VALUES (554,148602,29,'staffing','cartographer','chancellor','');
602
INSERT INTO t2 VALUES (555,150701,29,'obtain','aims','bulk','A');
603
INSERT INTO t2 VALUES (556,152101,29,'loaded','Pakistani','commits','A');
604
INSERT INTO t2 VALUES (557,152102,29,'slaughtered','burglarized','meson','W');
605
INSERT INTO t2 VALUES (558,155202,36,'lights','saucepans','deputies','');
606
INSERT INTO t2 VALUES (559,155203,29,'circumference','lacerating','northeaster','A');
607
INSERT INTO t2 VALUES (560,155204,29,'dull','corny','dipole','');
608
INSERT INTO t2 VALUES (561,155205,29,'weekly','megabytes','machining','0');
609
INSERT INTO t2 VALUES (562,156001,29,'wetness','chancellor','therefore','');
610
INSERT INTO t2 VALUES (563,156002,29,'visualized','bulk','Telefunken','');
611
INSERT INTO t2 VALUES (564,156102,29,'Tannenbaum','commits','salvaging','');
612
INSERT INTO t2 VALUES (565,156301,29,'moribund','meson','Corinthianizes','A');
613
INSERT INTO t2 VALUES (566,156302,29,'demultiplex','deputies','restlessly','A');
614
INSERT INTO t2 VALUES (567,156303,29,'lockings','northeaster','bromides','');
615
INSERT INTO t2 VALUES (568,156304,29,'thugs','dipole','generalized','A');
616
INSERT INTO t2 VALUES (569,156305,29,'unnerves','machining','mishaps','');
617
INSERT INTO t2 VALUES (570,156306,29,'abut','therefore','quelling','');
618
INSERT INTO t2 VALUES (571,156501,29,'Chippewa','Telefunken','spiritual','A');
619
INSERT INTO t2 VALUES (572,158001,29,'stratifications','salvaging','beguiles','FAS');
620
INSERT INTO t2 VALUES (573,158002,29,'signaled','Corinthianizes','Trobriand','FAS');
621
INSERT INTO t2 VALUES (574,158101,29,'Italianizes','restlessly','fleeing','A');
622
INSERT INTO t2 VALUES (575,158102,29,'algorithmic','bromides','Armour','A');
623
INSERT INTO t2 VALUES (576,158103,29,'paranoid','generalized','chin','A');
624
INSERT INTO t2 VALUES (577,158201,29,'camping','mishaps','provers','A');
625
INSERT INTO t2 VALUES (578,158202,29,'signifying','quelling','aeronautic','A');
626
INSERT INTO t2 VALUES (579,158203,29,'Patrice','spiritual','voltage','W');
627
INSERT INTO t2 VALUES (580,158204,29,'search','beguiles','sash','');
628
INSERT INTO t2 VALUES (581,158301,29,'Angeles','Trobriand','anaerobic','A');
629
INSERT INTO t2 VALUES (582,158302,29,'semblance','fleeing','simultaneous','A');
630
INSERT INTO t2 VALUES (583,158303,29,'taxed','Armour','accumulating','A');
631
INSERT INTO t2 VALUES (584,158304,29,'Beatrice','chin','Medusan','A');
632
INSERT INTO t2 VALUES (585,158305,29,'retrace','provers','shouted','A');
633
INSERT INTO t2 VALUES (586,158306,29,'lockout','aeronautic','freakish','');
634
INSERT INTO t2 VALUES (587,158501,29,'grammatic','voltage','index','FAS');
635
INSERT INTO t2 VALUES (588,160301,29,'helmsman','sash','commercially','');
636
INSERT INTO t2 VALUES (589,166101,50,'uniform','anaerobic','mistiness','A');
637
INSERT INTO t2 VALUES (590,166102,50,'hamming','simultaneous','endpoint','');
638
INSERT INTO t2 VALUES (591,168001,29,'disobedience','accumulating','straight','A');
639
INSERT INTO t2 VALUES (592,168002,29,'captivated','Medusan','flurried','');
640
INSERT INTO t2 VALUES (593,168003,29,'transferals','shouted','denotative','A');
641
INSERT INTO t2 VALUES (594,168101,29,'cartographer','freakish','coming','FAS');
642
INSERT INTO t2 VALUES (595,168102,29,'aims','index','commencements','FAS');
643
INSERT INTO t2 VALUES (596,168103,29,'Pakistani','commercially','gentleman','');
644
INSERT INTO t2 VALUES (597,168104,29,'burglarized','mistiness','gifted','');
645
INSERT INTO t2 VALUES (598,168202,29,'saucepans','endpoint','Shanghais','');
646
INSERT INTO t2 VALUES (599,168301,29,'lacerating','straight','sportswriting','A');
647
INSERT INTO t2 VALUES (600,168502,29,'corny','flurried','sloping','A');
648
INSERT INTO t2 VALUES (601,168503,29,'megabytes','denotative','navies','');
649
INSERT INTO t2 VALUES (602,168601,29,'chancellor','coming','leaflet','A');
650
INSERT INTO t2 VALUES (603,173001,40,'bulk','commencements','shooter','');
651
INSERT INTO t2 VALUES (604,173701,40,'commits','gentleman','Joplin','FAS');
652
INSERT INTO t2 VALUES (605,173702,40,'meson','gifted','babies','');
653
INSERT INTO t2 VALUES (606,176001,40,'deputies','Shanghais','subdivision','FAS');
654
INSERT INTO t2 VALUES (607,176101,40,'northeaster','sportswriting','burstiness','W');
655
INSERT INTO t2 VALUES (608,176201,40,'dipole','sloping','belted','FAS');
656
INSERT INTO t2 VALUES (609,176401,40,'machining','navies','assails','FAS');
657
INSERT INTO t2 VALUES (610,176501,40,'therefore','leaflet','admiring','W');
658
INSERT INTO t2 VALUES (611,176601,40,'Telefunken','shooter','swaying','0');
659
INSERT INTO t2 VALUES (612,176602,40,'salvaging','Joplin','Goldstine','FAS');
660
INSERT INTO t2 VALUES (613,176603,40,'Corinthianizes','babies','fitting','');
661
INSERT INTO t2 VALUES (614,178001,40,'restlessly','subdivision','Norwalk','W');
662
INSERT INTO t2 VALUES (615,178002,40,'bromides','burstiness','weakening','W');
663
INSERT INTO t2 VALUES (616,178003,40,'generalized','belted','analogy','FAS');
664
INSERT INTO t2 VALUES (617,178004,40,'mishaps','assails','deludes','');
665
INSERT INTO t2 VALUES (618,178005,40,'quelling','admiring','cokes','');
666
INSERT INTO t2 VALUES (619,178006,40,'spiritual','swaying','Clayton','');
667
INSERT INTO t2 VALUES (620,178007,40,'beguiles','Goldstine','exhausts','');
668
INSERT INTO t2 VALUES (621,178008,40,'Trobriand','fitting','causality','');
669
INSERT INTO t2 VALUES (622,178101,40,'fleeing','Norwalk','sating','FAS');
670
INSERT INTO t2 VALUES (623,178102,40,'Armour','weakening','icon','');
671
INSERT INTO t2 VALUES (624,178103,40,'chin','analogy','throttles','');
672
INSERT INTO t2 VALUES (625,178201,40,'provers','deludes','communicants','FAS');
673
INSERT INTO t2 VALUES (626,178202,40,'aeronautic','cokes','dehydrate','FAS');
674
INSERT INTO t2 VALUES (627,178301,40,'voltage','Clayton','priceless','FAS');
675
INSERT INTO t2 VALUES (628,178302,40,'sash','exhausts','publicly','');
676
INSERT INTO t2 VALUES (629,178401,40,'anaerobic','causality','incidentals','FAS');
677
INSERT INTO t2 VALUES (630,178402,40,'simultaneous','sating','commonplace','');
678
INSERT INTO t2 VALUES (631,178403,40,'accumulating','icon','mumbles','');
679
INSERT INTO t2 VALUES (632,178404,40,'Medusan','throttles','furthermore','W');
680
INSERT INTO t2 VALUES (633,178501,40,'shouted','communicants','cautioned','W');
681
INSERT INTO t2 VALUES (634,186002,37,'freakish','dehydrate','parametrized','A');
682
INSERT INTO t2 VALUES (635,186102,37,'index','priceless','registration','A');
683
INSERT INTO t2 VALUES (636,186201,40,'commercially','publicly','sadly','FAS');
684
INSERT INTO t2 VALUES (637,186202,40,'mistiness','incidentals','positioning','');
685
INSERT INTO t2 VALUES (638,186203,40,'endpoint','commonplace','babysitting','');
686
INSERT INTO t2 VALUES (639,186302,37,'straight','mumbles','eternal','A');
687
INSERT INTO t2 VALUES (640,188007,37,'flurried','furthermore','hoarder','');
688
INSERT INTO t2 VALUES (641,188008,37,'denotative','cautioned','congregates','');
689
INSERT INTO t2 VALUES (642,188009,37,'coming','parametrized','rains','');
690
INSERT INTO t2 VALUES (643,188010,37,'commencements','registration','workers','W');
691
INSERT INTO t2 VALUES (644,188011,37,'gentleman','sadly','sags','A');
692
INSERT INTO t2 VALUES (645,188012,37,'gifted','positioning','unplug','W');
693
INSERT INTO t2 VALUES (646,188013,37,'Shanghais','babysitting','garage','A');
694
INSERT INTO t2 VALUES (647,188014,37,'sportswriting','eternal','boulder','A');
695
INSERT INTO t2 VALUES (648,188015,37,'sloping','hoarder','hollowly','A');
696
INSERT INTO t2 VALUES (649,188016,37,'navies','congregates','specifics','');
697
INSERT INTO t2 VALUES (650,188017,37,'leaflet','rains','Teresa','');
698
INSERT INTO t2 VALUES (651,188102,37,'shooter','workers','Winsett','');
699
INSERT INTO t2 VALUES (652,188103,37,'Joplin','sags','convenient','A');
700
INSERT INTO t2 VALUES (653,188202,37,'babies','unplug','buckboards','FAS');
701
INSERT INTO t2 VALUES (654,188301,40,'subdivision','garage','amenities','');
702
INSERT INTO t2 VALUES (655,188302,40,'burstiness','boulder','resplendent','FAS');
703
INSERT INTO t2 VALUES (656,188303,40,'belted','hollowly','priding','FAS');
704
INSERT INTO t2 VALUES (657,188401,37,'assails','specifics','configurations','');
705
INSERT INTO t2 VALUES (658,188402,37,'admiring','Teresa','untidiness','A');
706
INSERT INTO t2 VALUES (659,188503,37,'swaying','Winsett','Brice','W');
707
INSERT INTO t2 VALUES (660,188504,37,'Goldstine','convenient','sews','FAS');
708
INSERT INTO t2 VALUES (661,188505,37,'fitting','buckboards','participated','');
709
INSERT INTO t2 VALUES (662,190701,37,'Norwalk','amenities','Simon','FAS');
710
INSERT INTO t2 VALUES (663,190703,50,'weakening','resplendent','certificates','');
711
INSERT INTO t2 VALUES (664,191701,37,'analogy','priding','Fitzpatrick','');
712
INSERT INTO t2 VALUES (665,191702,37,'deludes','configurations','Evanston','A');
713
INSERT INTO t2 VALUES (666,191703,37,'cokes','untidiness','misted','');
714
INSERT INTO t2 VALUES (667,196001,37,'Clayton','Brice','textures','A');
715
INSERT INTO t2 VALUES (668,196002,37,'exhausts','sews','save','');
716
INSERT INTO t2 VALUES (669,196003,37,'causality','participated','count','');
717
INSERT INTO t2 VALUES (670,196101,37,'sating','Simon','rightful','A');
718
INSERT INTO t2 VALUES (671,196103,37,'icon','certificates','chaperone','');
719
INSERT INTO t2 VALUES (672,196104,37,'throttles','Fitzpatrick','Lizzy','A');
720
INSERT INTO t2 VALUES (673,196201,37,'communicants','Evanston','clenched','A');
721
INSERT INTO t2 VALUES (674,196202,37,'dehydrate','misted','effortlessly','');
722
INSERT INTO t2 VALUES (675,196203,37,'priceless','textures','accessed','');
723
INSERT INTO t2 VALUES (676,198001,37,'publicly','save','beaters','A');
724
INSERT INTO t2 VALUES (677,198003,37,'incidentals','count','Hornblower','FAS');
725
INSERT INTO t2 VALUES (678,198004,37,'commonplace','rightful','vests','A');
726
INSERT INTO t2 VALUES (679,198005,37,'mumbles','chaperone','indulgences','FAS');
727
INSERT INTO t2 VALUES (680,198006,37,'furthermore','Lizzy','infallibly','A');
728
INSERT INTO t2 VALUES (681,198007,37,'cautioned','clenched','unwilling','FAS');
729
INSERT INTO t2 VALUES (682,198008,37,'parametrized','effortlessly','excrete','FAS');
730
INSERT INTO t2 VALUES (683,198009,37,'registration','accessed','spools','A');
731
INSERT INTO t2 VALUES (684,198010,37,'sadly','beaters','crunches','FAS');
732
INSERT INTO t2 VALUES (685,198011,37,'positioning','Hornblower','overestimating','FAS');
733
INSERT INTO t2 VALUES (686,198012,37,'babysitting','vests','ineffective','');
734
INSERT INTO t2 VALUES (687,198013,37,'eternal','indulgences','humiliation','A');
735
INSERT INTO t2 VALUES (688,198014,37,'hoarder','infallibly','sophomore','');
736
INSERT INTO t2 VALUES (689,198015,37,'congregates','unwilling','star','');
737
INSERT INTO t2 VALUES (690,198017,37,'rains','excrete','rifles','');
738
INSERT INTO t2 VALUES (691,198018,37,'workers','spools','dialysis','');
739
INSERT INTO t2 VALUES (692,198019,37,'sags','crunches','arriving','');
740
INSERT INTO t2 VALUES (693,198020,37,'unplug','overestimating','indulge','');
741
INSERT INTO t2 VALUES (694,198021,37,'garage','ineffective','clockers','');
742
INSERT INTO t2 VALUES (695,198022,37,'boulder','humiliation','languages','');
743
INSERT INTO t2 VALUES (696,198023,50,'hollowly','sophomore','Antarctica','A');
744
INSERT INTO t2 VALUES (697,198024,37,'specifics','star','percentage','');
745
INSERT INTO t2 VALUES (698,198101,37,'Teresa','rifles','ceiling','A');
746
INSERT INTO t2 VALUES (699,198103,37,'Winsett','dialysis','specification','');
747
INSERT INTO t2 VALUES (700,198105,37,'convenient','arriving','regimented','A');
748
INSERT INTO t2 VALUES (701,198106,37,'buckboards','indulge','ciphers','');
749
INSERT INTO t2 VALUES (702,198201,37,'amenities','clockers','pictures','A');
750
INSERT INTO t2 VALUES (703,198204,37,'resplendent','languages','serpents','A');
751
INSERT INTO t2 VALUES (704,198301,53,'priding','Antarctica','allot','A');
752
INSERT INTO t2 VALUES (705,198302,53,'configurations','percentage','realized','A');
753
INSERT INTO t2 VALUES (706,198303,53,'untidiness','ceiling','mayoral','A');
754
INSERT INTO t2 VALUES (707,198304,53,'Brice','specification','opaquely','A');
755
INSERT INTO t2 VALUES (708,198401,37,'sews','regimented','hostess','FAS');
756
INSERT INTO t2 VALUES (709,198402,37,'participated','ciphers','fiftieth','');
757
INSERT INTO t2 VALUES (710,198403,37,'Simon','pictures','incorrectly','');
758
INSERT INTO t2 VALUES (711,202101,37,'certificates','serpents','decomposition','FAS');
759
INSERT INTO t2 VALUES (712,202301,37,'Fitzpatrick','allot','stranglings','');
760
INSERT INTO t2 VALUES (713,202302,37,'Evanston','realized','mixture','FAS');
761
INSERT INTO t2 VALUES (714,202303,37,'misted','mayoral','electroencephalography','FAS');
762
INSERT INTO t2 VALUES (715,202304,37,'textures','opaquely','similarities','FAS');
763
INSERT INTO t2 VALUES (716,202305,37,'save','hostess','charges','W');
764
INSERT INTO t2 VALUES (717,202601,37,'count','fiftieth','freest','FAS');
765
INSERT INTO t2 VALUES (718,202602,37,'rightful','incorrectly','Greenberg','FAS');
766
INSERT INTO t2 VALUES (719,202605,37,'chaperone','decomposition','tinting','');
767
INSERT INTO t2 VALUES (720,202606,37,'Lizzy','stranglings','expelled','W');
768
INSERT INTO t2 VALUES (721,202607,37,'clenched','mixture','warm','');
769
INSERT INTO t2 VALUES (722,202901,37,'effortlessly','electroencephalography','smoothed','');
770
INSERT INTO t2 VALUES (723,202902,37,'accessed','similarities','deductions','FAS');
771
INSERT INTO t2 VALUES (724,202903,37,'beaters','charges','Romano','W');
772
INSERT INTO t2 VALUES (725,202904,37,'Hornblower','freest','bitterroot','');
773
INSERT INTO t2 VALUES (726,202907,37,'vests','Greenberg','corset','');
774
INSERT INTO t2 VALUES (727,202908,37,'indulgences','tinting','securing','');
775
INSERT INTO t2 VALUES (728,203101,37,'infallibly','expelled','environing','FAS');
776
INSERT INTO t2 VALUES (729,203103,37,'unwilling','warm','cute','');
777
INSERT INTO t2 VALUES (730,203104,37,'excrete','smoothed','Crays','');
778
INSERT INTO t2 VALUES (731,203105,37,'spools','deductions','heiress','FAS');
779
INSERT INTO t2 VALUES (732,203401,37,'crunches','Romano','inform','FAS');
780
INSERT INTO t2 VALUES (733,203402,37,'overestimating','bitterroot','avenge','');
781
INSERT INTO t2 VALUES (734,203404,37,'ineffective','corset','universals','');
782
INSERT INTO t2 VALUES (735,203901,37,'humiliation','securing','Kinsey','W');
783
INSERT INTO t2 VALUES (736,203902,37,'sophomore','environing','ravines','FAS');
784
INSERT INTO t2 VALUES (737,203903,37,'star','cute','bestseller','');
785
INSERT INTO t2 VALUES (738,203906,37,'rifles','Crays','equilibrium','');
786
INSERT INTO t2 VALUES (739,203907,37,'dialysis','heiress','extents','0');
787
INSERT INTO t2 VALUES (740,203908,37,'arriving','inform','relatively','');
788
INSERT INTO t2 VALUES (741,203909,37,'indulge','avenge','pressure','FAS');
789
INSERT INTO t2 VALUES (742,206101,37,'clockers','universals','critiques','FAS');
790
INSERT INTO t2 VALUES (743,206201,37,'languages','Kinsey','befouled','');
791
INSERT INTO t2 VALUES (744,206202,37,'Antarctica','ravines','rightfully','FAS');
792
INSERT INTO t2 VALUES (745,206203,37,'percentage','bestseller','mechanizing','FAS');
793
INSERT INTO t2 VALUES (746,206206,37,'ceiling','equilibrium','Latinizes','');
794
INSERT INTO t2 VALUES (747,206207,37,'specification','extents','timesharing','');
795
INSERT INTO t2 VALUES (748,206208,37,'regimented','relatively','Aden','');
796
INSERT INTO t2 VALUES (749,208001,37,'ciphers','pressure','embassies','');
797
INSERT INTO t2 VALUES (750,208002,37,'pictures','critiques','males','FAS');
798
INSERT INTO t2 VALUES (751,208003,37,'serpents','befouled','shapelessly','FAS');
799
INSERT INTO t2 VALUES (752,208004,37,'allot','rightfully','genres','FAS');
800
INSERT INTO t2 VALUES (753,208008,37,'realized','mechanizing','mastering','');
801
INSERT INTO t2 VALUES (754,208009,37,'mayoral','Latinizes','Newtonian','');
802
INSERT INTO t2 VALUES (755,208010,37,'opaquely','timesharing','finishers','FAS');
803
INSERT INTO t2 VALUES (756,208011,37,'hostess','Aden','abates','');
804
INSERT INTO t2 VALUES (757,208101,37,'fiftieth','embassies','teem','');
805
INSERT INTO t2 VALUES (758,208102,37,'incorrectly','males','kiting','FAS');
806
INSERT INTO t2 VALUES (759,208103,37,'decomposition','shapelessly','stodgy','FAS');
807
INSERT INTO t2 VALUES (760,208104,37,'stranglings','genres','scalps','FAS');
808
INSERT INTO t2 VALUES (761,208105,37,'mixture','mastering','feed','FAS');
809
INSERT INTO t2 VALUES (762,208110,37,'electroencephalography','Newtonian','guitars','');
810
INSERT INTO t2 VALUES (763,208111,37,'similarities','finishers','airships','');
811
INSERT INTO t2 VALUES (764,208112,37,'charges','abates','store','');
812
INSERT INTO t2 VALUES (765,208113,37,'freest','teem','denounces','');
813
INSERT INTO t2 VALUES (766,208201,37,'Greenberg','kiting','Pyle','FAS');
814
INSERT INTO t2 VALUES (767,208203,37,'tinting','stodgy','Saxony','');
815
INSERT INTO t2 VALUES (768,208301,37,'expelled','scalps','serializations','FAS');
816
INSERT INTO t2 VALUES (769,208302,37,'warm','feed','Peruvian','FAS');
817
INSERT INTO t2 VALUES (770,208305,37,'smoothed','guitars','taxonomically','FAS');
818
INSERT INTO t2 VALUES (771,208401,37,'deductions','airships','kingdom','A');
819
INSERT INTO t2 VALUES (772,208402,37,'Romano','store','stint','A');
820
INSERT INTO t2 VALUES (773,208403,37,'bitterroot','denounces','Sault','A');
821
INSERT INTO t2 VALUES (774,208404,37,'corset','Pyle','faithful','');
822
INSERT INTO t2 VALUES (775,208501,37,'securing','Saxony','Ganymede','FAS');
823
INSERT INTO t2 VALUES (776,208502,37,'environing','serializations','tidiness','FAS');
824
INSERT INTO t2 VALUES (777,208503,37,'cute','Peruvian','gainful','FAS');
825
INSERT INTO t2 VALUES (778,208504,37,'Crays','taxonomically','contrary','FAS');
826
INSERT INTO t2 VALUES (779,208505,37,'heiress','kingdom','Tipperary','FAS');
827
INSERT INTO t2 VALUES (780,210101,37,'inform','stint','tropics','W');
828
INSERT INTO t2 VALUES (781,210102,37,'avenge','Sault','theorizers','');
829
INSERT INTO t2 VALUES (782,210103,37,'universals','faithful','renew','0');
830
INSERT INTO t2 VALUES (783,210104,37,'Kinsey','Ganymede','already','');
831
INSERT INTO t2 VALUES (784,210105,37,'ravines','tidiness','terminal','');
832
INSERT INTO t2 VALUES (785,210106,37,'bestseller','gainful','Hegelian','');
833
INSERT INTO t2 VALUES (786,210107,37,'equilibrium','contrary','hypothesizer','');
834
INSERT INTO t2 VALUES (787,210401,37,'extents','Tipperary','warningly','FAS');
835
INSERT INTO t2 VALUES (788,213201,37,'relatively','tropics','journalizing','FAS');
836
INSERT INTO t2 VALUES (789,213203,37,'pressure','theorizers','nested','');
837
INSERT INTO t2 VALUES (790,213204,37,'critiques','renew','Lars','');
838
INSERT INTO t2 VALUES (791,213205,37,'befouled','already','saplings','');
839
INSERT INTO t2 VALUES (792,213206,37,'rightfully','terminal','foothill','');
840
INSERT INTO t2 VALUES (793,213207,37,'mechanizing','Hegelian','labeled','');
841
INSERT INTO t2 VALUES (794,216101,37,'Latinizes','hypothesizer','imperiously','FAS');
842
INSERT INTO t2 VALUES (795,216103,37,'timesharing','warningly','reporters','FAS');
843
INSERT INTO t2 VALUES (796,218001,37,'Aden','journalizing','furnishings','FAS');
844
INSERT INTO t2 VALUES (797,218002,37,'embassies','nested','precipitable','FAS');
845
INSERT INTO t2 VALUES (798,218003,37,'males','Lars','discounts','FAS');
846
INSERT INTO t2 VALUES (799,218004,37,'shapelessly','saplings','excises','FAS');
847
INSERT INTO t2 VALUES (800,143503,50,'genres','foothill','Stalin','');
848
INSERT INTO t2 VALUES (801,218006,37,'mastering','labeled','despot','FAS');
849
INSERT INTO t2 VALUES (802,218007,37,'Newtonian','imperiously','ripeness','FAS');
850
INSERT INTO t2 VALUES (803,218008,37,'finishers','reporters','Arabia','');
851
INSERT INTO t2 VALUES (804,218009,37,'abates','furnishings','unruly','');
852
INSERT INTO t2 VALUES (805,218010,37,'teem','precipitable','mournfulness','');
853
INSERT INTO t2 VALUES (806,218011,37,'kiting','discounts','boom','FAS');
854
INSERT INTO t2 VALUES (807,218020,37,'stodgy','excises','slaughter','A');
855
INSERT INTO t2 VALUES (808,218021,50,'scalps','Stalin','Sabine','');
856
INSERT INTO t2 VALUES (809,218022,37,'feed','despot','handy','FAS');
857
INSERT INTO t2 VALUES (810,218023,37,'guitars','ripeness','rural','');
858
INSERT INTO t2 VALUES (811,218024,37,'airships','Arabia','organizer','');
859
INSERT INTO t2 VALUES (812,218101,37,'store','unruly','shipyard','FAS');
860
INSERT INTO t2 VALUES (813,218102,37,'denounces','mournfulness','civics','FAS');
861
INSERT INTO t2 VALUES (814,218103,37,'Pyle','boom','inaccuracy','FAS');
862
INSERT INTO t2 VALUES (815,218201,37,'Saxony','slaughter','rules','FAS');
863
INSERT INTO t2 VALUES (816,218202,37,'serializations','Sabine','juveniles','FAS');
864
INSERT INTO t2 VALUES (817,218203,37,'Peruvian','handy','comprised','W');
865
INSERT INTO t2 VALUES (818,218204,37,'taxonomically','rural','investigations','');
866
INSERT INTO t2 VALUES (819,218205,37,'kingdom','organizer','stabilizes','A');
867
INSERT INTO t2 VALUES (820,218301,37,'stint','shipyard','seminaries','FAS');
868
INSERT INTO t2 VALUES (821,218302,37,'Sault','civics','Hunter','A');
869
INSERT INTO t2 VALUES (822,218401,37,'faithful','inaccuracy','sporty','FAS');
870
INSERT INTO t2 VALUES (823,218402,37,'Ganymede','rules','test','FAS');
871
INSERT INTO t2 VALUES (824,218403,37,'tidiness','juveniles','weasels','');
872
INSERT INTO t2 VALUES (825,218404,37,'gainful','comprised','CERN','');
873
INSERT INTO t2 VALUES (826,218407,37,'contrary','investigations','tempering','');
874
INSERT INTO t2 VALUES (827,218408,37,'Tipperary','stabilizes','afore','FAS');
875
INSERT INTO t2 VALUES (828,218409,37,'tropics','seminaries','Galatean','');
876
INSERT INTO t2 VALUES (829,218410,37,'theorizers','Hunter','techniques','W');
877
INSERT INTO t2 VALUES (830,226001,37,'renew','sporty','error','');
878
INSERT INTO t2 VALUES (831,226002,37,'already','test','veranda','');
879
INSERT INTO t2 VALUES (832,226003,37,'terminal','weasels','severely','');
880
INSERT INTO t2 VALUES (833,226004,37,'Hegelian','CERN','Cassites','FAS');
881
INSERT INTO t2 VALUES (834,226005,37,'hypothesizer','tempering','forthcoming','');
882
INSERT INTO t2 VALUES (835,226006,37,'warningly','afore','guides','');
883
INSERT INTO t2 VALUES (836,226007,37,'journalizing','Galatean','vanish','FAS');
884
INSERT INTO t2 VALUES (837,226008,37,'nested','techniques','lied','A');
885
INSERT INTO t2 VALUES (838,226203,37,'Lars','error','sawtooth','FAS');
886
INSERT INTO t2 VALUES (839,226204,37,'saplings','veranda','fated','FAS');
887
INSERT INTO t2 VALUES (840,226205,37,'foothill','severely','gradually','');
888
INSERT INTO t2 VALUES (841,226206,37,'labeled','Cassites','widens','');
889
INSERT INTO t2 VALUES (842,226207,37,'imperiously','forthcoming','preclude','');
890
INSERT INTO t2 VALUES (843,226208,37,'reporters','guides','Jobrel','');
891
INSERT INTO t2 VALUES (844,226209,37,'furnishings','vanish','hooker','');
892
INSERT INTO t2 VALUES (845,226210,37,'precipitable','lied','rainstorm','');
893
INSERT INTO t2 VALUES (846,226211,37,'discounts','sawtooth','disconnects','');
894
INSERT INTO t2 VALUES (847,228001,37,'excises','fated','cruelty','');
895
INSERT INTO t2 VALUES (848,228004,37,'Stalin','gradually','exponentials','A');
896
INSERT INTO t2 VALUES (849,228005,37,'despot','widens','affective','A');
897
INSERT INTO t2 VALUES (850,228006,37,'ripeness','preclude','arteries','');
898
INSERT INTO t2 VALUES (851,228007,37,'Arabia','Jobrel','Crosby','FAS');
899
INSERT INTO t2 VALUES (852,228008,37,'unruly','hooker','acquaint','');
900
INSERT INTO t2 VALUES (853,228009,37,'mournfulness','rainstorm','evenhandedly','');
901
INSERT INTO t2 VALUES (854,228101,37,'boom','disconnects','percentage','');
902
INSERT INTO t2 VALUES (855,228108,37,'slaughter','cruelty','disobedience','');
903
INSERT INTO t2 VALUES (856,228109,37,'Sabine','exponentials','humility','');
904
INSERT INTO t2 VALUES (857,228110,37,'handy','affective','gleaning','A');
905
INSERT INTO t2 VALUES (858,228111,37,'rural','arteries','petted','A');
906
INSERT INTO t2 VALUES (859,228112,37,'organizer','Crosby','bloater','A');
907
INSERT INTO t2 VALUES (860,228113,37,'shipyard','acquaint','minion','A');
908
INSERT INTO t2 VALUES (861,228114,37,'civics','evenhandedly','marginal','A');
909
INSERT INTO t2 VALUES (862,228115,37,'inaccuracy','percentage','apiary','A');
910
INSERT INTO t2 VALUES (863,228116,37,'rules','disobedience','measures','');
911
INSERT INTO t2 VALUES (864,228117,37,'juveniles','humility','precaution','');
912
INSERT INTO t2 VALUES (865,228118,37,'comprised','gleaning','repelled','');
913
INSERT INTO t2 VALUES (866,228119,37,'investigations','petted','primary','FAS');
914
INSERT INTO t2 VALUES (867,228120,37,'stabilizes','bloater','coverings','');
915
INSERT INTO t2 VALUES (868,228121,37,'seminaries','minion','Artemia','A');
916
INSERT INTO t2 VALUES (869,228122,37,'Hunter','marginal','navigate','');
917
INSERT INTO t2 VALUES (870,228201,37,'sporty','apiary','spatial','');
918
INSERT INTO t2 VALUES (871,228206,37,'test','measures','Gurkha','');
919
INSERT INTO t2 VALUES (872,228207,37,'weasels','precaution','meanwhile','A');
920
INSERT INTO t2 VALUES (873,228208,37,'CERN','repelled','Melinda','A');
921
INSERT INTO t2 VALUES (874,228209,37,'tempering','primary','Butterfield','');
922
INSERT INTO t2 VALUES (875,228210,37,'afore','coverings','Aldrich','A');
923
INSERT INTO t2 VALUES (876,228211,37,'Galatean','Artemia','previewing','A');
924
INSERT INTO t2 VALUES (877,228212,37,'techniques','navigate','glut','A');
925
INSERT INTO t2 VALUES (878,228213,37,'error','spatial','unaffected','');
926
INSERT INTO t2 VALUES (879,228214,37,'veranda','Gurkha','inmate','');
927
INSERT INTO t2 VALUES (880,228301,37,'severely','meanwhile','mineral','');
928
INSERT INTO t2 VALUES (881,228305,37,'Cassites','Melinda','impending','A');
929
INSERT INTO t2 VALUES (882,228306,37,'forthcoming','Butterfield','meditation','A');
930
INSERT INTO t2 VALUES (883,228307,37,'guides','Aldrich','ideas','');
931
INSERT INTO t2 VALUES (884,228308,37,'vanish','previewing','miniaturizes','W');
932
INSERT INTO t2 VALUES (885,228309,37,'lied','glut','lewdly','');
933
INSERT INTO t2 VALUES (886,228310,37,'sawtooth','unaffected','title','');
934
INSERT INTO t2 VALUES (887,228311,37,'fated','inmate','youthfulness','');
935
INSERT INTO t2 VALUES (888,228312,37,'gradually','mineral','creak','FAS');
936
INSERT INTO t2 VALUES (889,228313,37,'widens','impending','Chippewa','');
937
INSERT INTO t2 VALUES (890,228314,37,'preclude','meditation','clamored','');
938
INSERT INTO t2 VALUES (891,228401,65,'Jobrel','ideas','freezes','');
939
INSERT INTO t2 VALUES (892,228402,65,'hooker','miniaturizes','forgivably','FAS');
940
INSERT INTO t2 VALUES (893,228403,65,'rainstorm','lewdly','reduce','FAS');
941
INSERT INTO t2 VALUES (894,228404,65,'disconnects','title','McGovern','W');
942
INSERT INTO t2 VALUES (895,228405,65,'cruelty','youthfulness','Nazis','W');
943
INSERT INTO t2 VALUES (896,228406,65,'exponentials','creak','epistle','W');
944
INSERT INTO t2 VALUES (897,228407,65,'affective','Chippewa','socializes','W');
945
INSERT INTO t2 VALUES (898,228408,65,'arteries','clamored','conceptions','');
946
INSERT INTO t2 VALUES (899,228409,65,'Crosby','freezes','Kevin','');
947
INSERT INTO t2 VALUES (900,228410,65,'acquaint','forgivably','uncovering','');
948
INSERT INTO t2 VALUES (901,230301,37,'evenhandedly','reduce','chews','FAS');
949
INSERT INTO t2 VALUES (902,230302,37,'percentage','McGovern','appendixes','FAS');
950
INSERT INTO t2 VALUES (903,230303,37,'disobedience','Nazis','raining','');
951
INSERT INTO t2 VALUES (904,018062,37,'humility','epistle','infest','');
952
INSERT INTO t2 VALUES (905,230501,37,'gleaning','socializes','compartment','');
953
INSERT INTO t2 VALUES (906,230502,37,'petted','conceptions','minting','');
954
INSERT INTO t2 VALUES (907,230503,37,'bloater','Kevin','ducks','');
955
INSERT INTO t2 VALUES (908,230504,37,'minion','uncovering','roped','A');
956
INSERT INTO t2 VALUES (909,230505,37,'marginal','chews','waltz','');
957
INSERT INTO t2 VALUES (910,230506,37,'apiary','appendixes','Lillian','');
958
INSERT INTO t2 VALUES (911,230507,37,'measures','raining','repressions','A');
959
INSERT INTO t2 VALUES (912,230508,37,'precaution','infest','chillingly','');
960
INSERT INTO t2 VALUES (913,230509,37,'repelled','compartment','noncritical','');
961
INSERT INTO t2 VALUES (914,230901,37,'primary','minting','lithograph','');
962
INSERT INTO t2 VALUES (915,230902,37,'coverings','ducks','spongers','');
963
INSERT INTO t2 VALUES (916,230903,37,'Artemia','roped','parenthood','');
964
INSERT INTO t2 VALUES (917,230904,37,'navigate','waltz','posed','');
965
INSERT INTO t2 VALUES (918,230905,37,'spatial','Lillian','instruments','');
966
INSERT INTO t2 VALUES (919,230906,37,'Gurkha','repressions','filial','');
967
INSERT INTO t2 VALUES (920,230907,37,'meanwhile','chillingly','fixedly','');
968
INSERT INTO t2 VALUES (921,230908,37,'Melinda','noncritical','relives','');
969
INSERT INTO t2 VALUES (922,230909,37,'Butterfield','lithograph','Pandora','');
970
INSERT INTO t2 VALUES (923,230910,37,'Aldrich','spongers','watering','A');
971
INSERT INTO t2 VALUES (924,230911,37,'previewing','parenthood','ungrateful','');
972
INSERT INTO t2 VALUES (925,230912,37,'glut','posed','secures','');
973
INSERT INTO t2 VALUES (926,230913,37,'unaffected','instruments','chastisers','');
974
INSERT INTO t2 VALUES (927,230914,37,'inmate','filial','icon','');
975
INSERT INTO t2 VALUES (928,231304,37,'mineral','fixedly','reuniting','A');
976
INSERT INTO t2 VALUES (929,231305,37,'impending','relives','imagining','A');
977
INSERT INTO t2 VALUES (930,231306,37,'meditation','Pandora','abiding','A');
978
INSERT INTO t2 VALUES (931,231307,37,'ideas','watering','omnisciently','');
979
INSERT INTO t2 VALUES (932,231308,37,'miniaturizes','ungrateful','Britannic','');
980
INSERT INTO t2 VALUES (933,231309,37,'lewdly','secures','scholastics','A');
981
INSERT INTO t2 VALUES (934,231310,37,'title','chastisers','mechanics','A');
982
INSERT INTO t2 VALUES (935,231311,37,'youthfulness','icon','humidly','A');
983
INSERT INTO t2 VALUES (936,231312,37,'creak','reuniting','masterpiece','');
984
INSERT INTO t2 VALUES (937,231313,37,'Chippewa','imagining','however','');
985
INSERT INTO t2 VALUES (938,231314,37,'clamored','abiding','Mendelian','');
986
INSERT INTO t2 VALUES (939,231315,37,'freezes','omnisciently','jarred','');
987
INSERT INTO t2 VALUES (940,232102,37,'forgivably','Britannic','scolds','');
988
INSERT INTO t2 VALUES (941,232103,37,'reduce','scholastics','infatuate','');
989
INSERT INTO t2 VALUES (942,232104,37,'McGovern','mechanics','willed','A');
990
INSERT INTO t2 VALUES (943,232105,37,'Nazis','humidly','joyfully','');
991
INSERT INTO t2 VALUES (944,232106,37,'epistle','masterpiece','Microsoft','');
992
INSERT INTO t2 VALUES (945,232107,37,'socializes','however','fibrosities','');
993
INSERT INTO t2 VALUES (946,232108,37,'conceptions','Mendelian','Baltimorean','');
994
INSERT INTO t2 VALUES (947,232601,37,'Kevin','jarred','equestrian','');
995
INSERT INTO t2 VALUES (948,232602,37,'uncovering','scolds','Goodrich','');
996
INSERT INTO t2 VALUES (949,232603,37,'chews','infatuate','apish','A');
997
INSERT INTO t2 VALUES (950,232605,37,'appendixes','willed','Adlerian','');
998
INSERT INTO t2 VALUES (5950,1232605,37,'appendixes','willed','Adlerian','');
999
INSERT INTO t2 VALUES (5951,1232606,37,'appendixes','willed','Adlerian','');
1000
INSERT INTO t2 VALUES (5952,1232607,37,'appendixes','willed','Adlerian','');
1001
INSERT INTO t2 VALUES (5953,1232608,37,'appendixes','willed','Adlerian','');
1002
INSERT INTO t2 VALUES (5954,1232609,37,'appendixes','willed','Adlerian','');
1003
INSERT INTO t2 VALUES (951,232606,37,'raining','joyfully','Tropez','');
1004
INSERT INTO t2 VALUES (952,232607,37,'infest','Microsoft','nouns','');
1005
INSERT INTO t2 VALUES (953,232608,37,'compartment','fibrosities','distracting','');
1006
INSERT INTO t2 VALUES (954,232609,37,'minting','Baltimorean','mutton','');
1007
INSERT INTO t2 VALUES (955,236104,37,'ducks','equestrian','bridgeable','A');
1008
INSERT INTO t2 VALUES (956,236105,37,'roped','Goodrich','stickers','A');
1009
INSERT INTO t2 VALUES (957,236106,37,'waltz','apish','transcontinental','A');
1010
INSERT INTO t2 VALUES (958,236107,37,'Lillian','Adlerian','amateurish','');
1011
INSERT INTO t2 VALUES (959,236108,37,'repressions','Tropez','Gandhian','');
1012
INSERT INTO t2 VALUES (960,236109,37,'chillingly','nouns','stratified','');
1013
INSERT INTO t2 VALUES (961,236110,37,'noncritical','distracting','chamberlains','');
1014
INSERT INTO t2 VALUES (962,236111,37,'lithograph','mutton','creditably','');
1015
INSERT INTO t2 VALUES (963,236112,37,'spongers','bridgeable','philosophic','');
1016
INSERT INTO t2 VALUES (964,236113,37,'parenthood','stickers','ores','');
1017
INSERT INTO t2 VALUES (965,238005,37,'posed','transcontinental','Carleton','');
1018
INSERT INTO t2 VALUES (966,238006,37,'instruments','amateurish','tape','A');
1019
INSERT INTO t2 VALUES (967,238007,37,'filial','Gandhian','afloat','A');
1020
INSERT INTO t2 VALUES (968,238008,37,'fixedly','stratified','goodness','A');
1021
INSERT INTO t2 VALUES (969,238009,37,'relives','chamberlains','welcoming','');
1022
INSERT INTO t2 VALUES (970,238010,37,'Pandora','creditably','Pinsky','FAS');
1023
INSERT INTO t2 VALUES (971,238011,37,'watering','philosophic','halting','');
1024
INSERT INTO t2 VALUES (972,238012,37,'ungrateful','ores','bibliography','');
1025
INSERT INTO t2 VALUES (973,238013,37,'secures','Carleton','decoding','');
1026
INSERT INTO t2 VALUES (974,240401,41,'chastisers','tape','variance','A');
1027
INSERT INTO t2 VALUES (975,240402,41,'icon','afloat','allowed','A');
1028
INSERT INTO t2 VALUES (976,240901,41,'reuniting','goodness','dire','A');
1029
INSERT INTO t2 VALUES (977,240902,41,'imagining','welcoming','dub','A');
1030
INSERT INTO t2 VALUES (978,241801,41,'abiding','Pinsky','poisoning','');
1031
INSERT INTO t2 VALUES (979,242101,41,'omnisciently','halting','Iraqis','A');
1032
INSERT INTO t2 VALUES (980,242102,41,'Britannic','bibliography','heaving','');
1033
INSERT INTO t2 VALUES (981,242201,41,'scholastics','decoding','population','A');
1034
INSERT INTO t2 VALUES (982,242202,41,'mechanics','variance','bomb','A');
1035
INSERT INTO t2 VALUES (983,242501,41,'humidly','allowed','Majorca','A');
1036
INSERT INTO t2 VALUES (984,242502,41,'masterpiece','dire','Gershwins','');
1037
INSERT INTO t2 VALUES (985,246201,41,'however','dub','explorers','');
1038
INSERT INTO t2 VALUES (986,246202,41,'Mendelian','poisoning','libretto','A');
1039
INSERT INTO t2 VALUES (987,246203,41,'jarred','Iraqis','occurred','');
1040
INSERT INTO t2 VALUES (988,246204,41,'scolds','heaving','Lagos','');
1041
INSERT INTO t2 VALUES (989,246205,41,'infatuate','population','rats','');
1042
INSERT INTO t2 VALUES (990,246301,41,'willed','bomb','bankruptcies','A');
1043
INSERT INTO t2 VALUES (991,246302,41,'joyfully','Majorca','crying','');
1044
INSERT INTO t2 VALUES (992,248001,41,'Microsoft','Gershwins','unexpected','');
1045
INSERT INTO t2 VALUES (993,248002,41,'fibrosities','explorers','accessed','A');
1046
INSERT INTO t2 VALUES (994,248003,41,'Baltimorean','libretto','colorful','A');
1047
INSERT INTO t2 VALUES (995,248004,41,'equestrian','occurred','versatility','A');
1048
INSERT INTO t2 VALUES (996,248005,41,'Goodrich','Lagos','cosy','');
1049
INSERT INTO t2 VALUES (997,248006,41,'apish','rats','Darius','A');
1050
INSERT INTO t2 VALUES (998,248007,41,'Adlerian','bankruptcies','mastering','A');
1051
INSERT INTO t2 VALUES (999,248008,41,'Tropez','crying','Asiaticizations','A');
1052
INSERT INTO t2 VALUES (1000,248009,41,'nouns','unexpected','offerers','A');
1053
INSERT INTO t2 VALUES (1001,248010,41,'distracting','accessed','uncles','A');
1054
INSERT INTO t2 VALUES (1002,248011,41,'mutton','colorful','sleepwalk','');
1055
INSERT INTO t2 VALUES (1003,248012,41,'bridgeable','versatility','Ernestine','');
1056
INSERT INTO t2 VALUES (1004,248013,41,'stickers','cosy','checksumming','');
1057
INSERT INTO t2 VALUES (1005,248014,41,'transcontinental','Darius','stopped','');
1058
INSERT INTO t2 VALUES (1006,248015,41,'amateurish','mastering','sicker','');
1059
INSERT INTO t2 VALUES (1007,248016,41,'Gandhian','Asiaticizations','Italianization','');
1060
INSERT INTO t2 VALUES (1008,248017,41,'stratified','offerers','alphabetic','');
1061
INSERT INTO t2 VALUES (1009,248018,41,'chamberlains','uncles','pharmaceutic','');
1062
INSERT INTO t2 VALUES (1010,248019,41,'creditably','sleepwalk','creator','');
1063
INSERT INTO t2 VALUES (1011,248020,41,'philosophic','Ernestine','chess','');
1064
INSERT INTO t2 VALUES (1012,248021,41,'ores','checksumming','charcoal','');
1065
INSERT INTO t2 VALUES (1013,248101,41,'Carleton','stopped','Epiphany','A');
1066
INSERT INTO t2 VALUES (1014,248102,41,'tape','sicker','bulldozes','A');
1067
INSERT INTO t2 VALUES (1015,248201,41,'afloat','Italianization','Pygmalion','A');
1068
INSERT INTO t2 VALUES (1016,248202,41,'goodness','alphabetic','caressing','A');
1069
INSERT INTO t2 VALUES (1017,248203,41,'welcoming','pharmaceutic','Palestine','A');
1070
INSERT INTO t2 VALUES (1018,248204,41,'Pinsky','creator','regimented','A');
1071
INSERT INTO t2 VALUES (1019,248205,41,'halting','chess','scars','A');
1072
INSERT INTO t2 VALUES (1020,248206,41,'bibliography','charcoal','realest','A');
1073
INSERT INTO t2 VALUES (1021,248207,41,'decoding','Epiphany','diffusing','A');
1074
INSERT INTO t2 VALUES (1022,248208,41,'variance','bulldozes','clubroom','A');
1075
INSERT INTO t2 VALUES (1023,248209,41,'allowed','Pygmalion','Blythe','A');
1076
INSERT INTO t2 VALUES (1024,248210,41,'dire','caressing','ahead','');
1077
INSERT INTO t2 VALUES (1025,248211,50,'dub','Palestine','reviver','');
1078
INSERT INTO t2 VALUES (1026,250501,34,'poisoning','regimented','retransmitting','A');
1079
INSERT INTO t2 VALUES (1027,250502,34,'Iraqis','scars','landslide','');
1080
INSERT INTO t2 VALUES (1028,250503,34,'heaving','realest','Eiffel','');
1081
INSERT INTO t2 VALUES (1029,250504,34,'population','diffusing','absentee','');
1082
INSERT INTO t2 VALUES (1030,250505,34,'bomb','clubroom','aye','');
1083
INSERT INTO t2 VALUES (1031,250601,34,'Majorca','Blythe','forked','A');
1084
INSERT INTO t2 VALUES (1032,250602,34,'Gershwins','ahead','Peruvianizes','');
1085
INSERT INTO t2 VALUES (1033,250603,34,'explorers','reviver','clerked','');
1086
INSERT INTO t2 VALUES (1034,250604,34,'libretto','retransmitting','tutor','');
1087
INSERT INTO t2 VALUES (1035,250605,34,'occurred','landslide','boulevard','');
1088
INSERT INTO t2 VALUES (1036,251001,34,'Lagos','Eiffel','shuttered','');
1089
INSERT INTO t2 VALUES (1037,251002,34,'rats','absentee','quotes','A');
1090
INSERT INTO t2 VALUES (1038,251003,34,'bankruptcies','aye','Caltech','');
1091
INSERT INTO t2 VALUES (1039,251004,34,'crying','forked','Mossberg','');
1092
INSERT INTO t2 VALUES (1040,251005,34,'unexpected','Peruvianizes','kept','');
1093
INSERT INTO t2 VALUES (1041,251301,34,'accessed','clerked','roundly','');
1094
INSERT INTO t2 VALUES (1042,251302,34,'colorful','tutor','features','A');
1095
INSERT INTO t2 VALUES (1043,251303,34,'versatility','boulevard','imaginable','A');
1096
INSERT INTO t2 VALUES (1044,251304,34,'cosy','shuttered','controller','');
1097
INSERT INTO t2 VALUES (1045,251305,34,'Darius','quotes','racial','');
1098
INSERT INTO t2 VALUES (1046,251401,34,'mastering','Caltech','uprisings','A');
1099
INSERT INTO t2 VALUES (1047,251402,34,'Asiaticizations','Mossberg','narrowed','A');
1100
INSERT INTO t2 VALUES (1048,251403,34,'offerers','kept','cannot','A');
1101
INSERT INTO t2 VALUES (1049,251404,34,'uncles','roundly','vest','');
1102
INSERT INTO t2 VALUES (1050,251405,34,'sleepwalk','features','famine','');
1103
INSERT INTO t2 VALUES (1051,251406,34,'Ernestine','imaginable','sugars','');
1104
INSERT INTO t2 VALUES (1052,251801,34,'checksumming','controller','exterminated','A');
1105
INSERT INTO t2 VALUES (1053,251802,34,'stopped','racial','belays','');
1106
INSERT INTO t2 VALUES (1054,252101,34,'sicker','uprisings','Hodges','A');
1107
INSERT INTO t2 VALUES (1055,252102,34,'Italianization','narrowed','translatable','');
1108
INSERT INTO t2 VALUES (1056,252301,34,'alphabetic','cannot','duality','A');
1109
INSERT INTO t2 VALUES (1057,252302,34,'pharmaceutic','vest','recording','A');
1110
INSERT INTO t2 VALUES (1058,252303,34,'creator','famine','rouses','A');
1111
INSERT INTO t2 VALUES (1059,252304,34,'chess','sugars','poison','');
1112
INSERT INTO t2 VALUES (1060,252305,34,'charcoal','exterminated','attitude','');
1113
INSERT INTO t2 VALUES (1061,252306,34,'Epiphany','belays','dusted','');
1114
INSERT INTO t2 VALUES (1062,252307,34,'bulldozes','Hodges','encompasses','');
1115
INSERT INTO t2 VALUES (1063,252308,34,'Pygmalion','translatable','presentation','');
1116
INSERT INTO t2 VALUES (1064,252309,34,'caressing','duality','Kantian','');
1117
INSERT INTO t2 VALUES (1065,256001,34,'Palestine','recording','imprecision','A');
1118
INSERT INTO t2 VALUES (1066,256002,34,'regimented','rouses','saving','');
1119
INSERT INTO t2 VALUES (1067,256003,34,'scars','poison','maternal','');
1120
INSERT INTO t2 VALUES (1068,256004,34,'realest','attitude','hewed','');
1121
INSERT INTO t2 VALUES (1069,256005,34,'diffusing','dusted','kerosene','');
1122
INSERT INTO t2 VALUES (1070,258001,34,'clubroom','encompasses','Cubans','');
1123
INSERT INTO t2 VALUES (1071,258002,34,'Blythe','presentation','photographers','');
1124
INSERT INTO t2 VALUES (1072,258003,34,'ahead','Kantian','nymph','A');
1125
INSERT INTO t2 VALUES (1073,258004,34,'reviver','imprecision','bedlam','A');
1126
INSERT INTO t2 VALUES (1074,258005,34,'retransmitting','saving','north','A');
1127
INSERT INTO t2 VALUES (1075,258006,34,'landslide','maternal','Schoenberg','A');
1128
INSERT INTO t2 VALUES (1076,258007,34,'Eiffel','hewed','botany','A');
1129
INSERT INTO t2 VALUES (1077,258008,34,'absentee','kerosene','curs','');
1130
INSERT INTO t2 VALUES (1078,258009,34,'aye','Cubans','solidification','');
1131
INSERT INTO t2 VALUES (1079,258010,34,'forked','photographers','inheritresses','');
1132
INSERT INTO t2 VALUES (1080,258011,34,'Peruvianizes','nymph','stiller','');
1133
INSERT INTO t2 VALUES (1081,258101,68,'clerked','bedlam','t1','A');
1134
INSERT INTO t2 VALUES (1082,258102,68,'tutor','north','suite','A');
1135
INSERT INTO t2 VALUES (1083,258103,34,'boulevard','Schoenberg','ransomer','');
1136
INSERT INTO t2 VALUES (1084,258104,68,'shuttered','botany','Willy','');
1137
INSERT INTO t2 VALUES (1085,258105,68,'quotes','curs','Rena','A');
1138
INSERT INTO t2 VALUES (1086,258106,68,'Caltech','solidification','Seattle','A');
1139
INSERT INTO t2 VALUES (1087,258107,68,'Mossberg','inheritresses','relaxes','A');
1140
INSERT INTO t2 VALUES (1088,258108,68,'kept','stiller','exclaim','');
1141
INSERT INTO t2 VALUES (1089,258109,68,'roundly','t1','implicated','A');
1142
INSERT INTO t2 VALUES (1090,258110,68,'features','suite','distinguish','');
1143
INSERT INTO t2 VALUES (1091,258111,68,'imaginable','ransomer','assayed','');
1144
INSERT INTO t2 VALUES (1092,258112,68,'controller','Willy','homeowner','');
1145
INSERT INTO t2 VALUES (1093,258113,68,'racial','Rena','and','');
1146
INSERT INTO t2 VALUES (1094,258201,34,'uprisings','Seattle','stealth','');
1147
INSERT INTO t2 VALUES (1095,258202,34,'narrowed','relaxes','coinciding','A');
1148
INSERT INTO t2 VALUES (1096,258203,34,'cannot','exclaim','founder','A');
1149
INSERT INTO t2 VALUES (1097,258204,34,'vest','implicated','environing','');
1150
INSERT INTO t2 VALUES (1098,258205,34,'famine','distinguish','jewelry','');
1151
INSERT INTO t2 VALUES (1099,258301,34,'sugars','assayed','lemons','A');
1152
INSERT INTO t2 VALUES (1100,258401,34,'exterminated','homeowner','brokenness','A');
1153
INSERT INTO t2 VALUES (1101,258402,34,'belays','and','bedpost','A');
1154
INSERT INTO t2 VALUES (1102,258403,34,'Hodges','stealth','assurers','A');
1155
INSERT INTO t2 VALUES (1103,258404,34,'translatable','coinciding','annoyers','');
1156
INSERT INTO t2 VALUES (1104,258405,34,'duality','founder','affixed','');
1157
INSERT INTO t2 VALUES (1105,258406,34,'recording','environing','warbling','');
1158
INSERT INTO t2 VALUES (1106,258407,34,'rouses','jewelry','seriously','');
1159
INSERT INTO t2 VALUES (1107,228123,37,'poison','lemons','boasted','');
1160
INSERT INTO t2 VALUES (1108,250606,34,'attitude','brokenness','Chantilly','');
1161
INSERT INTO t2 VALUES (1109,208405,37,'dusted','bedpost','Iranizes','');
1162
INSERT INTO t2 VALUES (1110,212101,37,'encompasses','assurers','violinist','');
1163
INSERT INTO t2 VALUES (1111,218206,37,'presentation','annoyers','extramarital','');
1164
INSERT INTO t2 VALUES (1112,150401,37,'Kantian','affixed','spates','');
1165
INSERT INTO t2 VALUES (1113,248212,41,'imprecision','warbling','cloakroom','');
1166
INSERT INTO t2 VALUES (1114,128026,00,'saving','seriously','gazer','');
1167
INSERT INTO t2 VALUES (1115,128024,00,'maternal','boasted','hand','');
1168
INSERT INTO t2 VALUES (1116,128027,00,'hewed','Chantilly','tucked','');
1169
INSERT INTO t2 VALUES (1117,128025,00,'kerosene','Iranizes','gems','');
1170
INSERT INTO t2 VALUES (1118,128109,00,'Cubans','violinist','clinker','');
1171
INSERT INTO t2 VALUES (1119,128705,00,'photographers','extramarital','refiner','');
1172
INSERT INTO t2 VALUES (1120,126303,00,'nymph','spates','callus','');
1173
INSERT INTO t2 VALUES (1121,128308,00,'bedlam','cloakroom','leopards','');
1174
INSERT INTO t2 VALUES (1122,128204,00,'north','gazer','comfortingly','');
1175
INSERT INTO t2 VALUES (1123,128205,00,'Schoenberg','hand','generically','');
1176
INSERT INTO t2 VALUES (1124,128206,00,'botany','tucked','getters','');
1177
INSERT INTO t2 VALUES (1125,128207,00,'curs','gems','sexually','');
1178
INSERT INTO t2 VALUES (1126,118205,00,'solidification','clinker','spear','');
1179
INSERT INTO t2 VALUES (1127,116801,00,'inheritresses','refiner','serums','');
1180
INSERT INTO t2 VALUES (1128,116803,00,'stiller','callus','Italianization','');
1181
INSERT INTO t2 VALUES (1129,116804,00,'t1','leopards','attendants','');
1182
INSERT INTO t2 VALUES (1130,116802,00,'suite','comfortingly','spies','');
1183
INSERT INTO t2 VALUES (1131,128605,00,'ransomer','generically','Anthony','');
1184
INSERT INTO t2 VALUES (1132,118308,00,'Willy','getters','planar','');
1185
INSERT INTO t2 VALUES (1133,113702,00,'Rena','sexually','cupped','');
1186
INSERT INTO t2 VALUES (1134,113703,00,'Seattle','spear','cleanser','');
1187
INSERT INTO t2 VALUES (1135,112103,00,'relaxes','serums','commuters','');
1188
INSERT INTO t2 VALUES (1136,118009,00,'exclaim','Italianization','honeysuckle','');
1189
INSERT INTO t2 VALUES (5136,1118009,00,'exclaim','Italianization','honeysuckle','');
1190
INSERT INTO t2 VALUES (1137,138011,00,'implicated','attendants','orphanage','');
1191
INSERT INTO t2 VALUES (1138,138010,00,'distinguish','spies','skies','');
1192
INSERT INTO t2 VALUES (1139,138012,00,'assayed','Anthony','crushers','');
1193
INSERT INTO t2 VALUES (1140,068304,00,'homeowner','planar','Puritan','');
1194
INSERT INTO t2 VALUES (1141,078009,00,'and','cupped','squeezer','');
1195
INSERT INTO t2 VALUES (1142,108013,00,'stealth','cleanser','bruises','');
1196
INSERT INTO t2 VALUES (1143,084004,00,'coinciding','commuters','bonfire','');
1197
INSERT INTO t2 VALUES (1144,083402,00,'founder','honeysuckle','Colombo','');
1198
INSERT INTO t2 VALUES (1145,084003,00,'environing','orphanage','nondecreasing','');
1199
INSERT INTO t2 VALUES (1146,088504,00,'jewelry','skies','innocents','');
1200
INSERT INTO t2 VALUES (1147,088005,00,'lemons','crushers','masked','');
1201
INSERT INTO t2 VALUES (1148,088007,00,'brokenness','Puritan','file','');
1202
INSERT INTO t2 VALUES (1149,088006,00,'bedpost','squeezer','brush','');
1203
INSERT INTO t2 VALUES (1150,148025,00,'assurers','bruises','mutilate','');
1204
INSERT INTO t2 VALUES (1151,148024,00,'annoyers','bonfire','mommy','');
1205
INSERT INTO t2 VALUES (1152,138305,00,'affixed','Colombo','bulkheads','');
1206
INSERT INTO t2 VALUES (1153,138306,00,'warbling','nondecreasing','undeclared','');
1207
INSERT INTO t2 VALUES (1154,152701,00,'seriously','innocents','displacements','');
1208
INSERT INTO t2 VALUES (1155,148505,00,'boasted','masked','nieces','');
1209
INSERT INTO t2 VALUES (1156,158003,00,'Chantilly','file','coeducation','');
1210
INSERT INTO t2 VALUES (1157,156201,00,'Iranizes','brush','brassy','');
1211
INSERT INTO t2 VALUES (1158,156202,00,'violinist','mutilate','authenticator','');
1212
INSERT INTO t2 VALUES (1159,158307,00,'extramarital','mommy','Washoe','');
1213
INSERT INTO t2 VALUES (1160,158402,00,'spates','bulkheads','penny','');
1214
INSERT INTO t2 VALUES (1161,158401,00,'cloakroom','undeclared','Flagler','');
1215
INSERT INTO t2 VALUES (1162,068013,00,'gazer','displacements','stoned','');
1216
INSERT INTO t2 VALUES (1163,068012,00,'hand','nieces','cranes','');
1217
INSERT INTO t2 VALUES (1164,068203,00,'tucked','coeducation','masterful','');
1218
INSERT INTO t2 VALUES (1165,088205,00,'gems','brassy','biracial','');
1219
INSERT INTO t2 VALUES (1166,068704,00,'clinker','authenticator','steamships','');
1220
INSERT INTO t2 VALUES (1167,068604,00,'refiner','Washoe','windmills','');
1221
INSERT INTO t2 VALUES (1168,158502,00,'callus','penny','exploit','');
1222
INSERT INTO t2 VALUES (1169,123103,00,'leopards','Flagler','riverfront','');
1223
INSERT INTO t2 VALUES (1170,148026,00,'comfortingly','stoned','sisterly','');
1224
INSERT INTO t2 VALUES (1171,123302,00,'generically','cranes','sharpshoot','');
1225
INSERT INTO t2 VALUES (1172,076503,00,'getters','masterful','mittens','');
1226
INSERT INTO t2 VALUES (1173,126304,00,'sexually','biracial','interdependency','');
1227
INSERT INTO t2 VALUES (1174,068306,00,'spear','steamships','policy','');
1228
INSERT INTO t2 VALUES (1175,143504,00,'serums','windmills','unleashing','');
1229
INSERT INTO t2 VALUES (1176,160201,00,'Italianization','exploit','pretenders','');
1230
INSERT INTO t2 VALUES (1177,148028,00,'attendants','riverfront','overstatements','');
1231
INSERT INTO t2 VALUES (1178,148027,00,'spies','sisterly','birthed','');
1232
INSERT INTO t2 VALUES (1179,143505,00,'Anthony','sharpshoot','opportunism','');
1233
INSERT INTO t2 VALUES (1180,108014,00,'planar','mittens','showroom','');
1234
INSERT INTO t2 VALUES (1181,076104,00,'cupped','interdependency','compromisingly','');
1235
INSERT INTO t2 VALUES (1182,078106,00,'cleanser','policy','Medicare','');
1236
INSERT INTO t2 VALUES (1183,126102,00,'commuters','unleashing','corresponds','');
1237
INSERT INTO t2 VALUES (1184,128029,00,'honeysuckle','pretenders','hardware','');
1238
INSERT INTO t2 VALUES (1185,128028,00,'orphanage','overstatements','implant','');
1239
INSERT INTO t2 VALUES (1186,018410,00,'skies','birthed','Alicia','');
1240
INSERT INTO t2 VALUES (1187,128110,00,'crushers','opportunism','requesting','');
1241
INSERT INTO t2 VALUES (1188,148506,00,'Puritan','showroom','produced','');
1242
INSERT INTO t2 VALUES (1189,123303,00,'squeezer','compromisingly','criticizes','');
1243
INSERT INTO t2 VALUES (1190,123304,00,'bruises','Medicare','backer','');
1244
INSERT INTO t2 VALUES (1191,068504,00,'bonfire','corresponds','positively','');
1245
INSERT INTO t2 VALUES (1192,068305,00,'Colombo','hardware','colicky','');
1246
INSERT INTO t2 VALUES (1193,000000,00,'nondecreasing','implant','thrillingly','');
1247
--enable_query_log
1248
1249
#
1250
# Search with a key
1251
#
1252
1253
select t2.fld3 from t2 where companynr = 58 and fld3 like "%imaginable%";
1254
select fld3 from t2 where fld3 like "%cultivation" ;
1255
1256
#
1257
# Search with a key using sorting and limit the same time
1258
#
1259
1260
select t2.fld3,companynr from t2 where companynr = 57+1 order by fld3;
1261
select fld3,companynr from t2 where companynr = 58 order by fld3;
1262
1263
select fld3 from t2 order by fld3 desc limit 10;
1264
select fld3 from t2 order by fld3 desc limit 5;
1265
select fld3 from t2 order by fld3 desc limit 5,5;
1266
1267
#
1268
# Search with a key having a constant with each unique key.
1269
# The table is read directly with read-next on fld3
1270
#
1271
1272
select t2.fld3 from t2 where fld3 = 'honeysuckle';
1273
select t2.fld3 from t2 where fld3 LIKE 'honeysuckl_';
1274
select t2.fld3 from t2 where fld3 LIKE 'hon_ysuckl_';
1275
select t2.fld3 from t2 where fld3 LIKE 'honeysuckle%';
1276
select t2.fld3 from t2 where fld3 LIKE 'h%le';
1277
1278
select t2.fld3 from t2 where fld3 LIKE 'honeysuckle_';
1279
select t2.fld3 from t2 where fld3 LIKE 'don_t_find_me_please%';
1280
1281
#
1282
# Test using INDEX and IGNORE INDEX
1283
#
1284
201 by Brian Aker
Convert default engine to Innodb
1285
#explain select t2.fld3 from t2 where fld3 = 'honeysuckle';
1286
1287
#explain select fld3 from t2 ignore index (fld3) where fld3 = 'honeysuckle';
1288
#explain select fld3 from t2 use index (fld1) where fld3 = 'honeysuckle';
1289
1290
#explain select fld3 from t2 use index (fld3) where fld3 = 'honeysuckle';
1291
#explain select fld3 from t2 use index (fld1,fld3) where fld3 = 'honeysuckle';
1 by brian
clean slate
1292
1293
#
1294
# NOTE NOTE NOTE
1295
# The next should give an error
1296
#
1297
201 by Brian Aker
Convert default engine to Innodb
1298
#-- error 1176
1299
#explain select fld3 from t2 ignore index (fld3,not_used);
1300
#-- error 1176
1301
#explain select fld3 from t2 use index (not_used);
1 by brian
clean slate
1302
1303
#
1304
# Test sorting with a used key (there is no need for sorting)
1305
#
1306
1307
select t2.fld3 from t2 where fld3 >= 'honeysuckle' and fld3 <= 'honoring' order by fld3;
201 by Brian Aker
Convert default engine to Innodb
1308
#explain select t2.fld3 from t2 where fld3 >= 'honeysuckle' and fld3 <= 'honoring' order by fld3;
1 by brian
clean slate
1309
select fld1,fld3 from t2 where fld3="Colombo" or fld3 = "nondecreasing" order by fld3;
1310
1311
# 
1312
# Search with a key having a constant with many occurrences
1313
# The table is read directly with read-next having fld3 to get the
1314
# occurrences
1315
#
1316
1317
select fld1,fld3 from t2 where companynr = 37 and fld3 = 'appendixes';
1318
1319
#
1320
# Search with bunched 'or's.
1321
# If one can limit the key to a certain interval only the possible
1322
# alternatives will be gone through
1323
#
1324
1325
select fld1 from t2 where fld1=250501 or fld1="250502";
201 by Brian Aker
Convert default engine to Innodb
1326
#explain select fld1 from t2 where fld1=250501 or fld1="250502"; 
1 by brian
clean slate
1327
select fld1 from t2 where fld1=250501 or fld1=250502 or fld1 >= 250505 and fld1 <= 250601 or fld1 between 250501 and 250502;
201 by Brian Aker
Convert default engine to Innodb
1328
#explain select fld1 from t2 where fld1=250501 or fld1=250502 or fld1 >= 250505 and fld1 <= 250601 or fld1 between 250501 and 250502;
1 by brian
clean slate
1329
1330
#
1331
# Search with a key with LIKE constant
1332
# If the like starts with a certain letter key will be used.
1333
#
1334
496.1.2 by Paul McCullagh
Changes to .test files to run both PBXT and InnoDB
1335
--sorted_result
1 by brian
clean slate
1336
select fld1,fld3 from t2 where companynr = 37 and fld3 like 'f%';
1337
select fld3 from t2 where fld3 like "L%" and fld3 = "ok";
1338
select fld3 from t2 where (fld3 like "C%" and fld3 = "Chantilly");
1339
select fld1,fld3 from t2 where fld1 like "25050%";
1340
select fld1,fld3 from t2 where fld1 like "25050_";
1341
1342
# 
1343
# Search using distinct. An automatic grouping will be done over all the fields,
1344
# if only distinct is used. In any other case a temporary table will always
1345
# be created. If only the field used for sorting is from the main register,
1346
# it will be sorted first before the distinct table is created.
1347
#
1348
1349
select distinct companynr from t2;
1350
select distinct companynr from t2 order by companynr;
1351
select distinct companynr from t2 order by companynr desc;
496.1.2 by Paul McCullagh
Changes to .test files to run both PBXT and InnoDB
1352
--sorted_result
1 by brian
clean slate
1353
select distinct t2.fld3,period from t2,t1 where companynr=37 and fld3 like "O%";
1354
1355
select distinct fld3 from t2 where companynr = 34 order by fld3;
496.1.2 by Paul McCullagh
Changes to .test files to run both PBXT and InnoDB
1356
# PBXT: because there is no ORDER BY with a LIMIT, these
1357
# statements return different results to those from innodb
1358
--sorted_result
1 by brian
clean slate
1359
select distinct fld3 from t2 limit 10;
1360
select distinct fld3 from t2 having fld3 like "A%" limit 10;
1361
select distinct substring(fld3,1,3) from t2 where fld3 like "A%";
1362
select distinct substring(fld3,1,3) as a from t2 having a like "A%" order by a limit 10;
1363
select distinct substring(fld3,1,3) from t2 where fld3 like "A%" limit 10;
496.1.2 by Paul McCullagh
Changes to .test files to run both PBXT and InnoDB
1364
--sorted_result
1 by brian
clean slate
1365
select distinct substring(fld3,1,3) as a from t2 having a like "A%" limit 10;
1366
1367
# make a big table.
1368
1369
create table t3 (
1370
 period    int not null,
1371
 name      char(32) not null,
1372
 companynr int not null,
1373
 price     double(11,0),
1374
 price2     double(11,0),
1375
 key (period),
1376
 key (name)
1377
);
1378
1379
--disable_query_log
1380
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1001,"Iranizes",37,5987435,234724);
1381
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1002,"violinist",37,28357832,8723648);
1382
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1003,"extramarital",37,39654943,235872);
1383
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1004,"spates",78,726498,72987523);
1384
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1005,"cloakroom",78,98439034,823742);
1385
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1006,"gazer",101,834598,27348324);
1386
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1007,"hand",154,983543950,29837423);
1387
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1008,"tucked",311,234298,3275892);
1388
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1009,"gems",447,2374834,9872392);
1389
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1010,"clinker",512,786542,76234234);
1390
--enable_query_log
1391
1392
create temporary table tmp engine = myisam select * from t3;
1393
1394
insert into t3 select * from tmp;
1395
insert into tmp select * from t3;
1396
insert into t3 select * from tmp;
1397
insert into tmp select * from t3;
1398
insert into t3 select * from tmp;
1399
insert into tmp select * from t3;
1400
insert into t3 select * from tmp;
1401
insert into tmp select * from t3;
1402
insert into t3 select * from tmp;
1403
insert into tmp select * from t3;
1404
insert into t3 select * from tmp;
1405
insert into tmp select * from t3;
1406
insert into t3 select * from tmp;
1407
insert into tmp select * from t3;
1408
insert into t3 select * from tmp;
1409
insert into tmp select * from t3;
1410
insert into t3 select * from tmp;
1411
#insert into tmp select * from t3;
1412
#insert into t3 select * from tmp;
1413
1414
alter table t3 add t2nr int not null auto_increment primary key first;
1415
1416
drop table tmp;
1417
1418
# big table done
1419
1420
select distinct concat(fld3," ",fld3) as namn from t2,t3 where t2.fld1=t3.t2nr order by namn limit 10;
1421
select distinct concat(fld3," ",fld3) from t2,t3 where t2.fld1=t3.t2nr order by fld3 limit 10;
1422
select distinct fld5 from t2 limit 10;
1423
1424
#
1425
# Force use of remove_dupp
1426
#
1427
1428
select distinct fld3,count(*) from t2 group by companynr,fld3 limit 10;
1429
select distinct fld3,count(*) from t2 group by companynr,fld3 limit 10;
1430
select distinct fld3,repeat("a",length(fld3)),count(*) from t2 group by companynr,fld3 limit 100,10;
1431
1432
#
1433
# A big order by that should trigger a merge in filesort
1434
#
1435
1436
select distinct companynr,rtrim(space(512+companynr)) from t3 order by 1,2;
1437
1438
#
1439
# Search with distinct and order by with many table.
1440
#
1441
1442
select distinct fld3 from t2,t3 where t2.companynr = 34 and t2.fld1=t3.t2nr order by fld3;
1443
1444
#
1445
# Here the last fld3 is optimized away from the order by
1446
#
1447
201 by Brian Aker
Convert default engine to Innodb
1448
#explain select t3.t2nr,fld3 from t2,t3 where t2.companynr = 34 and t2.fld1=t3.t2nr order by t3.t2nr,fld3;
1 by brian
clean slate
1449
1450
#
1451
# Some test with ORDER BY and limit
1452
#
1453
201 by Brian Aker
Convert default engine to Innodb
1454
#explain select * from t3 as t1,t3 where t1.period=t3.period order by t3.period;
1455
#explain select * from t3 as t1,t3 where t1.period=t3.period order by t3.period limit 10;
1456
#explain select * from t3 as t1,t3 where t1.period=t3.period order by t1.period limit 10;
1 by brian
clean slate
1457
1458
#
1459
# Search with a constant table.
1460
#
1461
1462
select period from t1;
1463
select period from t1 where period=1900;
1464
select fld3,period from t1,t2 where fld1 = 011401 order by period;
1465
1466
#
1467
# Search with a constant table and several keyparts. (Rows are read only once
1468
# in the beginning of the search)
1469
#
1470
1471
select fld3,period from t2,t3 where t2.fld1 = 011401 and t2.fld1=t3.t2nr and t3.period=1001;
1472
201 by Brian Aker
Convert default engine to Innodb
1473
#explain select fld3,period from t2,t3 where t2.fld1 = 011401 and t3.t2nr=t2.fld1 and 1001 = t3.period;
1 by brian
clean slate
1474
1475
#
1476
# Search with a constant table and several rows from another table
1477
#
1478
496.1.2 by Paul McCullagh
Changes to .test files to run both PBXT and InnoDB
1479
--sorted_result
1 by brian
clean slate
1480
select fld3,period from t2,t1 where companynr*10 = 37*10;
1481
1482
#
1483
# Search with a table reference and without a key.
1484
# t3 will be the main table.
1485
#
1486
1487
select fld3,period,price,price2 from t2,t3 where t2.fld1=t3.t2nr and period >= 1001 and period <= 1002 and t2.companynr = 37 order by fld3,period, price;
1488
1489
#
1490
# Search with an interval on a table with full key on reference table.
1491
# Here t2 will be the main table and only records matching the
1492
# t2nr will be checked.
1493
#
1494
1495
select t2.fld1,fld3,period,price,price2 from t2,t3 where t2.fld1>= 18201 and t2.fld1 <= 18811 and t2.fld1=t3.t2nr and period = 1001 and t2.companynr = 37;
1496
1497
#
1498
# We need another table for join stuff..
1499
#
1500
1501
create table t4 (
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
1502
  companynr int NOT NULL default '0',
1 by brian
clean slate
1503
  companyname char(30) NOT NULL default '',
1504
  PRIMARY KEY (companynr),
1505
  UNIQUE KEY companyname(companyname)
1506
) ENGINE=MyISAM MAX_ROWS=50 PACK_KEYS=1 COMMENT='companynames';
1507
1508
--disable_query_log
1509
INSERT INTO t4 (companynr, companyname) VALUES (29,'company 1');
1510
INSERT INTO t4 (companynr, companyname) VALUES (34,'company 2');
1511
INSERT INTO t4 (companynr, companyname) VALUES (36,'company 3');
1512
INSERT INTO t4 (companynr, companyname) VALUES (37,'company 4');
1513
INSERT INTO t4 (companynr, companyname) VALUES (40,'company 5');
1514
INSERT INTO t4 (companynr, companyname) VALUES (41,'company 6');
1515
INSERT INTO t4 (companynr, companyname) VALUES (53,'company 7');
1516
INSERT INTO t4 (companynr, companyname) VALUES (58,'company 8');
1517
INSERT INTO t4 (companynr, companyname) VALUES (65,'company 9');
1518
INSERT INTO t4 (companynr, companyname) VALUES (68,'company 10');
1519
INSERT INTO t4 (companynr, companyname) VALUES (50,'company 11');
1520
INSERT INTO t4 (companynr, companyname) VALUES (00,'Unknown');
1521
--enable_query_log
1522
1523
#
1524
# Test of stright join to force a full join.
1525
#
1526
1527
select STRAIGHT_JOIN t2.companynr,companyname from t4,t2 where t2.companynr=t4.companynr group by t2.companynr;
1528
1529
select SQL_SMALL_RESULT t2.companynr,companyname from t4,t2 where t2.companynr=t4.companynr group by t2.companynr;
1530
1531
#
1532
# Full join (same alias)
1533
#
1534
1535
select * from t1,t1 t12;
1536
select t2.fld1,t22.fld1 from t2,t2 t22 where t2.fld1 >= 250501 and t2.fld1 <= 250505 and t22.fld1 >= 250501 and t22.fld1 <= 250505;
1537
1538
#
1539
# Test of left join.
1540
#
1541
insert into t2 (fld1, companynr) values (999999,99);
1542
1543
select t2.companynr,companyname from t2 left join t4 using (companynr) where t4.companynr is null;
1544
select count(*) from t2 left join t4 using (companynr) where t4.companynr is not null;
201 by Brian Aker
Convert default engine to Innodb
1545
#explain select t2.companynr,companyname from t2 left join t4 using (companynr) where t4.companynr is null;
1546
#explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr is null;
1 by brian
clean slate
1547
1548
select companynr,companyname from t2 left join t4 using (companynr) where companynr is null;
1549
select count(*) from t2 left join t4 using (companynr) where companynr is not null;
201 by Brian Aker
Convert default engine to Innodb
1550
#explain select companynr,companyname from t2 left join t4 using (companynr) where companynr is null;
1551
#explain select companynr,companyname from t4 left join t2 using (companynr) where companynr is null;
1 by brian
clean slate
1552
delete from t2 where fld1=999999;
1553
1554
#
1555
# Test left join optimization
1556
201 by Brian Aker
Convert default engine to Innodb
1557
#explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0;
1558
#explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0 or t2.companynr < 0;
1559
#explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0 and t4.companynr > 0;
1560
#
1561
#explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0;
1562
#explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0 or companynr < 0;
1563
#explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0 and companynr > 0;
1564
## Following can't be optimized
1565
#explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0 or t2.companynr is null;
1566
#explain select t2.companynr,companyname from t4 left join t2 using (companynr) where t2.companynr > 0 or t2.companynr < 0 or t4.companynr > 0;
1567
#explain select t2.companynr,companyname from t4 left join t2 using (companynr) where ifnull(t2.companynr,1)>0;
1568
#
1569
#explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0 or companynr is null;
1570
#explain select companynr,companyname from t4 left join t2 using (companynr) where companynr > 0 or companynr < 0 or companynr > 0;
1571
#explain select companynr,companyname from t4 left join t2 using (companynr) where ifnull(companynr,1)>0;
1 by brian
clean slate
1572
1573
#
1574
# Joins with forms.
1575
#
1576
1577
select distinct t2.companynr,t4.companynr from t2,t4 where t2.companynr=t4.companynr+1;
201 by Brian Aker
Convert default engine to Innodb
1578
#explain select distinct t2.companynr,t4.companynr from t2,t4 where t2.companynr=t4.companynr+1;
1 by brian
clean slate
1579
1580
#
1581
# Search using 'or' with the same referens group.
1582
# An interval search will be done first with the first table and after that
1583
# the other table is referenced with a key with a 'test if key in use' for
1584
# each record
1585
#
1586
1587
select t2.fld1,t2.companynr,fld3,period from t3,t2 where t2.fld1 = 38208 and t2.fld1=t3.t2nr and period = 1008 or t2.fld1 = 38008 and t2.fld1 =t3.t2nr and period = 1008;
1588
1589
select t2.fld1,t2.companynr,fld3,period from t3,t2 where (t2.fld1 = 38208 or t2.fld1 = 38008) and t2.fld1=t3.t2nr and period>=1008 and period<=1009;
1590
1591
select t2.fld1,t2.companynr,fld3,period from t3,t2 where (t3.t2nr = 38208 or t3.t2nr = 38008) and t2.fld1=t3.t2nr and period>=1008 and period<=1009;
1592
1593
#
1594
# Test of many parenthesis levels
1595
#
1596
1597
select period from t1 where (((period > 0) or period < 10000 or (period = 1900)) and (period=1900 and period <= 1901) or (period=1903 and (period=1903)) and period>=1902) or ((period=1904 or period=1905) or (period=1906 or period>1907)) or (period=1908 and period = 1909);
1598
select period from t1 where ((period > 0 and period < 1) or (((period > 0 and period < 100) and (period > 10)) or (period > 10)) or (period > 0 and (period > 5 or period > 6)));
1599
1600
select a.fld1 from t2 as a,t2 b where ((a.fld1 = 250501 and a.fld1=b.fld1) or a.fld1=250502 or a.fld1=250503 or (a.fld1=250505 and a.fld1<=b.fld1 and b.fld1>=a.fld1)) and a.fld1=b.fld1;
1601
1602
select fld1 from t2 where fld1 in (250502,98005,98006,250503,250605,250606) and fld1 >=250502 and fld1 not in (250605,250606);
1603
1604
select fld1 from t2 where fld1 between 250502 and 250504;
1605
1606
select fld3 from t2 where (((fld3 like "_%L%" ) or (fld3 like "%ok%")) and ( fld3 like "L%" or fld3 like "G%")) and fld3 like "L%" ;
1607
1608
#
1609
# Group on one table.
1610
# optimizer: sort table by group and send rows.
1611
#
1612
1613
select count(*) from t1;
1614
select companynr,count(*),sum(fld1) from t2 group by companynr;
1615
select companynr,count(*) from t2 group by companynr order by companynr desc limit 5;
1616
select count(*),min(fld4),max(fld4),sum(fld1),avg(fld1),std(fld1),variance(fld1) from t2 where companynr = 34 and fld4<>"";
201 by Brian Aker
Convert default engine to Innodb
1617
#explain extended select count(*),min(fld4),max(fld4),sum(fld1),avg(fld1),std(fld1),variance(fld1) from t2 where companynr = 34 and fld4<>"";
1 by brian
clean slate
1618
select companynr,count(*),min(fld4),max(fld4),sum(fld1),avg(fld1),std(fld1),variance(fld1) from t2 group by companynr limit 3;
1619
select companynr,t2nr,count(price),sum(price),min(price),max(price),avg(price) from t3 where companynr = 37 group by companynr,t2nr limit 10;
1620
select /*! SQL_SMALL_RESULT */ companynr,t2nr,count(price),sum(price),min(price),max(price),avg(price) from t3 where companynr = 37 group by companynr,t2nr limit 10;
1621
select companynr,count(price),sum(price),min(price),max(price),avg(price) from t3 group by companynr ;
1622
select distinct mod(companynr,10) from t4 group by companynr;
1623
select distinct 1 from t4 group by companynr;
1624
select count(distinct fld1) from t2;
1625
select companynr,count(distinct fld1) from t2 group by companynr;
1626
select companynr,count(*) from t2 group by companynr;
1627
select companynr,count(distinct concat(fld1,repeat(65,1000))) from t2 group by companynr;
1628
select companynr,count(distinct concat(fld1,repeat(65,200))) from t2 group by companynr;
1629
select companynr,count(distinct floor(fld1/100)) from t2 group by companynr;
1630
select companynr,count(distinct concat(repeat(65,1000),floor(fld1/100))) from t2 group by companynr;
1631
1632
#
1633
# group with where on a key field
1634
#
1635
1636
select sum(fld1),fld3 from t2 where fld3="Romans" group by fld1 limit 10;
1637
select name,count(*) from t3 where name='cloakroom' group by name;
1638
select name,count(*) from t3 where name='cloakroom' and price>10 group by name;
1639
select count(*) from t3 where name='cloakroom' and price2=823742;
1640
select name,count(*) from t3 where name='cloakroom' and price2=823742 group by name;
1641
select name,count(*) from t3 where name >= "extramarital" and price <= 39654943 group by name;
1642
select t2.fld3,count(*) from t2,t3 where t2.fld1=158402 and t3.name=t2.fld3 group by t3.name;
1643
1644
#
1645
# Group with extra not group fields.
1646
#
1647
257 by Brian Aker
Removed ALTER TABLE UPGRADE.
1648
select companynr,companyname from t4 group by 1;
1 by brian
clean slate
1649
select t2.companynr,companyname,count(*) from t2,t4 where t2.companynr=t4.companynr group by t2.companynr order by companyname;
1650
select t2.fld1,count(*) from t2,t3 where t2.fld1=158402 and t3.name=t2.fld3 group by t3.name;
1651
1652
#
1653
# Calculation with group functions
1654
#
1655
1656
select sum(Period)/count(*) from t1;
1657
select companynr,count(price) as "count",sum(price) as "sum" ,abs(sum(price)/count(price)-avg(price)) as "diff",(0+count(price))*companynr as func from t3 group by companynr;
1658
select companynr,sum(price)/count(price) as avg from t3 group by companynr having avg > 70000000 order by avg;
1659
1660
#
1661
# Group with order on not first table
1662
# optimizer: sort table by group and write group records to tmp table.
1663
#            sort tmp_table and send rows.
1664
#
1665
1666
select companynr,count(*) from t2 group by companynr order by 2 desc;
1667
select companynr,count(*) from t2 where companynr > 40 group by companynr order by 2 desc;
1668
select t2.fld4,t2.fld1,count(price),sum(price),min(price),max(price),avg(price) from t3,t2 where t3.companynr = 37 and t2.fld1 = t3.t2nr group by fld1,t2.fld4;
1669
1670
#
1671
# group by with many tables
1672
# optimizer: create tmp table with group-by uniq index.
1673
#           write with update to tmp table.
1674
#           sort tmp table according to order (or group if no order)
1675
#	    send rows
1676
#
1677
1678
select t3.companynr,fld3,sum(price) from t3,t2 where t2.fld1 = t3.t2nr and t3.companynr = 512 group by companynr,fld3;
1679
select t2.companynr,count(*),min(fld3),max(fld3),sum(price),avg(price) from t2,t3 where t3.companynr >= 30 and t3.companynr <= 58 and t3.t2nr = t2.fld1 and 1+1=2 group by t2.companynr;
1680
1681
#
1682
# group with many tables and long group on many tables. group on formula
1683
# optimizer: create tmp table with neaded fields
1684
#           sort tmp table by group and calculate sums to new table
1685
#	    if different order by than group, sort tmp table
1686
#	    send rows
1687
#
1688
1689
select t3.companynr+0,t3.t2nr,fld3,sum(price) from t3,t2 where t2.fld1 = t3.t2nr and t3.companynr = 37 group by 1,t3.t2nr,fld3,fld3,fld3,fld3,fld3 order by fld1;
1690
1691
#
1692
# WHERE const folding
1693
# optimize: If there is a "field = const" part in the where, change all
1694
#           instances of field in the and level to const.
1695
#	    All instances of const = const are checked once and removed.
1696
#
1697
1698
#
1699
# Where -> t3.t2nr = 98005 and t2.fld1 = 98005
1700
#
1701
1702
select sum(price) from t3,t2 where t2.fld1 = t3.t2nr and t3.companynr = 512 and t3.t2nr = 38008 and t2.fld1 = 38008 or t2.fld1= t3.t2nr and t3.t2nr = 38008 and t2.fld1 = 38008;
1703
1704
select t2.fld1,sum(price) from t3,t2 where t2.fld1 = t3.t2nr and t3.companynr = 512 and t3.t2nr = 38008 and t2.fld1 = 38008 or t2.fld1 = t3.t2nr and t3.t2nr = 38008 and t2.fld1 = 38008 or t3.t2nr = t2.fld1 and t2.fld1 = 38008 group by t2.fld1;
1705
201 by Brian Aker
Convert default engine to Innodb
1706
#explain select fld3 from t2 where 1>2 or 2>3;
1707
#explain select fld3 from t2 where fld1=fld1;
1 by brian
clean slate
1708
1709
#
1710
# HAVING
1711
#
1712
1713
select companynr,fld1 from t2 HAVING fld1=250501 or fld1=250502; 
1714
select companynr,fld1 from t2 WHERE fld1>=250501 HAVING fld1<=250502;
1715
select companynr,count(*) as count,sum(fld1) as sum from t2 group by companynr having count > 40 and sum/count >= 120000;
1716
select companynr from t2 group by companynr having count(*) > 40 and sum(fld1)/count(*) >= 120000 ;
1717
select t2.companynr,companyname,count(*) from t2,t4 where t2.companynr=t4.companynr group by companyname having t2.companynr >= 40;
1718
1719
#
1720
# MIN(), MAX() and COUNT() optimizing
1721
#
1722
1723
select count(*) from t2;
1724
select count(*) from t2 where fld1 < 098024;
1725
# PS does correct pre-zero here. MySQL can't do it as it returns a number.
1726
--disable_ps_protocol
1727
select min(fld1) from t2 where fld1>= 098024;
1728
--enable_ps_protocol
1729
select max(fld1) from t2 where fld1>= 098024;
1730
select count(*) from t3 where price2=76234234;
1731
select count(*) from t3 where companynr=512 and price2=76234234;
201 by Brian Aker
Convert default engine to Innodb
1732
#explain select min(fld1),max(fld1),count(*) from t2;
1 by brian
clean slate
1733
# PS does correct pre-zero here. MySQL can't do it as it returns a number.
1734
--disable_ps_protocol
1735
select min(fld1),max(fld1),count(*) from t2;
1736
--enable_ps_protocol
1737
select min(t2nr),max(t2nr) from t3 where t2nr=2115 and price2=823742;
1738
select count(*),min(t2nr),max(t2nr) from t3 where name='spates' and companynr=78;
1739
select t2nr,count(*) from t3 where name='gems' group by t2nr limit 20;
1740
select max(t2nr) from t3 where price=983543950;
1741
1742
#
1743
# Test of alias
1744
#
1745
1746
select t1.period from t3 = t1 limit 1;
1747
select t1.period from t1 as t1 limit 1;
1748
select t1.period as "Nuvarande period" from t1 as t1 limit 1;
1749
select period as ok_period from t1 limit 1;
1750
select period as ok_period from t1 group by ok_period limit 1;
1751
select 1+1 as summa from t1 group by summa limit 1;
1752
select period as "Nuvarande period" from t1 group by "Nuvarande period" limit 1;
1753
1754
#
1755
# Some simple show commands
1756
#
1757
1758
show tables;
1759
show tables from test like "s%";
1760
show tables from test like "t?";
1761
# We mask out the Privileges column because it differs with embedded server
1762
--replace_column 8 #
1763
show full columns from t2;
1764
--replace_column 8 #
1765
show full columns from t2 from test like 'f%';
1766
--replace_column 8 #
1767
show full columns from t2 from test like 's%';
201 by Brian Aker
Convert default engine to Innodb
1768
#show keys from t2;
1 by brian
clean slate
1769
1770
drop table t4, t3, t2, t1;
1771
1772
#
1773
# random in WHERE clause
1774
#
1775
1776
CREATE TABLE t1 (
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
1777
  id bigint NOT NULL auto_increment,
1 by brian
clean slate
1778
  pseudo varchar(35) NOT NULL default '',
1779
  PRIMARY KEY  (id),
1780
  UNIQUE KEY pseudo (pseudo)
1781
);
1782
INSERT INTO t1 (pseudo) VALUES ('test');
1783
INSERT INTO t1 (pseudo) VALUES ('test1');
1784
SELECT 1 as rnd1 from t1 where rand() > 2;
1785
DROP TABLE t1;
1786
1787
#
1788
# Test of bug with SUM(CASE...)
1789
#
1790
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
1791
CREATE TABLE t1 (gvid int default NULL,  hmid int default NULL,  volid int default NULL,  mmid int default NULL,  hdid int default NULL,  fsid int default NULL,  ctid int default NULL,  dtid int default NULL,  cost int default NULL,  performance int default NULL,  serialnumber bigint default NULL,  monitored int default '1',  removed int default '0',  target int default '0',  dt_modified timestamp NOT NULL,  name varchar(255) binary default NULL,  description varchar(255) default NULL,  UNIQUE KEY hmid (hmid,volid)) ENGINE=MyISAM;
1 by brian
clean slate
1792
INSERT INTO t1 VALUES (200001,2,1,1,100,1,1,1,0,0,0,1,0,1,20020425060057,'\\\\ARKIVIO-TESTPDC\\E$',''),(200002,2,2,1,101,1,1,1,0,0,0,1,0,1,20020425060057,'\\\\ARKIVIO-TESTPDC\\C$',''),(200003,1,3,2,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,1,20020425060427,'c:',NULL);
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
1793
CREATE TABLE t2 (  hmid int default NULL,  volid int default NULL,  sampletid int default NULL,  sampletime datetime default NULL,  samplevalue bigint default NULL,  KEY idx1 (hmid,volid,sampletid,sampletime)) ENGINE=MyISAM;
1 by brian
clean slate
1794
INSERT INTO t2 VALUES (1,3,10,'2002-06-01 08:00:00',35),(1,3,1010,'2002-06-01 12:00:01',35);
1795
# Disable PS becasue we get more warnings from PS than from normal execution
1796
--disable_ps_protocol
1797
SELECT a.gvid, (SUM(CASE b.sampletid WHEN 140 THEN b.samplevalue ELSE 0 END)) as the_success,(SUM(CASE b.sampletid WHEN 141 THEN b.samplevalue ELSE 0 END)) as the_fail,(SUM(CASE b.sampletid WHEN 142 THEN b.samplevalue ELSE 0 END)) as the_size,(SUM(CASE b.sampletid WHEN 143 THEN b.samplevalue ELSE 0 END)) as the_time FROM t1 a, t2 b WHERE a.hmid = b.hmid AND a.volid = b.volid AND b.sampletime >= 'wrong-date-value' AND b.sampletime < 'wrong-date-value' AND b.sampletid IN (140, 141, 142, 143) GROUP BY a.gvid;
1798
--enable_ps_protocol
1799
# Testing the same select with NULL's instead of invalid datetime values
1800
SELECT a.gvid, (SUM(CASE b.sampletid WHEN 140 THEN b.samplevalue ELSE 0 END)) as the_success,(SUM(CASE b.sampletid WHEN 141 THEN b.samplevalue ELSE 0 END)) as the_fail,(SUM(CASE b.sampletid WHEN 142 THEN b.samplevalue ELSE 0 END)) as the_size,(SUM(CASE b.sampletid WHEN 143 THEN b.samplevalue ELSE 0 END)) as the_time FROM t1 a, t2 b WHERE a.hmid = b.hmid AND a.volid = b.volid AND b.sampletime >= NULL AND b.sampletime < NULL AND b.sampletid IN (140, 141, 142, 143) GROUP BY a.gvid;
1801
DROP TABLE t1,t2;
1802
1803
#
1804
# Test of bigint comparision
1805
#
1806
223 by Brian Aker
Cleanup int() work.
1807
create table  t1 (  A_Id bigint NOT NULL default '0',  A_UpdateBy char(10) NOT NULL default '',  A_UpdateDate bigint NOT NULL default '0',  A_UpdateSerial int NOT NULL default '0',  other_types bigint NOT NULL default '0',  wss_type bigint NOT NULL default '0');
1 by brian
clean slate
1808
INSERT INTO t1 VALUES (102935998719055004,'brade',1029359987,2,102935229116544068,102935229216544093);
1809
select wss_type from t1 where wss_type ='102935229216544106';
1810
select wss_type from t1 where wss_type ='102935229216544105';
1811
select wss_type from t1 where wss_type ='102935229216544104';
1812
select wss_type from t1 where wss_type ='102935229216544093';
1813
select wss_type from t1 where wss_type =102935229216544093;
1814
drop table t1;
1815
select 1+2,"aaaa",3.13*2.0 into @a,@b,@c;
1816
select @a;
1817
select @b;
1818
select @c;
1819
1820
#
1821
# Test of removing redundant braces in the FROM part
1822
# (We test each construct with the braced join to the left and right;
1823
#  the latter case used to cause a syntax errors.)
1824
#
1825
1826
create table t1 (a int not null auto_increment primary key);
1827
insert into t1 values ();
1828
insert into t1 values ();
1829
insert into t1 values ();
1830
# ,
1831
select * from (t1 as t2 left join t1 as t3 using (a)), t1;
1832
select * from t1, (t1 as t2 left join t1 as t3 using (a));
1833
# stright_join
1834
select * from (t1 as t2 left join t1 as t3 using (a)) straight_join t1;
1835
select * from t1 straight_join (t1 as t2 left join t1 as t3 using (a));
1836
# inner join on
496.1.2 by Paul McCullagh
Changes to .test files to run both PBXT and InnoDB
1837
--sorted_result
1 by brian
clean slate
1838
select * from (t1 as t2 left join t1 as t3 using (a)) inner join t1 on t1.a>1;
1839
select * from t1 inner join (t1 as t2 left join t1 as t3 using (a)) on t1.a>1;
1840
# inner join using
1841
select * from (t1 as t2 left join t1 as t3 using (a)) inner join t1 using ( a );
1842
select * from t1 inner join (t1 as t2 left join t1 as t3 using (a)) using ( a );
1843
# left [outer] join on
1844
select * from (t1 as t2 left join t1 as t3 using (a)) left outer join t1 on t1.a>1;
1845
select * from t1 left outer join (t1 as t2 left join t1 as t3 using (a)) on t1.a>1;
1846
# left join using
1847
select * from (t1 as t2 left join t1 as t3 using (a)) left join t1 using ( a );
1848
select * from t1 left join (t1 as t2 left join t1 as t3 using (a)) using ( a );
1849
# natural left join
1850
select * from (t1 as t2 left join t1 as t3 using (a)) natural left join t1;
1851
select * from t1 natural left join (t1 as t2 left join t1 as t3 using (a));
1852
# right join on
1853
select * from (t1 as t2 left join t1 as t3 using (a)) right join t1 on t1.a>1;
1854
select * from t1 right join (t1 as t2 left join t1 as t3 using (a)) on t1.a>1;
1855
# right [outer] joing using
1856
select * from (t1 as t2 left join t1 as t3 using (a)) right outer join t1 using ( a );
1857
select * from t1 right outer join (t1 as t2 left join t1 as t3 using (a)) using ( a );
1858
# natural right join
1859
select * from (t1 as t2 left join t1 as t3 using (a)) natural right join t1;
1860
select * from t1 natural right join (t1 as t2 left join t1 as t3 using (a));
1861
# natural join
1862
select * from t1 natural join (t1 as t2 left join t1 as t3 using (a));
1863
select * from (t1 as t2 left join t1 as t3 using (a)) natural join t1;
1864
drop table t1;
1865
223 by Brian Aker
Cleanup int() work.
1866
CREATE TABLE t1 (  aa char(2),  id int NOT NULL auto_increment,  t2_id int NOT NULL default '0',  PRIMARY KEY  (id),  KEY replace_id (t2_id)) ENGINE=MyISAM;
1 by brian
clean slate
1867
INSERT INTO t1 VALUES ("1",8264,2506),("2",8299,2517),("3",8301,2518),("4",8302,2519),("5",8303,2520),("6",8304,2521),("7",8305,2522);
223 by Brian Aker
Cleanup int() work.
1868
CREATE TABLE t2 ( id int NOT NULL auto_increment,  PRIMARY KEY  (id)) ENGINE=MyISAM;
1 by brian
clean slate
1869
INSERT INTO t2 VALUES (2517), (2518), (2519), (2520), (2521), (2522);
1870
select * from t1, t2 WHERE t1.t2_id = t2.id and t1.t2_id > 0   order by t1.id   LIMIT 0, 5;
1871
drop table t1,t2;
1872
1873
#
1874
# outer join, impossible on condition, where, and usable key for range
1875
#
1876
create table t1 (id1 int NOT NULL);
1877
create table t2 (id2 int NOT NULL);
1878
create table t3 (id3 int NOT NULL);
1879
create table t4 (id4 int NOT NULL, id44 int NOT NULL, KEY (id4));
1880
1881
insert into t1 values (1);
1882
insert into t1 values (2);
1883
insert into t2 values (1);
1884
insert into t4 values (1,1);
1885
201 by Brian Aker
Convert default engine to Innodb
1886
#explain select * from t1 left join t2 on id1 = id2 left join t3 on id1 = id3 left join t4 on id3 = id4 where id2 = 1 or id4 = 1;
1 by brian
clean slate
1887
select * from t1 left join t2 on id1 = id2 left join t3 on id1 = id3
1888
left join t4 on id3 = id4 where id2 = 1 or id4 = 1;
1889
1890
drop table t1,t2,t3,t4;
1891
#
1892
# Bug #2298
1893
#
1894
1895
create table t1(s varchar(10) not null);
1896
create table t2(s varchar(10) not null primary key);
1897
create table t3(s varchar(10) not null primary key);
1898
insert into t1 values ('one\t'), ('two\t');
1899
insert into t2 values ('one\r'), ('two\t');
1900
insert into t3 values ('one '), ('two\t');
1901
select * from t1 where s = 'one';
1902
select * from t2 where s = 'one';
1903
select * from t3 where s = 'one';
1904
select * from t1,t2 where t1.s = t2.s;
1905
select * from t2,t3 where t2.s = t3.s;
1906
drop table t1, t2, t3;
1907
1908
#
1909
# Bug #3759
1910
# Both queries should produce identical plans and results.
1911
#
1912
create table t1 (a integer,  b integer, index(a), index(b));
1913
create table t2 (c integer,  d integer, index(c), index(d));
1914
insert into t1 values (1,2), (2,2), (3,2), (4,2);
1915
insert into t2 values (1,3), (2,3), (3,4), (4,4);
201 by Brian Aker
Convert default engine to Innodb
1916
#explain select * from t1 left join t2 on a=c where d in (4);
1 by brian
clean slate
1917
select * from t1 left join t2 on a=c where d in (4);
201 by Brian Aker
Convert default engine to Innodb
1918
#explain select * from t1 left join t2 on a=c where d = 4;
1 by brian
clean slate
1919
select * from t1 left join t2 on a=c where d = 4;
1920
drop table t1, t2;
1921
1922
#
1923
# Covering index is mentioned in EXPLAIN output for const tables (bug #5333)
1924
#
1925
1926
CREATE TABLE t1 (
223 by Brian Aker
Cleanup int() work.
1927
  i int NOT NULL default '0',
1 by brian
clean slate
1928
  c char(10) NOT NULL default '',
1929
  PRIMARY KEY  (i),
1930
  UNIQUE KEY c (c)
1931
) ENGINE=MyISAM;
1932
1933
INSERT INTO t1 VALUES (1,'a');
1934
INSERT INTO t1 VALUES (2,'b');
1935
INSERT INTO t1 VALUES (3,'c');
1936
1937
EXPLAIN SELECT i FROM t1 WHERE i=1;
1938
1939
DROP TABLE t1;
1940
1941
#
1942
# Test case for bug 7520: a wrong cost of the index for a BLOB field
1943
#
1944
1945
CREATE TABLE t1 ( a BLOB, INDEX (a(20)) );
1946
CREATE TABLE t2 ( a BLOB, INDEX (a(20)) );
1947
1948
INSERT INTO t1 VALUES ('one'),('two'),('three'),('four'),('five');
1949
INSERT INTO t2 VALUES ('one'),('two'),('three'),('four'),('five');
1950
1951
EXPLAIN SELECT * FROM t1 LEFT JOIN t2 USE INDEX (a) ON t1.a=t2.a;
1952
EXPLAIN SELECT * FROM t1 LEFT JOIN t2 FORCE INDEX (a) ON t1.a=t2.a;
1953
1954
DROP TABLE t1, t2;
1955
1956
#
1957
# Test case for bug 7098: substitution of a constant for a string field 
1958
#
1959
1960
CREATE TABLE t1 ( city char(30) );
1961
INSERT INTO t1 VALUES ('London');
1962
INSERT INTO t1 VALUES ('Paris');
1963
1964
SELECT * FROM t1 WHERE city='London';
1965
SELECT * FROM t1 WHERE city='london';
1966
EXPLAIN SELECT * FROM t1 WHERE city='London' AND city='london';
1967
SELECT * FROM t1 WHERE city='London' AND city='london';
1968
EXPLAIN SELECT * FROM t1 WHERE city LIKE '%london%' AND city='London';
1969
SELECT * FROM t1 WHERE city LIKE '%london%' AND city='London';
1970
1971
DROP TABLE t1;
1972
1973
#
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
1974
# Bug#7425 inconsistent sort order on columns result of substraction
1 by brian
clean slate
1975
#
1976
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
1977
create table t1 (a int, b int);
1 by brian
clean slate
1978
insert into t1 values (1,0), (1,1), (1,2);
1979
select a-b  from t1 order by 1;
1980
select a-b , (a-b < 0)  from t1 order by 1;
1981
select a-b as d, (a-b >= 0), b from t1 group by b having d >= 0;
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
1982
select a - b from t1 order by 1;
1 by brian
clean slate
1983
drop table t1;
1984
1985
1986
#
1987
# Bug#8733 server accepts malformed query (multiply mentioned distinct)
1988
#
223 by Brian Aker
Cleanup int() work.
1989
create table t1 (a int);
1 by brian
clean slate
1990
select all all * from t1;
1991
select distinct distinct * from t1;
1992
--error 1221
1993
select all distinct * from t1;
1994
--error 1221
1995
select distinct all * from t1;
1996
drop table t1;
1997
1998
#
1999
# Test for BUG#10095
2000
#
2001
CREATE TABLE t1 (
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
2002
  kunde_intern_id int NOT NULL default '0',
2003
  kunde_id int NOT NULL default '0',
2004
  FK_firma_id int NOT NULL default '0',
1 by brian
clean slate
2005
  aktuell enum('Ja','Nein') NOT NULL default 'Ja',
2006
  vorname varchar(128) NOT NULL default '',
2007
  nachname varchar(128) NOT NULL default '',
2008
  geloescht enum('Ja','Nein') NOT NULL default 'Nein',
2009
  firma varchar(128) NOT NULL default ''
2010
);
2011
2012
INSERT INTO t1 VALUES 
2013
  (3964,3051,1,'Ja','Vorname1','1Nachname','Nein','Print Schau XXXX'),
2014
  (3965,3051111,1,'Ja','Vorname1111','1111Nachname','Nein','Print Schau XXXX');
2015
2016
2017
SELECT kunde_id ,FK_firma_id ,aktuell, vorname, nachname, geloescht FROM t1
2018
  WHERE
2019
   (
2020
      (
2021
         ( '' != '' AND firma LIKE CONCAT('%', '', '%'))
2022
         OR
2023
         (vorname LIKE CONCAT('%', 'Vorname1', '%') AND 
2024
          nachname LIKE CONCAT('%', '1Nachname', '%') AND 
2025
          'Vorname1' != '' AND 'xxxx' != '')
2026
      )
2027
      AND
2028
      (
2029
        aktuell = 'Ja' AND geloescht = 'Nein' AND FK_firma_id = 2
2030
      )
2031
   )
2032
 ;
2033
2034
SELECT kunde_id ,FK_firma_id ,aktuell, vorname, nachname,
2035
geloescht FROM t1
2036
  WHERE
2037
   (
2038
     (
2039
       aktuell = 'Ja' AND geloescht = 'Nein' AND FK_firma_id = 2
2040
     )
2041
     AND
2042
     (
2043
         ( '' != '' AND firma LIKE CONCAT('%', '', '%')  )
2044
         OR
2045
         (  vorname LIKE CONCAT('%', 'Vorname1', '%') AND
2046
nachname LIKE CONCAT('%', '1Nachname', '%') AND 'Vorname1' != '' AND
2047
'xxxx' != '')
2048
     )
2049
   )
2050
 ;
2051
2052
SELECT COUNT(*) FROM t1 WHERE 
2053
( 0 OR (vorname LIKE '%Vorname1%' AND nachname LIKE '%1Nachname%' AND 1)) 
2054
AND FK_firma_id = 2;
2055
2056
drop table t1;
2057
2058
#
2059
#
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
2060
# Test for Bug#8009, SELECT failed on bigint when using HEX
1 by brian
clean slate
2061
#
2062
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
2063
CREATE TABLE t1 (b BIGINT NOT NULL, PRIMARY KEY (b));
2064
INSERT INTO t1 VALUES (0x4000000000000000);
2065
SELECT b FROM t1 WHERE b=0x4000000000000000;
1 by brian
clean slate
2066
DROP TABLE t1;
2067
2068
#
2069
# IN with outer join condition (BUG#9393)
2070
#
223 by Brian Aker
Cleanup int() work.
2071
CREATE TABLE `t1` ( `gid` int default NULL, `uid` int default NULL);
1 by brian
clean slate
2072
223 by Brian Aker
Cleanup int() work.
2073
CREATE TABLE `t2` ( `ident` int default NULL, `level` char(16) default NULL);
1 by brian
clean slate
2074
INSERT INTO `t2` VALUES (0,'READ');
2075
223 by Brian Aker
Cleanup int() work.
2076
CREATE TABLE `t3` ( `id` int default NULL, `name` char(16) default NULL);
1 by brian
clean slate
2077
INSERT INTO `t3` VALUES (1,'fs');
2078
2079
select * from t3 left join t1 on t3.id = t1.uid, t2 where t2.ident in (0, t1.gid, t3.id, 0);
2080
2081
drop table t1,t2,t3;
2082
2083
# Test for BUG#11700
2084
CREATE TABLE t1 (
223 by Brian Aker
Cleanup int() work.
2085
  acct_id int NOT NULL default '0',
396 by Brian Aker
Cleanup tiny and small int.
2086
  profile_id int default NULL,
1 by brian
clean slate
2087
  UNIQUE KEY t1$acct_id (acct_id),
2088
  KEY t1$profile_id (profile_id)
2089
);
2090
INSERT INTO t1 VALUES (132,17),(133,18);
2091
2092
CREATE TABLE t2 (
396 by Brian Aker
Cleanup tiny and small int.
2093
  profile_id int default NULL,
223 by Brian Aker
Cleanup int() work.
2094
  queue_id int default NULL,
2095
  seq int default NULL,
1 by brian
clean slate
2096
  KEY t2$queue_id (queue_id)
2097
);
2098
INSERT INTO t2 VALUES (17,31,4),(17,30,3),(17,36,2),(17,37,1);
2099
2100
CREATE TABLE t3 (
223 by Brian Aker
Cleanup int() work.
2101
  id int NOT NULL default '0',
2102
  qtype int default NULL,
2103
  seq int default NULL,
2104
  warn_lvl int default NULL,
2105
  crit_lvl int default NULL,
396 by Brian Aker
Cleanup tiny and small int.
2106
  rr1 int NOT NULL default '0',
223 by Brian Aker
Cleanup int() work.
2107
  rr2 int default NULL,
396 by Brian Aker
Cleanup tiny and small int.
2108
  default_queue int NOT NULL default '0',
1 by brian
clean slate
2109
  KEY t3$qtype (qtype),
2110
  KEY t3$id (id)
2111
);
2112
2113
INSERT INTO t3 VALUES (30,1,29,NULL,NULL,0,NULL,0),(31,1,28,NULL,NULL,0,NULL,0),
2114
  (36,1,34,NULL,NULL,0,NULL,0),(37,1,35,NULL,NULL,0,121,0);
2115
2116
SELECT COUNT(*) FROM t1 a STRAIGHT_JOIN t2 pq STRAIGHT_JOIN t3 q 
2117
WHERE 
2118
  (pq.profile_id = a.profile_id) AND (a.acct_id = 132) AND 
2119
  (pq.queue_id = q.id) AND (q.rr1 <> 1);
2120
2121
drop table t1,t2,t3;
2122
2123
#
2124
# Bug #11482 Wrongly applied optimization was erroneously rejecting valid
2125
#            rows 
2126
create table t1 (f1 int);
2127
insert into t1 values (1),(NULL);
2128
create table t2 (f2 int, f3 int, f4 int);
2129
create index idx1 on t2 (f4);
2130
insert into t2 values (1,2,3),(2,4,6);
2131
select A.f2 from t1 left join t2 A on A.f2 = f1 where A.f3=(select min(f3)
2132
from  t2 C where A.f4 = C.f4) or A.f3 IS NULL; 
2133
drop table t1,t2;
2134
2135
#
2136
# Bug #11521 Negative integer keys incorrectly substituted for 0 during
2137
#            range analysis.
2138
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
2139
create table t2 (a int);
1 by brian
clean slate
2140
create index t2i on t2(a);
2141
insert into t2 values (0), (254), (255);
201 by Brian Aker
Convert default engine to Innodb
2142
#explain select * from t2 where a > -1;
1 by brian
clean slate
2143
select * from t2 where a > -1;
2144
drop table t2;
2145
2146
#
2147
# Bug 7672 Unknown column error in order clause
2148
#
2149
CREATE TABLE t1 (a INT, b INT);
2150
(SELECT a, b AS c FROM t1) ORDER BY c+1;
2151
(SELECT a, b AS c FROM t1) ORDER BY b+1;
2152
SELECT a, b AS c FROM t1 ORDER BY c+1;
2153
SELECT a, b AS c FROM t1 ORDER BY b+1;
2154
drop table t1;
2155
2156
#
2157
# Bug #13356 assertion failed in resolve_const_item()
2158
#
2159
create table t1(f1 int, f2 int);
2160
create table t2(f3 int);
2161
select f1 from t1,t2 where f1=f2 and (f1,f2) = ((1,1));
2162
select f1 from t1,t2 where f1=f2 and (f1,NULL) = ((1,1));
2163
select f1 from t1,t2 where f1=f2 and (f1,f2) = ((1,NULL));
2164
insert into t1 values(1,1),(2,null);
2165
insert into t2 values(2);
2166
select * from t1,t2 where f1=f3 and (f1,f2) = (2,null);
2167
select * from t1,t2 where f1=f3 and (f1,f2) <=> (2,null);
2168
drop table t1,t2; 
2169
2170
#
2171
# Bug #13535
2172
#
2173
create table t1 (f1 int not null auto_increment primary key, f2 varchar(10));
2174
create table t11 like t1;
2175
insert into t1 values(1,""),(2,"");
590.1.4 by Stewart Smith
remove frm_version from TABLE_SHARE
2176
--replace_column 3 X 7 X 8 X 9 X 10 X 11 X 12 X 13 X 14 X
1 by brian
clean slate
2177
show table status like 't1%';
2178
select 123 as a from t1 where f1 is null;
2179
drop table t1,t11;
2180
2181
#
2182
# Bug #3874 (function in GROUP and LEFT JOIN)
2183
#
2184
2185
CREATE TABLE t1 ( a INT NOT NULL, b INT NOT NULL, UNIQUE idx (a,b) );
2186
INSERT INTO t1 VALUES (1,1),(1,2),(1,3),(1,4);
2187
CREATE TABLE t2 ( a INT NOT NULL, b INT NOT NULL, e INT );
2188
INSERT INTO t2 VALUES ( 1,10,1), (1,10,2), (1,11,1), (1,11,2), (1,2,1), (1,2,2),(1,2,3);
2189
SELECT t2.a, t2.b, IF(t1.b IS NULL,'',e) AS c, COUNT(*) AS d FROM t2 LEFT JOIN
2190
t1 ON t2.a = t1.a AND t2.b = t1.b GROUP BY a, b, c;
2191
SELECT t2.a, t2.b, IF(t1.b IS NULL,'',e) AS c, COUNT(*) AS d FROM t2 LEFT JOIN
2192
t1 ON t2.a = t1.a AND t2.b = t1.b GROUP BY t1.a, t1.b, c;
2193
SELECT t2.a, t2.b, IF(t1.b IS NULL,'',e) AS c, COUNT(*) AS d FROM t2 LEFT JOIN
2194
t1 ON t2.a = t1.a AND t2.b = t1.b GROUP BY t2.a, t2.b, c;
2195
SELECT t2.a, t2.b, IF(t1.b IS NULL,'',e) AS c, COUNT(*) AS d FROM t2,t1
2196
WHERE t2.a = t1.a AND t2.b = t1.b GROUP BY a, b, c;
2197
DROP TABLE IF EXISTS t1, t2;
2198
2199
#
2200
# Bug #13855 select distinct with group by caused server crash
2201
#
2202
create table t1 (f1 int primary key, f2 int);
2203
create table t2 (f3 int, f4 int, primary key(f3,f4));
2204
insert into t1 values (1,1);
2205
insert into t2 values (1,1),(1,2);
2206
select distinct count(f2) >0 from t1 left join t2 on f1=f3 group by f1;
2207
drop table t1,t2;
2208
2209
#
2210
# Bug #14482 Server crash when subselecting from the same table
2211
#
2212
create table t1 (f1 int,f2 int);
2213
insert into t1 values(1,1);
2214
create table t2 (f3 int, f4 int, primary key(f3,f4));
2215
insert into t2 values(1,1);
2216
select * from t1 where f1 in (select f3 from t2 where (f3,f4)= (select f3,f4 from t2)); 
2217
drop table t1,t2;
2218
2219
#
2220
# Bug #4981: 4.x and 5.x produce non-optimal execution path, 3.23 regression test failure
2221
#
2222
CREATE TABLE t1(a int, b int, c int, KEY b(b), KEY c(c));
2223
insert into t1 values (1,0,0),(2,0,0);
2224
CREATE TABLE t2 (a int, b varchar(2), c varchar(2), PRIMARY KEY(a));
2225
insert into t2 values (1,'',''), (2,'','');
2226
CREATE TABLE t3 (a int, b int, PRIMARY KEY (a,b), KEY a (a), KEY b (b));
2227
insert into t3 values (1,1),(1,2);
2228
# must have "range checked" for t2
201 by Brian Aker
Convert default engine to Innodb
2229
#explain select straight_join DISTINCT t2.a,t2.b, t1.c from t1, t3, t2 where (t1.c=t2.a or (t1.c=t3.a and t2.a=t3.b)) and t1.b=556476786 and t2.b like '%%' order by t2.b limit 0,1;
1 by brian
clean slate
2230
DROP TABLE t1,t2,t3;
2231
2232
#
2233
# Bug #17873: confusing error message when IGNORE INDEX refers a column name
2234
#
2235
2236
CREATE TABLE t1 (a int, INDEX idx(a));
2237
INSERT INTO t1 VALUES (2), (3), (1);
2238
2239
EXPLAIN SELECT * FROM t1 IGNORE INDEX (idx);
2240
--error 1176
2241
EXPLAIN SELECT * FROM t1 IGNORE INDEX (a);
2242
--error 1176
2243
EXPLAIN SELECT * FROM t1 FORCE INDEX (a);
2244
2245
DROP TABLE t1;
2246
2247
#
2248
# Bug #21019: First result of SELECT COUNT(*) different than consecutive runs
2249
#
2250
CREATE TABLE t1 (a int, b int);
2251
INSERT INTO t1 VALUES (1,1), (2,1), (4,10);
2252
2253
CREATE TABLE t2 (a int PRIMARY KEY, b int, KEY b (b));
2254
INSERT INTO t2 VALUES (1,NULL), (2,10);
2255
ALTER TABLE t1 ENABLE KEYS;
2256
2257
EXPLAIN SELECT STRAIGHT_JOIN COUNT(*) FROM t2, t1 WHERE t1.b = t2.b OR t2.b IS NULL;
2258
SELECT STRAIGHT_JOIN * FROM t2, t1 WHERE t1.b = t2.b OR t2.b IS NULL;
2259
EXPLAIN SELECT STRAIGHT_JOIN COUNT(*) FROM t2, t1 WHERE t1.b = t2.b OR t2.b IS NULL;
2260
SELECT STRAIGHT_JOIN * FROM t2, t1 WHERE t1.b = t2.b OR t2.b IS NULL;
2261
DROP TABLE IF EXISTS t1,t2;
2262
2263
#
2264
# Bug #20954 "avg(keyval) retuns 0.38 but max(keyval) returns an empty set"
2265
#
2266
--disable_ps_protocol
2267
CREATE TABLE t1 (key1 float default NULL, UNIQUE KEY key1 (key1));
2268
CREATE TABLE t2 (key2 float default NULL, UNIQUE KEY key2 (key2));
2269
INSERT INTO t1 VALUES (0.3762),(0.3845),(0.6158),(0.7941);
2270
INSERT INTO t2 VALUES (1.3762),(1.3845),(1.6158),(1.7941);
2271
201 by Brian Aker
Convert default engine to Innodb
2272
#explain select max(key1) from t1 where key1 <= 0.6158;
2273
#explain select max(key2) from t2 where key2 <= 1.6158;
2274
#explain select min(key1) from t1 where key1 >= 0.3762;
2275
#explain select min(key2) from t2 where key2 >= 1.3762;
2276
#explain select max(key1), min(key2) from t1, t2 where key1 <= 0.6158 and key2 >= 1.3762;
2277
#explain select max(key1) from t1 where key1 <= 0.6158 and rand() + 0.5 >= 0.5;
2278
#explain select min(key1) from t1 where key1 >= 0.3762 and rand() + 0.5 >= 0.5;
1 by brian
clean slate
2279
2280
select max(key1) from t1 where key1 <= 0.6158;
2281
select max(key2) from t2 where key2 <= 1.6158;
2282
select min(key1) from t1 where key1 >= 0.3762;
2283
select min(key2) from t2 where key2 >= 1.3762;
2284
select max(key1), min(key2) from t1, t2
2285
where key1 <= 0.6158 and key2 >= 1.3762;
2286
select max(key1) from t1 where key1 <= 0.6158 and rand() + 0.5 >= 0.5;
2287
select min(key1) from t1 where key1 >= 0.3762 and rand() + 0.5 >= 0.5;
2288
2289
DROP TABLE t1,t2;
2290
--enable_ps_protocol
2291
2292
#
2293
# Bug #18759 "Incorrect string to numeric conversion"
2294
#
2295
# This test is here so that the behavior will not be changed to 4.1
2296
# and not to 5.0 either. In 4.1 and 5.0 sending an integer as a string
2297
# will be converted internally to real (double) value and it is not
2298
# as accurate as bigint (longlong) for integers. Thus the results may
2299
# vary. In 5.1 internally it is decimal, which is a string type and
2300
# will be more accurate. Due to rather big changes needed to fix this
2301
# in 4.1 or 5.0 it is not desired to do it in the stable versions.
2302
#
2303
# This test is here only to make sure that behavior is not changed in
2304
# 4.1 and 5.0
2305
#
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
2306
CREATE TABLE t1 (i BIGINT NOT NULL);
1 by brian
clean slate
2307
INSERT INTO t1 VALUES (10);
2308
SELECT i='1e+01',i=1e+01, i in (1e+01,1e+01), i in ('1e+01','1e+01') FROM t1;
2309
DROP TABLE t1;
2310
2311
#
67 by Brian Aker
First pass for removing mediumint (3 byte INT type).
2312
# Bug #32103: optimizer crash when join on int and bigint with variable in 
1 by brian
clean slate
2313
#             where clause
2314
#
2315
2316
CREATE TABLE t1 (c0 int);
2317
CREATE TABLE t2 (c0 int);
2318
2319
# We need any variable that:
2320
# 1. has integer type, 
2321
# 2. can be used with the "@@name" syntax
2322
# 3. available in every server build
2323
INSERT INTO t1 VALUES(@@connect_timeout);
2324
INSERT INTO t2 VALUES(@@connect_timeout);
2325
2326
# We only need to ensure 1 row is returned to validate the results
2327
--replace_column 1 X 2 X
2328
SELECT * FROM t1 JOIN t2 ON t1.c0 = t2.c0 WHERE (t1.c0 <=> @@connect_timeout);
2329
2330
DROP TABLE t1, t2;
2331
2332
--echo End of 4.1 tests
2333
2334
#
2335
# Test for bug #6474
2336
#
2337
2338
CREATE TABLE t1 ( 
383.1.30 by Brian Aker
Removal of latin character set.
2339
K2C4 varchar(4) collate utf8_bin NOT NULL default '', 
2340
K4N4 varchar(4) collate utf8_bin NOT NULL default '0000', 
223 by Brian Aker
Cleanup int() work.
2341
F2I4 int NOT NULL default '0' 
377.1.4 by Brian Aker
Big, fat, UTF-8 patch. This fixes some of the oddities around only one
2342
) ENGINE=MyISAM;
1 by brian
clean slate
2343
2344
INSERT INTO t1 VALUES 
2345
('W%RT', '0100',  1), 
2346
('W-RT', '0100', 1), 
2347
('WART', '0100', 1), 
2348
('WART', '0200', 1), 
2349
('WERT', '0100', 2), 
2350
('WORT','0200', 2), 
2351
('WT', '0100', 2), 
2352
('W_RT', '0100', 2), 
2353
('WaRT', '0100', 3), 
2354
('WART', '0300', 3), 
2355
('WRT' , '0400', 3), 
2356
('WURM', '0500', 3), 
2357
('W%T', '0600', 4), 
2358
('WA%T', '0700', 4), 
2359
('WA_T', '0800', 4);
2360
2361
SELECT K2C4, K4N4, F2I4 FROM t1
2362
  WHERE  K2C4 = 'WART' AND 
2363
        (F2I4 = 2 AND K2C4 = 'WART' OR (F2I4 = 2 OR K4N4 = '0200'));
2364
SELECT K2C4, K4N4, F2I4 FROM t1
2365
  WHERE  K2C4 = 'WART' AND (K2C4 = 'WART' OR K4N4 = '0200');
2366
DROP TABLE t1;
2367
2368
#
2369
# Bug#8670
2370
#
2371
create table t1 (a int, b int);
2372
create table t2 like t1;
2373
select t1.a from (t1 inner join t2 on t1.a=t2.a) where t2.a=1;
2374
select t1.a from ((t1 inner join t2 on t1.a=t2.a)) where t2.a=1;
2375
select x.a, y.a, z.a from ( (t1 x inner join t2 y on x.a=y.a) inner join t2 z on y.a=z.a) WHERE x.a=1;
2376
drop table t1,t2;
2377
2378
#
2379
# Bug#9820
2380
#
2381
2382
create table t1 (s1 varchar(5));
2383
insert into t1 values ('Wall');
2384
select min(s1) from t1 group by s1 with rollup;
2385
drop table t1;
2386
2387
#
2388
# Bug#9799
2389
#
2390
2391
create table t1 (s1 int) engine=myisam;
2392
insert into t1 values (0);
2393
select avg(distinct s1) from t1 group by s1 with rollup;
2394
drop table t1;
2395
2396
#
2397
# Bug#9800
2398
#
2399
2400
create table t1 (s1 int);
2401
insert into t1 values (null),(1);
2402
select distinct avg(s1) as x from t1 group by s1 with rollup;
2403
drop table t1;
2404
2405
2406
#
2407
# Test for bug #10084: STRAIGHT_JOIN with ON expression 
2408
#
2409
2410
CREATE TABLE t1 (a int);
2411
CREATE TABLE t2 (a int);
2412
INSERT INTO t1 VALUES (1), (2), (3), (4), (5);
2413
INSERT INTO t2 VALUES (2), (4), (6);
2414
2415
SELECT t1.a FROM t1 STRAIGHT_JOIN t2 ON t1.a=t2.a;
2416
2417
EXPLAIN SELECT t1.a FROM t1 STRAIGHT_JOIN t2 ON t1.a=t2.a;
2418
EXPLAIN SELECT t1.a FROM t1 INNER JOIN t2 ON t1.a=t2.a;
2419
2420
DROP TABLE t1,t2;
2421
2422
#
2423
# Bug #10650
2424
#
2425
2426
select x'10' + 0, X'10' + 0, b'10' + 0, B'10' + 0;
2427
2428
#
2429
# Bug #11398 Bug in field_conv() results in wrong result of join with index
2430
#
223 by Brian Aker
Cleanup int() work.
2431
create table t1 (f1 varchar(6) default NULL, f2 int primary key not null);
1 by brian
clean slate
2432
create table t2 (f3 varchar(5) not null, f4 varchar(5) not null, UNIQUE KEY UKEY (f3,f4));
2433
insert into t1 values (" 2", 2);
2434
insert into t2 values (" 2", " one "),(" 2", " two ");
2435
select * from t1 left join t2 on f1 = f3;
2436
drop table t1,t2;
2437
2438
#
2439
# Bug #10646 Columns included in the join between two tables are ambigious
2440
# in the select
2441
#
2442
2443
create table t1 (pk int primary key, b int);
2444
create table t2 (pk int primary key, c int);
2445
select pk from t1 inner join t2 using (pk);
2446
drop table t1,t2;
2447
2448
#
2449
# Bug #4789 Incosistent results of more than 2-way natural joins due to
2450
#           incorrect transformation to join ... on.
2451
#
2452
223 by Brian Aker
Cleanup int() work.
2453
create table t1 (a int, t1_val int);
2454
create table t2 (b int, t2_val int);
2455
create table t3 (a int, b int);
1 by brian
clean slate
2456
insert into t1 values (1,1),(2,2);
2457
insert into t2 values (1,1),(2,2),(3,3);
2458
insert into t3 values (1,1),(2,1),(3,1),(4,1);
2459
# the following two queries must return the same result
2460
select * from t1 natural join t2 natural join t3;
2461
select * from t1 natural join t3 natural join t2;
2462
drop table t1, t2, t3;
2463
2464
2465
#
2466
# Bug #6495 Illogical requirement for column qualification in NATURAL join
2467
#
2468
2469
create table t1 (a char(1));
2470
create table t2 (a char(1));
2471
insert into t1 values ('a'),('b'),('c');
2472
insert into t2 values ('b'),('c'),('d');
2473
select a from t1 natural join t2;
2474
select * from t1 natural join t2 where a = 'b';
2475
drop table t1, t2;
2476
2477
#
2478
# Bug #12977 Compare table names with qualifying field tables only
2479
# for base tables, search all nested join operands of natural joins.
2480
#
2481
396 by Brian Aker
Cleanup tiny and small int.
2482
CREATE TABLE t1 (`id` int);
2483
CREATE TABLE t2 (`id` int);
2484
CREATE TABLE t3 (`id` int);
1 by brian
clean slate
2485
INSERT INTO t1 VALUES (1),(2),(3);
2486
INSERT INTO t2 VALUES (2);
2487
INSERT INTO t3 VALUES (3);
2488
-- error 1052
2489
SELECT t1.id,t3.id FROM t1 JOIN t2 ON (t2.id=t1.id) LEFT JOIN t3 USING (id);
2490
-- error 1052
2491
SELECT t1.id,t3.id FROM t1 JOIN t2 ON (t2.notacolumn=t1.id) LEFT JOIN t3 USING (id);
2492
-- error 1052
2493
SELECT id,t3.id FROM t1 JOIN t2 ON (t2.id=t1.id) LEFT JOIN t3 USING (id);
2494
-- error 1052
2495
SELECT id,t3.id FROM (t1 JOIN t2 ON (t2.id=t1.id)) LEFT JOIN t3 USING (id);
2496
2497
drop table t1, t2, t3;
2498
2499
#
2500
# Bug #13067 JOIN xxx USING is case sensitive
2501
#
2502
223 by Brian Aker
Cleanup int() work.
2503
create table t1 (a int,b int);
2504
create table t2 (a int,b int);
1 by brian
clean slate
2505
insert into t1 values (1,10),(2,20),(3,30);
2506
insert into t2 values (1,10);
2507
# both queries should produce the same result
2508
select * from t1 inner join t2 using (A);
2509
select * from t1 inner join t2 using (a);
2510
drop table t1, t2;
2511
2512
#
2513
# Bug #12943 Incorrect nesting of [INNER| CROSS] JOIN due to unspecified
2514
#            associativity in the parser.
2515
#
2516
2517
create table t1 (a int, c int);
2518
create table t2 (b int);
2519
create table t3 (b int, a int);
2520
create table t4 (c int);
2521
insert into t1 values (1,1);
2522
insert into t2 values (1);
2523
insert into t3 values (1,1);
2524
insert into t4 values (1);
2525
2526
select * from t1 join t2 join t3 on (t2.b = t3.b and t1.a = t3.a);
2527
# Notice that ',' has lower priority than 'join', thus we have that:
2528
# t1, t2 join t3 <==> t1, (t2 join t3).
2529
-- error 1054
2530
select * from t1, t2 join t3 on (t2.b = t3.b and t1.a = t3.a);
2531
select * from t1 join t2 join t3 join t4 on (t1.a = t4.c and t2.b = t4.c);
2532
select * from t1 join t2 join t4 using (c);
2533
drop table t1, t2, t3, t4;
2534
2535
#
2536
# Bug #12291 Table wasn't reinited for index scan after sequential scan 
2537
#
2538
create table t1(x int, y int);
2539
create table t2(x int, y int);
2540
create table t3(x int, primary key(x));
2541
insert into t1 values (1, 1), (2, 1), (3, 1), (4, 3), (5, 6), (6, 6);
2542
insert into t2 values (1, 1), (2, 1), (3, 3), (4, 6), (5, 6);
2543
insert into t3 values (1), (2), (3), (4), (5);
2544
select t1.x, t3.x from t1, t2, t3  where t1.x = t2.x and t3.x >= t1.y and t3.x <= t2.y;
2545
drop table t1,t2,t3;
2546
2547
#
2548
# Bug #13597 Column in ON condition not resolved if references a table in
2549
# nested right join.
2550
#
2551
223 by Brian Aker
Cleanup int() work.
2552
create table t1 (id int not null default '0');
1 by brian
clean slate
2553
insert into t1 values (123),(191),(192);
383.1.28 by Brian Aker
Fix for CREATE TABLE/character sets.
2554
create table t2 (id char(16) not null);
1 by brian
clean slate
2555
insert into t2 values ('58013'),('58014'),('58015'),('58016');
383.1.28 by Brian Aker
Fix for CREATE TABLE/character sets.
2556
create table t3 (a_id int not null, b_id char(16));
1 by brian
clean slate
2557
insert into t3 values (123,null),(123,null),(123,null),(123,null),(123,null),(123,'58013');
2558
2559
# both queries are equivalent
2560
select count(*)
2561
from t1 inner join (t3 left join t2 on t2.id = t3.b_id) on t1.id = t3.a_id;
2562
2563
select count(*)
2564
from t1 inner join (t2 right join t3 on t2.id = t3.b_id) on t1.id = t3.a_id;
2565
2566
drop table t1,t2,t3;
2567
2568
#
2569
# Bug #13832 Incorrect parse order of join productions due to unspecified
2570
# operator priorities results in incorrect join tree.
2571
#
2572
2573
create table t1 (a int);
2574
create table t2 (b int);
2575
create table t3 (c int);
2576
select * from t1 join t2 join t3 on (t1.a=t3.c);
2577
select * from t1 join t2 left join t3 on (t1.a=t3.c);
2578
select * from t1 join t2 right join t3 on (t1.a=t3.c);
2579
select * from t1 join t2 straight_join t3 on (t1.a=t3.c);
2580
drop table t1, t2 ,t3;
2581
2582
#
2583
# Bug #14093 Query takes a lot of time when date format is not valid
2584
# fix optimizes execution. so here we just check that returned set is
2585
# correct.
2586
create table t1(f1 int, f2 date);
2587
insert into t1 values(1,'2005-01-01'),(2,'2005-09-01'),(3,'2005-09-30'),
2588
  (4,'2005-10-01'),(5,'2005-12-30');
2589
# should return all records
2590
select * from t1 where f2 >= 0            order by f2;
2591
select * from t1 where f2 >= '0000-00-00' order by f2;
2592
# should return 4,5
2593
select * from t1 where f2 >= '2005-09-31' order by f2;
2594
select * from t1 where f2 >= '2005-09-3a' order by f2;
2595
# should return 1,2,3
2596
select * from t1 where f2 <= '2005-09-31' order by f2;
2597
select * from t1 where f2 <= '2005-09-3a' order by f2;
2598
drop table t1;
2599
2600
#
2601
# Bug #15106: lost equality predicate of the form field=const in a join query
2602
#
2603
2604
CREATE TABLE t1(key_a int4 NOT NULL, optimus varchar(32), PRIMARY KEY(key_a));
2605
CREATE TABLE t2(key_a int4 NOT NULL, prime varchar(32), PRIMARY KEY(key_a));
2606
CREATE table t3(key_a int4 NOT NULL, key_b int4 NOT NULL, foo varchar(32),
2607
                PRIMARY KEY(key_a,key_b));
2608
2609
INSERT INTO t1 VALUES (0,'');
2610
INSERT INTO t1 VALUES (1,'i');
2611
INSERT INTO t1 VALUES (2,'j');
2612
INSERT INTO t1 VALUES (3,'k');
2613
2614
INSERT INTO t2 VALUES (1,'r');
2615
INSERT INTO t2 VALUES (2,'s');
2616
INSERT INTO t2 VALUES (3,'t');
2617
2618
INSERT INTO t3 VALUES (1,5,'x');
2619
INSERT INTO t3 VALUES (1,6,'y');
2620
INSERT INTO t3 VALUES (2,5,'xx');
2621
INSERT INTO t3 VALUES (2,6,'yy');
2622
INSERT INTO t3 VALUES (2,7,'zz');
2623
INSERT INTO t3 VALUES (3,5,'xxx');
2624
2625
SELECT t2.key_a,foo 
2626
  FROM t1 INNER JOIN t2 ON t1.key_a = t2.key_a
2627
          INNER JOIN t3 ON t1.key_a = t3.key_a
2628
    WHERE t2.key_a=2 and key_b=5;
2629
EXPLAIN SELECT t2.key_a,foo 
2630
  FROM t1 INNER JOIN t2 ON t1.key_a = t2.key_a
2631
          INNER JOIN t3 ON t1.key_a = t3.key_a
2632
    WHERE t2.key_a=2 and key_b=5;
2633
2634
SELECT t2.key_a,foo 
2635
  FROM t1 INNER JOIN t2 ON t2.key_a = t1.key_a
2636
          INNER JOIN t3 ON t1.key_a = t3.key_a
2637
    WHERE t2.key_a=2 and key_b=5;
2638
EXPLAIN SELECT t2.key_a,foo 
2639
  FROM t1 INNER JOIN t2 ON t2.key_a = t1.key_a
2640
          INNER JOIN t3 ON t1.key_a = t3.key_a
2641
    WHERE t2.key_a=2 and key_b=5;
2642
2643
DROP TABLE t1,t2,t3;
2644
2645
#
2646
# Bug#15347 Wrong result of subselect when records cache and set functions
2647
#           are involved
2648
#
2649
create  table t1 (f1 int);
2650
insert into t1 values(1),(2);
2651
create table t2 (f2 int, f3 int, key(f2));
2652
insert into t2 values(1,1),(2,2);
2653
create table t3 (f4 int not null);
2654
insert into t3 values (2),(2),(2);
2655
select f1,(select count(*) from t2,t3 where f2=f1 and f3=f4) as count from t1;
2656
drop table t1,t2,t3;
2657
2658
#
2659
# Bug #15633 Evaluation of Item_equal for non-const table caused wrong
2660
#            select result
2661
#
2662
create table t1 (f1 int unique);
2663
create table t2 (f2 int unique);
2664
create table t3 (f3 int unique);
2665
insert into t1 values(1),(2);
2666
insert into t2 values(1),(2);
2667
insert into t3 values(1),(NULL);
2668
select * from t3 where f3 is null;
2669
select t2.f2 from t1 left join t2 on f1=f2 join t3 on f1=f3 where f1=1;
2670
drop table t1,t2,t3;
2671
2672
#
2673
# Bug#15268 Unchecked null value caused server crash
2674
#
2675
create table t1(f1 char, f2 char not null);
2676
insert into t1 values(null,'a');
2677
create table t2 (f2 char not null);
2678
insert into t2 values('b');
2679
select * from t1 left join t2 on f1=t2.f2 where t1.f2='a';
2680
drop table t1,t2;
2681
2682
#
2683
# Bug#15538 unchecked table absense caused server crash.
2684
#
2685
--error 1064
2686
select * from (select * left join t on f1=f2) tt;
2687
2688
#
2689
# Bug #16504: re-evaluation of Item_equal object after reading const table
2690
#
2691
2692
CREATE TABLE t1 (sku int PRIMARY KEY, pr int);
2693
CREATE TABLE t2 (sku int PRIMARY KEY, sppr int, name varchar(255));
2694
2695
INSERT INTO t1 VALUES
2696
  (10, 10), (20, 10), (30, 20), (40, 30), (50, 10), (60, 10);
2697
2698
INSERT INTO t2 VALUES 
2699
  (10, 10, 'aaa'), (20, 10, 'bbb'), (30, 10, 'ccc'), (40, 20, 'ddd'),
2700
  (50, 10, 'eee'), (60, 20, 'fff'), (70, 20, 'ggg'), (80, 30, 'hhh');
2701
2702
SELECT t2.sku, t2.sppr, t2.name, t1.sku, t1.pr
2703
  FROM t2, t1 WHERE t2.sku=20 AND (t2.sku=t1.sku OR t2.sppr=t1.sku);
2704
EXPLAIN
2705
SELECT t2.sku, t2.sppr, t2.name, t1.sku, t1.pr
2706
  FROM t2, t1 WHERE t2.sku=20 AND (t2.sku=t1.sku OR t2.sppr=t1.sku);
2707
2708
2709
DROP TABLE t1,t2;
2710
2711
# BUG#17379
2712
2713
create table t1 (a int);
2714
insert into t1 values (0),(1),(2),(3),(4),(5),(6),(7),(8),(9);
2715
create table t2 (a int, b int, c int, e int, primary key(a,b,c));
2716
insert into t2 select A.a, B.a, C.a, C.a from t1 A, t1 B, t1 C;
2717
analyze table t2;
2718
select 'In next EXPLAIN, B.rows must be exactly 10:' Z;
2719
201 by Brian Aker
Convert default engine to Innodb
2720
#explain select * from t2 A, t2 B where A.a=5 and A.b=5 and A.C<5 and B.a=5 and B.b=A.e and (B.b =1 or B.b = 3 or B.b=5);
1 by brian
clean slate
2721
drop table t1, t2;
2722
2723
#
2724
#Bug #18940: selection of optimal execution plan caused by equality
2725
#            propagation (the bug was fixed by the patch for bug #17379)
2726
2727
CREATE TABLE t1 (a int PRIMARY KEY, b int, INDEX(b));
2728
INSERT INTO t1 VALUES (1, 3), (9,4), (7,5), (4,5), (6,2),
2729
                      (3,1), (5,1), (8,9), (2,2), (0,9);
2730
2731
CREATE TABLE t2 (c int, d int, f int, INDEX(c,f));
2732
INSERT INTO t2 VALUES
2733
 (1,0,0), (1,0,1), (2,0,0), (2,0,1), (3,0,0), (4,0,1),
2734
 (5,0,0), (5,0,1), (6,0,0), (0,0,1), (7,0,0), (7,0,1),
2735
 (0,0,0), (0,0,1), (8,0,0), (8,0,1), (9,0,0), (9,0,1);
2736
2737
EXPLAIN
2738
SELECT a, c, d, f FROM t1,t2 WHERE a=c AND b BETWEEN 4 AND 6;
2739
EXPLAIN
2740
SELECT a, c, d, f FROM t1,t2 WHERE a=c AND b BETWEEN 4 AND 6 AND a > 0;
2741
2742
DROP TABLE t1, t2;
2743
2744
#
397 by Brian Aker
Remove tiny/small int.
2745
# Bug #18895: Now tests for int
1 by brian
clean slate
2746
#
2747
create table t1 (
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
2748
    a int    not null auto_increment primary key,
397 by Brian Aker
Remove tiny/small int.
2749
    b int             not null,
2750
    c int             not null
1 by brian
clean slate
2751
);
2752
2753
create table t2 (
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
2754
    a int    not null auto_increment primary key,
397 by Brian Aker
Remove tiny/small int.
2755
    b int             not null,
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
2756
    c int    not null,
1 by brian
clean slate
2757
    d varchar(50)
2758
);
2759
2760
insert into t1 (b,c) values (0,1), (0,1);
2761
insert into t2 (b,c) values (0,1);
2762
2763
# Row 1 should succeed.  Row 2 should fail.  Both fail.
2764
select t1.a, t1.b + 0, t1.c + 0, t2.a, t2.b + 0, t2.c, t2.d
2765
from t1 left outer join t2 on t1.a = t2.c and t2.b <> 1
2766
where t1.b <> 1 order by t1.a;
2767
2768
drop table t1,t2;
2769
2770
#
2771
# Bug #20569: Garbage in DECIMAL results from some mathematical functions
2772
#
2773
SELECT 0.9888889889 * 1.011111411911;
2774
2775
#
2776
# Bug #21390: wrong estimate of rows after elimination of const tables
2777
#
2778
2779
CREATE TABLE t1 (a int NOT NULL PRIMARY KEY, b int NOT NULL);
2780
INSERT INTO t1 VALUES (1,1), (2,2), (3,3), (4,4);
2781
2782
CREATE TABLE t2 (c int NOT NULL, INDEX idx(c));
2783
INSERT INTO t2 VALUES
2784
  (1), (1), (1), (1), (1), (1), (1), (1),
2785
  (2), (2), (2), (2),
2786
  (3), (3),
2787
  (4);
2788
2789
EXPLAIN SELECT b FROM t1, t2 WHERE b=c AND a=1;
2790
EXPLAIN SELECT b FROM t1, t2 WHERE b=c AND a=4;
2791
2792
DROP TABLE t1, t2;
2793
2794
#
2795
# No matches for a join after substitution of a const table
2796
#
2797
2798
CREATE TABLE t1 (id int NOT NULL PRIMARY KEY, a int);
2799
INSERT INTO t1 VALUES (1,2), (2,NULL), (3,2);
2800
2801
CREATE TABLE t2 (b int, c INT, INDEX idx1(b));
2802
INSERT INTO t2 VALUES (2,1), (3,2);
2803
2804
CREATE TABLE t3 (d int,  e int, INDEX idx1(d));
2805
INSERT INTO t3 VALUES (2,10), (2,20), (1,30), (2,40), (2,50);
2806
2807
EXPLAIN
2808
SELECT * FROM t1 LEFT JOIN t2 ON t2.b=t1.a INNER JOIN t3 ON t3.d=t1.id
2809
  WHERE t1.id=2;
2810
SELECT * FROM t1 LEFT JOIN t2 ON t2.b=t1.a INNER JOIN t3 ON t3.d=t1.id
2811
  WHERE t1.id=2;
2812
2813
DROP TABLE t1,t2,t3;
2814
2815
#
2816
# Bug #22735: no equality propagation for BETWEEN and IN with STRING arguments
2817
#
2818
2819
CREATE TABLE t1 (pk varchar(10) PRIMARY KEY, fk varchar(16));
2820
CREATE TABLE t2 (pk varchar(16) PRIMARY KEY, fk varchar(10));
2821
2822
INSERT INTO t1 VALUES
2823
  ('d','dddd'), ('i','iii'), ('a','aa'), ('b','bb'), ('g','gg'), 
2824
  ('e','eee'), ('c','cccc'), ('h','hhh'), ('j','jjj'), ('f','fff');
2825
INSERT INTO t2 VALUES
2826
  ('jjj', 'j'), ('cc','c'), ('ccc','c'), ('aaa', 'a'), ('jjjj','j'),
2827
  ('hhh','h'), ('gg','g'), ('fff','f'), ('ee','e'), ('ffff','f'),
2828
  ('bbb','b'), ('ff','f'), ('cccc','c'), ('dddd','d'), ('jj','j'),
2829
  ('aaaa','a'), ('bb','b'), ('eeee','e'), ('aa','a'), ('hh','h');
2830
2831
EXPLAIN SELECT t2.* 
2832
  FROM t1 JOIN t2 ON t2.fk=t1.pk
2833
    WHERE t2.fk < 'c' AND t2.pk=t1.fk;
2834
EXPLAIN SELECT t2.* 
2835
  FROM t1 JOIN t2 ON t2.fk=t1.pk 
2836
    WHERE t2.fk BETWEEN 'a' AND 'b' AND t2.pk=t1.fk;
2837
EXPLAIN SELECT t2.* 
2838
  FROM t1 JOIN t2 ON t2.fk=t1.pk 
2839
    WHERE t2.fk IN ('a','b') AND t2.pk=t1.fk;
2840
2841
DROP TABLE t1,t2;
2842
2843
#
2844
# Bug #22367: Optimizer uses ref join type instead of eq_ref for simple 
2845
#               join on strings
2846
#
2847
CREATE TABLE t1 (a int, b varchar(20) NOT NULL, PRIMARY KEY(a));
2848
CREATE TABLE t2 (a int, b varchar(20) NOT NULL,
2849
                 PRIMARY KEY (a), UNIQUE KEY (b));
2850
INSERT INTO t1 VALUES (1,'a'),(2,'b'),(3,'c');
2851
INSERT INTO t2 VALUES (1,'a'),(2,'b'),(3,'c');
2852
2853
EXPLAIN SELECT t1.a FROM t1 LEFT JOIN t2 ON t2.b=t1.b WHERE t1.a=3;
2854
2855
DROP TABLE t1,t2;
2856
2857
#
2858
# Bug #19579: predicates that become sargable after reading const tables
2859
#             are not taken into account by optimizer
2860
#
2861
2862
CREATE TABLE t1(id int PRIMARY KEY, b int, e int);
2863
CREATE TABLE t2(i int, a int, INDEX si(i), INDEX ai(a));
2864
CREATE TABLE t3(a int PRIMARY KEY, c char(4), INDEX ci(c));
2865
2866
INSERT INTO t1 VALUES 
2867
  (1,10,19), (2,20,22), (4,41,42), (9,93,95), (7, 77,79),
2868
  (6,63,67), (5,55,58), (3,38,39), (8,81,89);
2869
INSERT INTO t2 VALUES
2870
  (21,210), (41,410), (82,820), (83,830), (84,840),
2871
  (65,650), (51,510), (37,370), (94,940), (76,760),
2872
  (22,220), (33,330), (40,400), (95,950), (38,380),
2873
  (67,670), (88,880), (57,570), (96,960), (97,970);
2874
INSERT INTO t3 VALUES
2875
  (210,'bb'), (950,'ii'), (400,'ab'), (500,'ee'), (220,'gg'),
2876
  (440,'gg'), (310,'eg'), (380,'ee'), (840,'bb'), (830,'ff'),
2877
  (230,'aa'), (960,'ii'), (410,'aa'), (510,'ee'), (290,'bb'),
2878
  (450,'gg'), (320,'dd'), (390,'hh'), (850,'jj'), (860,'ff');
2879
2880
EXPLAIN
2881
SELECT t3.a FROM t1,t2 FORCE INDEX (si),t3
2882
  WHERE t1.id = 8 AND t2.i BETWEEN t1.b AND t1.e AND 
2883
        t3.a=t2.a AND t3.c IN ('bb','ee');
2884
EXPLAIN
2885
SELECT t3.a FROM t1,t2,t3
2886
  WHERE t1.id = 8 AND t2.i BETWEEN t1.b AND t1.e AND
2887
        t3.a=t2.a AND t3.c IN ('bb','ee') ;
2888
2889
EXPLAIN 
2890
SELECT t3.a FROM t1,t2 FORCE INDEX (si),t3
2891
  WHERE t1.id = 8 AND (t2.i=t1.b OR t2.i=t1.e) AND t3.a=t2.a AND
2892
        t3.c IN ('bb','ee');
2893
EXPLAIN 
2894
SELECT t3.a FROM t1,t2,t3
2895
  WHERE t1.id = 8 AND (t2.i=t1.b OR t2.i=t1.e) AND t3.a=t2.a AND
2896
        t3.c IN ('bb','ee');
2897
2898
DROP TABLE t1,t2,t3;
2899
 
2900
#
2901
# Bug#25172: Not checked buffer size leads to a server crash
2902
#
2903
CREATE TABLE t1 ( f1 int primary key, f2 int, f3 int, f4 int, f5 int, f6 int, checked_out int);
2904
CREATE TABLE t2 ( f11 int PRIMARY KEY );
2905
INSERT INTO t1 VALUES (1,1,1,0,0,0,0),(2,1,1,3,8,1,0),(3,1,1,4,12,1,0);
2906
INSERT INTO t2 VALUES (62);
2907
SELECT * FROM t1 LEFT JOIN t2 ON f11 = t1.checked_out GROUP BY f1 ORDER BY f2, f3, f4, f5 LIMIT 0, 1;
2908
DROP TABLE t1, t2;
2909
2910
#
2911
# Bug#6298: LIMIT #, -1 no longer works to set start with no end limit
2912
#
2913
2914
--disable_warnings
2915
DROP TABLE IF EXISTS t1;
2916
--enable_warnings
2917
2918
CREATE TABLE t1(a int);
2919
INSERT into t1 values (1), (2), (3);
2920
2921
# LIMIT N, -1 was accepted by accident in 4.0, but was not intended.
2922
# This test verifies that this illegal construct is now properly detected.
2923
2924
--error ER_PARSE_ERROR
2925
SELECT * FROM t1 LIMIT 2, -1;
2926
2927
DROP TABLE t1;
2928
2929
#
2930
# 25407: wrong estimate of NULL keys for unique indexes
2931
#
2932
2933
CREATE TABLE t1 (
2934
  ID_with_null int NULL,
2935
  ID_better int NOT NULL,
2936
  INDEX idx1 (ID_with_null),
2937
  INDEX idx2 (ID_better)
2938
);
2939
2940
INSERT INTO t1 VALUES (1,1), (2,1), (null,3), (null,3), (null,3), (null,3);
2941
INSERT INTO t1 SELECT * FROM t1 WHERE ID_with_null IS NULL;
2942
INSERT INTO t1 SELECT * FROM t1 WHERE ID_with_null IS NULL;
2943
INSERT INTO t1 SELECT * FROM t1 WHERE ID_with_null IS NULL;
2944
INSERT INTO t1 SELECT * FROM t1 WHERE ID_with_null IS NULL;
2945
INSERT INTO t1 SELECT * FROM t1 WHERE ID_with_null IS NULL;
2946
2947
SELECT COUNT(*) FROM t1 WHERE ID_with_null IS NULL;
2948
SELECT COUNT(*) FROM t1 WHERE ID_better=1;
2949
2950
EXPLAIN SELECT * FROM t1 WHERE ID_better=1 AND ID_with_null IS NULL;
2951
2952
DROP INDEX idx1 ON t1;
2953
CREATE UNIQUE INDEX idx1 ON t1(ID_with_null);
2954
2955
EXPLAIN SELECT * FROM t1 WHERE ID_better=1 AND ID_with_null IS NULL;
2956
2957
DROP TABLE t1;
2958
2959
CREATE TABLE t1 (
2960
  ID1_with_null int NULL,
2961
  ID2_with_null int NULL,
2962
  ID_better int NOT NULL,
2963
  INDEX idx1 (ID1_with_null, ID2_with_null),
2964
  INDEX idx2 (ID_better)
2965
);
2966
2967
INSERT INTO t1 VALUES (1,1,1), (2,2,1), (3,null,3), (null,3,3), (null,null,3),
2968
  (3,null,3), (null,3,3), (null,null,3), (3,null,3), (null,3,3), (null,null,3);
2969
2970
INSERT INTO t1 SELECT * FROM t1 WHERE ID1_with_null IS NULL;
2971
INSERT INTO t1 SELECT * FROM t1 WHERE ID2_with_null IS NULL;
2972
INSERT INTO t1 SELECT * FROM t1 WHERE ID1_with_null IS NULL;
2973
INSERT INTO t1 SELECT * FROM t1 WHERE ID2_with_null IS NULL;
2974
INSERT INTO t1 SELECT * FROM t1 WHERE ID1_with_null IS NULL;
2975
INSERT INTO t1 SELECT * FROM t1 WHERE ID2_with_null IS NULL;
2976
2977
SELECT COUNT(*) FROM t1 WHERE ID1_with_null IS NULL AND ID2_with_null=3;
2978
SELECT COUNT(*) FROM t1 WHERE ID1_with_null=3 AND ID2_with_null IS NULL;
2979
SELECT COUNT(*) FROM t1 WHERE ID1_with_null IS NULL AND ID2_with_null IS NULL;
2980
SELECT COUNT(*) FROM t1 WHERE ID_better=1;
2981
496.1.2 by Paul McCullagh
Changes to .test files to run both PBXT and InnoDB
2982
# PBXT: does not return a consistent row count
2983
--replace_column 9 #
1 by brian
clean slate
2984
EXPLAIN SELECT * FROM t1
2985
  WHERE ID_better=1 AND ID1_with_null IS NULL AND ID2_with_null=3 ;
496.1.2 by Paul McCullagh
Changes to .test files to run both PBXT and InnoDB
2986
--replace_column 9 #
1 by brian
clean slate
2987
EXPLAIN SELECT * FROM t1
2988
  WHERE ID_better=1 AND ID1_with_null=3 AND ID2_with_null=3 IS NULL ;
496.1.2 by Paul McCullagh
Changes to .test files to run both PBXT and InnoDB
2989
--replace_column 9 #
1 by brian
clean slate
2990
EXPLAIN SELECT * FROM t1
2991
  WHERE ID_better=1 AND ID1_with_null IS NULL AND ID2_with_null IS NULL;
2992
2993
DROP INDEX idx1 ON t1;
2994
CREATE UNIQUE INDEX idx1 ON t1(ID1_with_null,ID2_with_null);
2995
2996
EXPLAIN SELECT * FROM t1
2997
  WHERE ID_better=1 AND ID1_with_null IS NULL AND ID2_with_null=3 ;
2998
EXPLAIN SELECT * FROM t1
2999
  WHERE ID_better=1 AND ID1_with_null=3 AND ID2_with_null IS NULL ;
3000
EXPLAIN SELECT * FROM t1
3001
  WHERE ID_better=1 AND ID1_with_null IS NULL AND ID2_with_null IS NULL;
3002
EXPLAIN SELECT * FROM t1
3003
  WHERE ID_better=1 AND ID1_with_null IS NULL AND 
3004
        (ID2_with_null=1 OR ID2_with_null=2);
3005
3006
DROP TABLE t1;
3007
3008
#
3009
# Bug #22344: InnoDB keys act strange on datetime vs timestamp comparison
3010
#
3011
CREATE TABLE t1 (a INT, ts TIMESTAMP, KEY ts(ts));
3012
INSERT INTO t1 VALUES (30,"2006-01-03 23:00:00"), (31,"2006-01-03 23:00:00");
3013
ANALYZE TABLE t1;
3014
3015
CREATE TABLE t2 (a INT, dt1 DATETIME, dt2 DATETIME, PRIMARY KEY (a));
3016
INSERT INTO t2 VALUES (30, "2006-01-01 00:00:00", "2999-12-31 00:00:00");
3017
INSERT INTO t2 SELECT a+1,dt1,dt2 FROM t2;
3018
ANALYZE TABLE t2;
3019
3020
EXPLAIN
3021
SELECT * FROM t1 LEFT JOIN t2 ON (t1.a=t2.a) WHERE t1.a=30
3022
  AND t1.ts BETWEEN t2.dt1 AND t2.dt2
3023
  AND t1.ts BETWEEN "2006-01-01" AND "2006-12-31";
3024
3025
SELECT * FROM t1 LEFT JOIN t2 ON (t1.a=t2.a) WHERE t1.a=30
3026
  AND t1.ts BETWEEN t2.dt1 AND t2.dt2
3027
  AND t1.ts BETWEEN "2006-01-01" AND "2006-12-31";
3028
3029
DROP TABLE t1,t2;
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
3030
# Bug #22026: Warning when using IF statement and large bigint
1 by brian
clean slate
3031
#
3032
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
3033
create table t1 (a bigint);
1 by brian
clean slate
3034
insert into t1 values
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
3035
  (if(1, 92233720368547758, 1)),
3036
  (case when 1 then 92233720368547758 else 1 end),
3037
  (coalesce(92233720368547758, 1));
1 by brian
clean slate
3038
select * from t1;
3039
drop table t1;
3040
create table t1 select
3041
  if(1, 9223372036854775808, 1) i,
3042
  case when 1 then 9223372036854775808 else 1 end c,
3043
  coalesce(9223372036854775808, 1) co;
3044
show create table t1;
3045
drop table t1;
3046
# Ensure we handle big values properly
3047
select 
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
3048
  if(1, 1111111111111111111, 1) i,
3049
  case when 1 then 1111111111111111111 else 1 end c,
3050
  coalesce(1111111111111111111, 1) co;
1 by brian
clean slate
3051
3052
#
3053
# Bug #22971: indexes on text columns are ignored for ref accesses 
3054
#
3055
3056
CREATE TABLE t1 (name varchar(255));
3057
CREATE TABLE t2 (name varchar(255), n int, KEY (name(3)));
3058
INSERT INTO t1 VALUES ('ccc'), ('bb'), ('cc '), ('aa  '), ('aa');
3059
INSERT INTO t2 VALUES ('bb',1), ('aa',2), ('cc   ',3);
3060
INSERT INTO t2 VALUES (concat('cc ', 0x06), 4);
3061
INSERT INTO t2 VALUES ('cc',5), ('bb ',6), ('cc ',7);
3062
SELECT * FROM t2;
3063
SELECT * FROM t2 ORDER BY name;
3064
SELECT name, LENGTH(name), n FROM t2 ORDER BY name;
3065
3066
EXPLAIN SELECT name, LENGTH(name), n FROM t2 WHERE name='cc '; 
3067
SELECT name, LENGTH(name), n FROM t2 WHERE name='cc '; 
3068
EXPLAIN SELECT name , LENGTH(name), n FROM t2 WHERE name LIKE 'cc%';
3069
SELECT name , LENGTH(name), n FROM t2 WHERE name LIKE 'cc%';
3070
EXPLAIN SELECT name , LENGTH(name), n FROM t2 WHERE name LIKE 'cc%' ORDER BY name;
3071
SELECT name , LENGTH(name), n FROM t2 WHERE name LIKE 'cc%' ORDER BY name;
3072
EXPLAIN SELECT * FROM t1 LEFT JOIN t2 ON t1.name=t2.name;
3073
SELECT * FROM t1 LEFT JOIN t2 ON t1.name=t2.name;
3074
3075
DROP TABLE t1,t2;
3076
3077
CREATE TABLE t1 (name text);
3078
CREATE TABLE t2 (name text, n int, KEY (name(3)));
3079
INSERT INTO t1 VALUES ('ccc'), ('bb'), ('cc '), ('aa  '), ('aa');
3080
INSERT INTO t2 VALUES ('bb',1), ('aa',2), ('cc   ',3);
3081
INSERT INTO t2 VALUES (concat('cc ', 0x06), 4);
3082
INSERT INTO t2 VALUES ('cc',5), ('bb ',6), ('cc ',7);
3083
SELECT * FROM t2;
3084
SELECT * FROM t2 ORDER BY name;
3085
SELECT name, LENGTH(name), n FROM t2 ORDER BY name;
3086
3087
EXPLAIN SELECT name, LENGTH(name), n FROM t2 WHERE name='cc '; 
3088
SELECT name, LENGTH(name), n FROM t2 WHERE name='cc '; 
3089
EXPLAIN SELECT name , LENGTH(name), n FROM t2 WHERE name LIKE 'cc%';
3090
SELECT name , LENGTH(name), n FROM t2 WHERE name LIKE 'cc%';
3091
EXPLAIN SELECT name , LENGTH(name), n FROM t2 WHERE name LIKE 'cc%' ORDER BY name;
3092
SELECT name , LENGTH(name), n FROM t2 WHERE name LIKE 'cc%' ORDER BY name;
3093
EXPLAIN SELECT * FROM t1 LEFT JOIN t2 ON t1.name=t2.name;
3094
SELECT * FROM t1 LEFT JOIN t2 ON t1.name=t2.name;
3095
3096
DROP TABLE t1,t2;
3097
3098
3099
#
3100
# Bug #26963: join with predicates that contain fields from equalities evaluated
3101
#             to constants after constant table substitution
3102
#
3103
3104
CREATE TABLE t1 (
3105
 access_id int NOT NULL default '0',
3106
 name varchar(20) default NULL,
3107
 rank int NOT NULL default '0',
3108
 KEY idx (access_id)
3109
);
3110
3111
CREATE TABLE t2 (
3112
  faq_group_id int NOT NULL default '0',
3113
  faq_id int NOT NULL default '0',
3114
  access_id int default NULL,
3115
  UNIQUE KEY idx1 (faq_id),
3116
  KEY idx2 (faq_group_id,faq_id)
3117
);
3118
3119
INSERT INTO t1 VALUES 
3120
  (1,'Everyone',2),(2,'Help',3),(3,'Technical Support',1),(4,'Chat User',4);
3121
INSERT INTO t2 VALUES
3122
  (261,265,1),(490,494,1);
3123
3124
3125
SELECT t2.faq_id 
3126
  FROM t1 INNER JOIN t2 IGNORE INDEX (idx1)
3127
       ON (t1.access_id = t2.access_id)
3128
       LEFT JOIN t2 t
3129
       ON (t.faq_group_id = t2.faq_group_id AND
3130
           find_in_set(t.access_id, '1,4') < find_in_set(t2.access_id, '1,4'))
3131
   WHERE
3132
     t2.access_id IN (1,4) AND t.access_id IS NULL AND t2.faq_id in (265);
3133
3134
SELECT t2.faq_id 
3135
  FROM t1 INNER JOIN t2
3136
       ON (t1.access_id = t2.access_id)
3137
       LEFT JOIN t2 t
3138
       ON (t.faq_group_id = t2.faq_group_id AND
3139
           find_in_set(t.access_id, '1,4') < find_in_set(t2.access_id, '1,4'))
3140
   WHERE
3141
     t2.access_id IN (1,4) AND t.access_id IS NULL AND t2.faq_id in (265);
3142
3143
DROP TABLE t1,t2;
3144
3145
3146
#
3147
# Bug #19372: Optimizer does not use index anymore when WHERE index NOT IN
3148
# () is added
3149
#
3150
CREATE TABLE t1 (a INT, b INT, KEY inx (b,a));
3151
3152
INSERT INTO t1 VALUES (1,1), (1,2), (1,3), (1,4), (1,5), (1, 6), (1,7);
3153
EXPLAIN SELECT COUNT(*) FROM t1 f1 INNER JOIN t1 f2
3154
    ON ( f1.b=f2.b AND f1.a<f2.a ) 
3155
    WHERE 1 AND f1.b NOT IN (100,2232,3343,51111);
3156
DROP TABLE t1;    
3157
3158
#
3159
# Bug #27352: Incorrect result of nested selects instead of error reporting
3160
#
3161
3162
CREATE TABLE t1 (c1 INT, c2 INT);
3163
INSERT INTO t1 VALUES (1,11), (2,22), (2,22);
3164
3165
let $n= 31;
3166
let $q= COUNT(c2);
3167
while ($n)
3168
{
3169
  let $q= (SELECT $q);
3170
  dec $n;
3171
}
3172
--disable_warnings
3173
eval EXPLAIN SELECT c1 FROM t1 WHERE $q > 0;
3174
--enable_warnings
3175
3176
let $n= 64;
3177
let $q= COUNT(c2);
3178
while ($n)
3179
{
3180
  let $q= (SELECT $q);
3181
  dec $n;
3182
}
3183
--error ER_TOO_HIGH_LEVEL_OF_NESTING_FOR_SELECT
3184
eval EXPLAIN SELECT c1 FROM t1 WHERE $q > 0;
3185
3186
DROP TABLE t1;
3187
3188
#
3189
# Bug #30396: crash for a join with equalities and sargable predicates
3190
#             in disjunctive parts of the WHERE condition 
3191
#
3192
3193
CREATE TABLE t1 (
223 by Brian Aker
Cleanup int() work.
3194
  c1 int NOT NULL AUTO_INCREMENT,
1 by brian
clean slate
3195
  c2 varchar(1000) DEFAULT NULL,
223 by Brian Aker
Cleanup int() work.
3196
  c3 bigint DEFAULT NULL,
3197
  c4 bigint DEFAULT NULL,
1 by brian
clean slate
3198
  PRIMARY KEY (c1)
3199
);
3200
3201
EXPLAIN EXTENDED 
3202
SELECT  join_2.c1  
3203
FROM 
3204
	t1 AS join_0, 
3205
	t1 AS join_1, 
3206
	t1 AS join_2, 
3207
	t1 AS join_3, 
3208
	t1 AS join_4, 
3209
	t1 AS join_5, 
3210
	t1 AS join_6, 
3211
	t1 AS join_7
3212
WHERE 
3213
	join_0.c1=join_1.c1  AND 
3214
	join_1.c1=join_2.c1  AND 
3215
	join_2.c1=join_3.c1  AND 
3216
	join_3.c1=join_4.c1  AND 
3217
	join_4.c1=join_5.c1  AND 
3218
	join_5.c1=join_6.c1  AND 
3219
	join_6.c1=join_7.c1 
3220
         OR 
3221
	join_0.c2 < '?'  AND 
3222
	join_1.c2 < '?'  AND
3223
	join_2.c2 > '?'  AND
3224
	join_2.c2 < '!'  AND
3225
	join_3.c2 > '?'  AND 
3226
	join_4.c2 = '?'  AND 
3227
	join_5.c2 <> '?' AND
3228
	join_6.c2 <> '?' AND 
3229
	join_7.c2 >= '?' AND
3230
        join_0.c1=join_1.c1  AND 
3231
	join_1.c1=join_2.c1  AND 
3232
        join_2.c1=join_3.c1  AND
3233
	join_3.c1=join_4.c1  AND 
3234
	join_4.c1=join_5.c1  AND 
3235
	join_5.c1=join_6.c1  AND 
3236
	join_6.c1=join_7.c1
3237
GROUP BY 
3238
	join_3.c1,
3239
	join_2.c1,
3240
	join_7.c1,
3241
	join_1.c1,
3242
	join_0.c1;
3243
	
3244
SHOW WARNINGS;
3245
3246
DROP TABLE t1;
3247
3248
#
3249
# Bug #27695: Misleading warning when declaring all space column names and
3250
#             truncation of one-space column names to zero length names.
3251
#
3252
3253
--disable_ps_protocol
3254
SELECT 1 AS ` `;
3255
SELECT 1 AS `  `;
3256
SELECT 1 AS ` x`;
3257
--enable_ps_protocol
3258
3259
#
3260
# Bug #30666: Incorrect order when using range conditions on 2 tables or more
3261
#
3262
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
3263
CREATE TABLE t1 (c11 INT NOT NULL AUTO_INCREMENT PRIMARY KEY);
3264
CREATE TABLE t2 (c21 INT NOT NULL, 
1 by brian
clean slate
3265
                 c22 INT DEFAULT NULL, 
3266
                 KEY(c21, c22));
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
3267
CREATE TABLE t3 (c31 INT NOT NULL DEFAULT 0, 
1 by brian
clean slate
3268
                 c32 INT DEFAULT NULL, 
3269
                 c33 INT NOT NULL, 
413.2.2 by Brian Aker
Removed UNSIGNED from parser.
3270
                 c34 INT DEFAULT 0,
1 by brian
clean slate
3271
                 KEY (c33, c34, c32));
3272
3273
INSERT INTO t1 values (),(),(),(),();
3274
INSERT INTO t2 SELECT a.c11, b.c11 FROM t1 a, t1 b;
3275
INSERT INTO t3 VALUES (1, 1, 1, 0), 
3276
                      (2, 2, 0, 0), 
3277
                      (3, 3, 1, 0), 
3278
                      (4, 4, 0, 0), 
3279
                      (5, 5, 1, 0);
3280
3281
# Show that ORDER BY produces the correct results order
3282
SELECT c32 FROM t1, t2, t3 WHERE t1.c11 IN (1, 3, 5) AND 
3283
                                 t3.c31 = t1.c11 AND t2.c21 = t1.c11 AND 
3284
                                 t3.c33 = 1 AND t2.c22 in (1, 3) 
3285
                           ORDER BY c32; 
3286
3287
# Show that ORDER BY DESC produces the correct results order
3288
SELECT c32 FROM t1, t2, t3 WHERE t1.c11 IN (1, 3, 5) AND 
3289
                                 t3.c31 = t1.c11 AND t2.c21 = t1.c11 AND 
3290
                                 t3.c33 = 1 AND t2.c22 in (1, 3) 
3291
                           ORDER BY c32 DESC; 
3292
3293
DROP TABLE t1, t2, t3;
3294
3295
#
3296
# Bug#31800: Date comparison fails with timezone and slashes for greater
3297
#            than comparison
3298
#
3299
3300
# On DATETIME-like literals with trailing garbage, BETWEEN fudged in a
3301
# DATETIME comparator, while greater/less-than used bin-string comparisons.
3302
# Should correctly be compared as DATE or DATETIME, but throw a warning:
3303
3304
select str_to_date('2007-10-09','%Y-%m-%d') between '2007/10/01 00:00:00 GMT'
3305
                                                and '2007/10/20 00:00:00 GMT';
3306
select str_to_date('2007-10-09','%Y-%m-%d') > '2007/10/01 00:00:00 GMT-6';
3307
select str_to_date('2007-10-09','%Y-%m-%d') <= '2007/10/2000:00:00 GMT-6';
3308
3309
# We have all we need -- and trailing garbage:
3310
# (leaving out a leading zero in first example to prove it's a
3311
# value-comparison, not a string-comparison!)
3312
select str_to_date('2007-10-01','%Y-%m-%d') = '2007-10-1 00:00:00 GMT-6';
3313
select str_to_date('2007-10-01','%Y-%m-%d') = '2007-10-01 x00:00:00 GMT-6';
3314
select str_to_date('2007-10-01','%Y-%m-%d %H:%i:%s') = '2007-10-01 00:00:00 GMT-6';
3315
select str_to_date('2007-10-01','%Y-%m-%d %H:%i:%s') = '2007-10-01 00:x00:00 GMT-6';
3316
# no time at all:
3317
select str_to_date('2007-10-01','%Y-%m-%d %H:%i:%s') = '2007-10-01 x12:34:56 GMT-6';
3318
# partial time:
3319
select str_to_date('2007-10-01 12:34:00','%Y-%m-%d %H:%i:%s') = '2007-10-01 12:34x:56 GMT-6';
3320
# fail, different second part:
3321
select str_to_date('2007-10-01 12:34:56','%Y-%m-%d %H:%i:%s') = '2007-10-01 12:34x:56 GMT-6';
3322
# correct syntax, no trailing nonsense -- this one must throw no warning:
3323
select str_to_date('2007-10-01 12:34:56','%Y-%m-%d %H:%i:%s') = '2007-10-01 12:34:56';
3324
# no warning, but failure (different hour parts):
3325
select str_to_date('2007-10-01','%Y-%m-%d') = '2007-10-01 12:00:00';
3326
# succeed:
3327
select str_to_date('2007-10-01 12','%Y-%m-%d %H') = '2007-10-01 12:00:00';
3328
# succeed, but warn for "trailing garbage" (":34"):
3329
select str_to_date('2007-10-01 12:34','%Y-%m-%d %H') = '2007-10-01 12:00:00';
3330
# invalid date (Feb 30) succeeds
3331
select str_to_date('2007-02-30 12:34','%Y-%m-%d %H:%i') = '2007-02-30 12:34';
3332
# 0-day for both, just works in default SQL mode.
3333
select str_to_date('2007-10-00 12:34','%Y-%m-%d %H:%i') = '2007-10-00 12:34';
3334
# 0-day, succeed
3335
select str_to_date('2007-10-00','%Y-%m-%d') between '2007/09/01 00:00:00'
3336
                                                and '2007/10/20 00:00:00';
3337
select str_to_date('2007-10-00','%Y-%m-%d') between '' and '2007/10/20';
3338
select str_to_date('','%Y-%m-%d') between '2007/10/01' and '2007/10/20';
3339
select str_to_date('','%Y-%m-%d %H:%i') = '2007-10-01 12:34';
3340
select str_to_date(NULL,'%Y-%m-%d %H:%i') = '2007-10-01 12:34';
3341
select str_to_date('2007-10-00 12:34','%Y-%m-%d %H:%i') = '';
3342
3343
select str_to_date('1','%Y-%m-%d') = '1';
3344
select str_to_date('1','%Y-%m-%d') = '1';
3345
select str_to_date('','%Y-%m-%d') = '';
3346
3347
# these three should work!
3348
select str_to_date('1000-01-01','%Y-%m-%d') between '0000-00-00' and NULL;
3349
select str_to_date('1000-01-01','%Y-%m-%d') between NULL and '2000-00-00';
3350
select str_to_date('1000-01-01','%Y-%m-%d') between NULL and NULL;
3351
###########################################################################
3352
3353
--echo
3354
--echo #
3355
--echo # Bug#30736: Row Size Too Large Error Creating a Table and
3356
--echo # Inserting Data.
3357
--echo #
3358
3359
--disable_warnings
3360
DROP TABLE IF EXISTS t1;
3361
DROP TABLE IF EXISTS t2;
3362
--enable_warnings
3363
3364
--echo
3365
3366
CREATE TABLE t1(
3367
  c1 DECIMAL(10, 2),
3368
  c2 FLOAT);
3369
3370
--echo
3371
3372
INSERT INTO t1 VALUES (0, 1), (2, 3), (4, 5);
3373
3374
--echo
3375
3376
CREATE TABLE t2(
3377
  c3 DECIMAL(10, 2))
3378
  SELECT
3379
    c1 * c2 AS c3
3380
  FROM t1;
3381
3382
--echo
3383
3384
SELECT * FROM t1;
3385
3386
--echo
3387
3388
SELECT * FROM t2;
3389
3390
--echo
3391
3392
DROP TABLE t1;
3393
DROP TABLE t2;
3394
3395
--echo
3396
3397
###########################################################################
3398
3399
#
3400
# Bug #32335: Error on BIGINT > NULL + 1 
3401
#
3402
3403
CREATE TABLE t1 (c1 BIGINT NOT NULL);
3404
INSERT INTO t1 (c1) VALUES (1);
3405
SELECT * FROM t1 WHERE c1 > NULL + 1;
3406
DROP TABLE t1;
3407
3408
--echo
3409
3410
###########################################################################
3411
3412
#
3413
# Bug #33764: Wrong result with IN(), CONCAT() and implicit type conversion
3414
#
3415
3416
CREATE TABLE t1 (a VARCHAR(10) NOT NULL PRIMARY KEY);
3417
INSERT INTO t1 (a) VALUES ('foo0'), ('bar0'), ('baz0');
3418
SELECT * FROM t1 WHERE a IN (CONCAT('foo', 0), 'bar');
3419
DROP TABLE t1;
3420
3421
#
3422
# Bug #32942 now() - interval '7200' second is NOT pre-calculated, causing "full table scan"
3423
#
3424
3425
CREATE TABLE t1 (a INT, b INT);
3426
CREATE TABLE t2 (a INT, c INT, KEY(a));
3427
3428
INSERT INTO t1 VALUES (1, 1), (2, 2);
3429
INSERT INTO t2 VALUES (1, 1), (1, 2), (1, 3), (1, 4), (1, 5),
3430
                      (2, 1), (2, 2), (2, 3), (2, 4), (2, 5),
3431
                      (3, 1), (3, 2), (3, 3), (3, 4), (3, 5),
3432
                      (4, 1), (4, 2), (4, 3), (4, 4), (4, 5);
3433
3434
FLUSH STATUS;
3435
SELECT DISTINCT b FROM t1 LEFT JOIN t2 USING(a) WHERE c <= 3;
3436
SHOW STATUS LIKE 'Handler_read%';
3437
DROP TABLE t1, t2;
3438
3439
--echo End of 5.0 tests
3440
3441
#
3442
# Bug #30639: limit offset,rowcount wraps when rowcount >= 2^32 in windows
3443
#
3444
create table t1(a INT, KEY (a));
3445
INSERT INTO t1 VALUES (1),(2),(3),(4),(5);
3446
SELECT a FROM t1 ORDER BY a LIMIT 2;
3447
SELECT a FROM t1 ORDER BY a LIMIT 2,4294967296;
3448
SELECT a FROM t1 ORDER BY a LIMIT 2,4294967297;
3449
DROP TABLE t1;