~linuxjedi/drizzle/trunk-bug-667053

« back to all changes in this revision

Viewing changes to mysql-test/suite/parts/r/partition_int_innodb.result

  • Committer: brian
  • Date: 2008-06-25 05:29:13 UTC
  • Revision ID: brian@localhost.localdomain-20080625052913-6upwo0jsrl4lnapl
clean slate

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
create table t1 (a tinyint unsigned not null, primary key(a)) engine='InnoDB' 
 
2
partition by key (a) (
 
3
partition pa1 max_rows=20 min_rows=2,
 
4
partition pa2 max_rows=30 min_rows=3,
 
5
partition pa3 max_rows=30 min_rows=4,
 
6
partition pa4 max_rows=40 min_rows=2);
 
7
show create table t1;
 
8
Table   Create Table
 
9
t1      CREATE TABLE `t1` (
 
10
  `a` tinyint(3) unsigned NOT NULL,
 
11
  PRIMARY KEY (`a`)
 
12
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) (PARTITION pa1 MAX_ROWS = 20 MIN_ROWS = 2 ENGINE = InnoDB, PARTITION pa2 MAX_ROWS = 30 MIN_ROWS = 3 ENGINE = InnoDB, PARTITION pa3 MAX_ROWS = 30 MIN_ROWS = 4 ENGINE = InnoDB, PARTITION pa4 MAX_ROWS = 40 MIN_ROWS = 2 ENGINE = InnoDB) */
 
13
insert into t1 values (255), (254), (253), (252), (1), (2), (128);
 
14
select * from t1;
 
15
a
 
16
1
 
17
2
 
18
128
 
19
252
 
20
253
 
21
254
 
22
255
 
23
select * from t1 where a=253;
 
24
a
 
25
253
 
26
delete from t1 where a=253;
 
27
select * from t1;
 
28
a
 
29
1
 
30
2
 
31
128
 
32
252
 
33
254
 
34
255
 
35
drop table t1;
 
36
create table t2 (a tinyint unsigned not null, primary key(a)) engine='InnoDB' 
 
37
partition by key (a) partitions 8;
 
38
show create table t2;
 
39
Table   Create Table
 
40
t2      CREATE TABLE `t2` (
 
41
  `a` tinyint(3) unsigned NOT NULL,
 
42
  PRIMARY KEY (`a`)
 
43
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 8  */
 
44
insert into t2 values (255), (254), (253), (252);
 
45
select * from t2;
 
46
a
 
47
252
 
48
253
 
49
254
 
50
255
 
51
select * from t2 where a=253;
 
52
a
 
53
253
 
54
delete from t2 where a=253;
 
55
select * from t2;
 
56
a
 
57
252
 
58
254
 
59
255
 
60
delete from t2;
 
61
255 inserts;
 
62
select count(*) from t2;
 
63
count(*)
 
64
255
 
65
drop table t2;
 
66
create table t3 (a tinyint not null, primary key(a)) engine='InnoDB' 
 
67
partition by key (a) partitions 10;
 
68
show create table t3;
 
69
Table   Create Table
 
70
t3      CREATE TABLE `t3` (
 
71
  `a` tinyint(4) NOT NULL,
 
72
  PRIMARY KEY (`a`)
 
73
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 10  */
 
74
insert into t3 values (127), (126), (125), (124), (-128), (-127), (1), (-1), (0);
 
75
select * from t3;
 
76
a
 
77
-128
 
78
-127
 
79
-1
 
80
0
 
81
1
 
82
124
 
83
125
 
84
126
 
85
127
 
86
select * from t3 where a=125;
 
87
a
 
88
125
 
89
delete from t3 where a=125;
 
90
select * from t3;
 
91
a
 
92
-128
 
93
-127
 
94
-1
 
95
0
 
96
1
 
97
124
 
98
126
 
99
127
 
100
drop table t3;
 
101
create table t1 (a smallint unsigned not null, primary key(a)) engine='InnoDB' 
 
102
partition by key (a) (
 
103
partition pa1 max_rows=20 min_rows=2,
 
104
partition pa2 max_rows=30 min_rows=3,
 
105
partition pa3 max_rows=30 min_rows=4,
 
106
partition pa4 max_rows=40 min_rows=2);
 
107
show create table t1;
 
108
Table   Create Table
 
109
t1      CREATE TABLE `t1` (
 
110
  `a` smallint(5) unsigned NOT NULL,
 
111
  PRIMARY KEY (`a`)
 
112
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) (PARTITION pa1 MAX_ROWS = 20 MIN_ROWS = 2 ENGINE = InnoDB, PARTITION pa2 MAX_ROWS = 30 MIN_ROWS = 3 ENGINE = InnoDB, PARTITION pa3 MAX_ROWS = 30 MIN_ROWS = 4 ENGINE = InnoDB, PARTITION pa4 MAX_ROWS = 40 MIN_ROWS = 2 ENGINE = InnoDB) */
 
113
insert into t1 values (65535), (65534), (65533), (65532), (1), (2), (256);
 
114
select * from t1;
 
115
a
 
116
1
 
117
2
 
118
256
 
119
65532
 
120
65533
 
121
65534
 
122
65535
 
123
select * from t1 where a=65533;
 
124
a
 
125
65533
 
126
delete from t1 where a=65533;
 
127
select * from t1;
 
128
a
 
129
1
 
130
2
 
131
256
 
132
65532
 
133
65534
 
134
65535
 
135
drop table t1;
 
136
create table t2 (a smallint unsigned not null, primary key(a)) engine='InnoDB' 
 
137
partition by key (a) partitions 8;
 
138
show create table t2;
 
139
Table   Create Table
 
140
t2      CREATE TABLE `t2` (
 
141
  `a` smallint(5) unsigned NOT NULL,
 
142
  PRIMARY KEY (`a`)
 
143
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 8  */
 
144
insert into t2 values (65535), (65534), (65533), (65532);
 
145
select * from t2;
 
146
a
 
147
65532
 
148
65533
 
149
65534
 
150
65535
 
151
select * from t2 where a=65533;
 
152
a
 
153
65533
 
154
delete from t2 where a=65533;
 
155
select * from t2;
 
156
a
 
157
65532
 
158
65534
 
159
65535
 
160
delete from t2;
 
161
1024 inserts;
 
162
select count(*) from t2;
 
163
count(*)
 
164
1024
 
165
drop table t2;
 
166
create table t3 (a smallint not null, primary key(a)) engine='InnoDB' 
 
167
partition by key (a) partitions 10;
 
168
show create table t3;
 
169
Table   Create Table
 
170
t3      CREATE TABLE `t3` (
 
171
  `a` smallint(6) NOT NULL,
 
172
  PRIMARY KEY (`a`)
 
173
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 10  */
 
174
insert into t3 values (32767), (32766), (32765), (32764), (-32768), (-32767), (1), (-1), (0);
 
175
select * from t3;
 
176
a
 
177
-32768
 
178
-32767
 
179
-1
 
180
0
 
181
1
 
182
32764
 
183
32765
 
184
32766
 
185
32767
 
186
select * from t3 where a=32765;
 
187
a
 
188
32765
 
189
delete from t3 where a=32765;
 
190
select * from t3;
 
191
a
 
192
-32768
 
193
-32767
 
194
-1
 
195
0
 
196
1
 
197
32764
 
198
32766
 
199
32767
 
200
drop table t3;
 
201
create table t1 (a int unsigned not null, primary key(a)) engine='InnoDB' 
 
202
partition by key (a) (
 
203
partition pa1 max_rows=20 min_rows=2,
 
204
partition pa2 max_rows=30 min_rows=3,
 
205
partition pa3 max_rows=30 min_rows=4,
 
206
partition pa4 max_rows=40 min_rows=2);
 
207
show create table t1;
 
208
Table   Create Table
 
209
t1      CREATE TABLE `t1` (
 
210
  `a` int(10) unsigned NOT NULL,
 
211
  PRIMARY KEY (`a`)
 
212
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) (PARTITION pa1 MAX_ROWS = 20 MIN_ROWS = 2 ENGINE = InnoDB, PARTITION pa2 MAX_ROWS = 30 MIN_ROWS = 3 ENGINE = InnoDB, PARTITION pa3 MAX_ROWS = 30 MIN_ROWS = 4 ENGINE = InnoDB, PARTITION pa4 MAX_ROWS = 40 MIN_ROWS = 2 ENGINE = InnoDB) */
 
213
insert into t1 values (4294967295), (4294967294), (4294967293), (4294967292), (1), (2), (65535);
 
214
select * from t1;
 
215
a
 
216
1
 
217
2
 
218
65535
 
219
4294967292
 
220
4294967293
 
221
4294967294
 
222
4294967295
 
223
select * from t1 where a=4294967293;
 
224
a
 
225
4294967293
 
226
delete from t1 where a=4294967293;
 
227
select * from t1;
 
228
a
 
229
1
 
230
2
 
231
65535
 
232
4294967292
 
233
4294967294
 
234
4294967295
 
235
drop table t1;
 
236
create table t2 (a int unsigned not null, primary key(a)) engine='InnoDB' 
 
237
partition by key (a) partitions 10;
 
238
show create table t2;
 
239
Table   Create Table
 
240
t2      CREATE TABLE `t2` (
 
241
  `a` int(10) unsigned NOT NULL,
 
242
  PRIMARY KEY (`a`)
 
243
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 10  */
 
244
insert into t2 values (4294967295), (4294967294), (4294967293), (4294967292);
 
245
select * from t2;
 
246
a
 
247
4294967292
 
248
4294967293
 
249
4294967294
 
250
4294967295
 
251
select * from t2 where a=4294967293;
 
252
a
 
253
4294967293
 
254
delete from t2 where a=4294967293;
 
255
select * from t2;
 
256
a
 
257
4294967292
 
258
4294967294
 
259
4294967295
 
260
delete from t2;
 
261
1024 inserts;
 
262
select count(*) from t2;
 
263
count(*)
 
264
1024
 
265
drop table t2;
 
266
create table t3 (a int not null, primary key(a)) engine='InnoDB' 
 
267
partition by key (a) partitions 10;
 
268
show create table t3;
 
269
Table   Create Table
 
270
t3      CREATE TABLE `t3` (
 
271
  `a` int(11) NOT NULL,
 
272
  PRIMARY KEY (`a`)
 
273
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 10  */
 
274
insert into t3 values (2147483647), (2147483646), (2147483645), (2147483644), (-2147483648), (-2147483647), (1), (-1), (0);
 
275
select * from t3;
 
276
a
 
277
-2147483648
 
278
-2147483647
 
279
-1
 
280
0
 
281
1
 
282
2147483644
 
283
2147483645
 
284
2147483646
 
285
2147483647
 
286
select * from t3 where a=2147483645;
 
287
a
 
288
2147483645
 
289
delete from t3 where a=2147483645;
 
290
select * from t3;
 
291
a
 
292
-2147483648
 
293
-2147483647
 
294
-1
 
295
0
 
296
1
 
297
2147483644
 
298
2147483646
 
299
2147483647
 
300
drop table t3;
 
301
create table t1 (a mediumint unsigned not null, primary key(a)) engine='InnoDB' 
 
302
partition by key (a) (
 
303
partition pa1 max_rows=20 min_rows=2,
 
304
partition pa2 max_rows=30 min_rows=3,
 
305
partition pa3 max_rows=30 min_rows=4,
 
306
partition pa4 max_rows=40 min_rows=2);
 
307
show create table t1;
 
308
Table   Create Table
 
309
t1      CREATE TABLE `t1` (
 
310
  `a` mediumint(8) unsigned NOT NULL,
 
311
  PRIMARY KEY (`a`)
 
312
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) (PARTITION pa1 MAX_ROWS = 20 MIN_ROWS = 2 ENGINE = InnoDB, PARTITION pa2 MAX_ROWS = 30 MIN_ROWS = 3 ENGINE = InnoDB, PARTITION pa3 MAX_ROWS = 30 MIN_ROWS = 4 ENGINE = InnoDB, PARTITION pa4 MAX_ROWS = 40 MIN_ROWS = 2 ENGINE = InnoDB) */
 
313
insert into t1 values (16777215), (16777214), (16777213), (16777212), (1), (2), (65535);
 
314
select * from t1;
 
315
a
 
316
1
 
317
2
 
318
65535
 
319
16777212
 
320
16777213
 
321
16777214
 
322
16777215
 
323
select * from t1 where a=16777213;
 
324
a
 
325
16777213
 
326
delete from t1 where a=16777213;
 
327
select * from t1;
 
328
a
 
329
1
 
330
2
 
331
65535
 
332
16777212
 
333
16777214
 
334
16777215
 
335
drop table t1;
 
336
create table t2 (a mediumint unsigned not null, primary key(a)) engine='InnoDB' 
 
337
partition by key (a) partitions 8;
 
338
show create table t2;
 
339
Table   Create Table
 
340
t2      CREATE TABLE `t2` (
 
341
  `a` mediumint(8) unsigned NOT NULL,
 
342
  PRIMARY KEY (`a`)
 
343
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 8  */
 
344
insert into t2 values (16777215), (16777214), (16777213), (16777212);
 
345
select * from t2;
 
346
a
 
347
16777212
 
348
16777213
 
349
16777214
 
350
16777215
 
351
select * from t2 where a=16777213;
 
352
a
 
353
16777213
 
354
delete from t2 where a=16777213;
 
355
select * from t2;
 
356
a
 
357
16777212
 
358
16777214
 
359
16777215
 
360
delete from t2;
 
361
1024 inserts;
 
362
select count(*) from t2;
 
363
count(*)
 
364
1024
 
365
drop table t2;
 
366
create table t3 (a mediumint not null, primary key(a)) engine='InnoDB' 
 
367
partition by key (a) partitions 10;
 
368
show create table t3;
 
369
Table   Create Table
 
370
t3      CREATE TABLE `t3` (
 
371
  `a` mediumint(9) NOT NULL,
 
372
  PRIMARY KEY (`a`)
 
373
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 10  */
 
374
insert into t3 values (8388607), (8388606), (8388605), (8388604), (-8388608), (-8388607), (1), (-1), (0);
 
375
select * from t3;
 
376
a
 
377
-8388608
 
378
-8388607
 
379
-1
 
380
0
 
381
1
 
382
8388604
 
383
8388605
 
384
8388606
 
385
8388607
 
386
select * from t3 where a=8388605;
 
387
a
 
388
8388605
 
389
delete from t3 where a=8388605;
 
390
select * from t3;
 
391
a
 
392
-8388608
 
393
-8388607
 
394
-1
 
395
0
 
396
1
 
397
8388604
 
398
8388606
 
399
8388607
 
400
drop table t3;
 
401
create table t1 (a bigint unsigned not null, primary key(a)) engine='InnoDB' 
 
402
partition by key (a) (
 
403
partition pa1 max_rows=20 min_rows=2,
 
404
partition pa2 max_rows=30 min_rows=3,
 
405
partition pa3 max_rows=30 min_rows=4,
 
406
partition pa4 max_rows=40 min_rows=2);
 
407
show create table t1;
 
408
Table   Create Table
 
409
t1      CREATE TABLE `t1` (
 
410
  `a` bigint(20) unsigned NOT NULL,
 
411
  PRIMARY KEY (`a`)
 
412
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) (PARTITION pa1 MAX_ROWS = 20 MIN_ROWS = 2 ENGINE = InnoDB, PARTITION pa2 MAX_ROWS = 30 MIN_ROWS = 3 ENGINE = InnoDB, PARTITION pa3 MAX_ROWS = 30 MIN_ROWS = 4 ENGINE = InnoDB, PARTITION pa4 MAX_ROWS = 40 MIN_ROWS = 2 ENGINE = InnoDB) */
 
413
insert into t1 values (18446744073709551615), (0xFFFFFFFFFFFFFFFE), (18446744073709551613), (18446744073709551612), (1), (2), (65535);
 
414
select * from t1;
 
415
a
 
416
1
 
417
2
 
418
65535
 
419
18446744073709551612
 
420
18446744073709551613
 
421
18446744073709551614
 
422
18446744073709551615
 
423
select * from t1 where a=-2;
 
424
a
 
425
delete from t1 where a=-2;
 
426
select * from t1;
 
427
a
 
428
1
 
429
2
 
430
65535
 
431
18446744073709551612
 
432
18446744073709551613
 
433
18446744073709551614
 
434
18446744073709551615
 
435
select * from t1 where a=18446744073709551615;
 
436
a
 
437
18446744073709551615
 
438
delete from t1 where a=18446744073709551615;
 
439
select * from t1;
 
440
a
 
441
1
 
442
2
 
443
65535
 
444
18446744073709551612
 
445
18446744073709551613
 
446
18446744073709551614
 
447
drop table t1;
 
448
create table t2 (a bigint unsigned not null, primary key(a)) engine='InnoDB' 
 
449
partition by key (a) partitions 10;
 
450
show create table t2;
 
451
Table   Create Table
 
452
t2      CREATE TABLE `t2` (
 
453
  `a` bigint(20) unsigned NOT NULL,
 
454
  PRIMARY KEY (`a`)
 
455
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 10  */
 
456
insert into t2 values (18446744073709551615), (0xFFFFFFFFFFFFFFFE), (18446744073709551613), (18446744073709551612);
 
457
select * from t2;
 
458
a
 
459
18446744073709551612
 
460
18446744073709551613
 
461
18446744073709551614
 
462
18446744073709551615
 
463
select * from t2 where a=18446744073709551615;
 
464
a
 
465
18446744073709551615
 
466
delete from t2 where a=18446744073709551615;
 
467
select * from t2;
 
468
a
 
469
18446744073709551612
 
470
18446744073709551613
 
471
18446744073709551614
 
472
delete from t2;
 
473
1024 inserts;
 
474
select count(*) from t2;
 
475
count(*)
 
476
1024
 
477
drop table t2;
 
478
create table t3 (a bigint not null, primary key(a)) engine='InnoDB' 
 
479
partition by key (a) partitions 10;
 
480
show create table t3;
 
481
Table   Create Table
 
482
t3      CREATE TABLE `t3` (
 
483
  `a` bigint(20) NOT NULL,
 
484
  PRIMARY KEY (`a`)
 
485
) ENGINE=InnoDB DEFAULT CHARSET=latin1 /*!50100 PARTITION BY KEY (a) PARTITIONS 10  */
 
486
insert into t3 values (9223372036854775807), (9223372036854775806), (9223372036854775805), (9223372036854775804), (-9223372036854775808), (-9223372036854775807), (1), (-1), (0);
 
487
select * from t3;
 
488
a
 
489
-9223372036854775808
 
490
-9223372036854775807
 
491
-1
 
492
0
 
493
1
 
494
9223372036854775804
 
495
9223372036854775805
 
496
9223372036854775806
 
497
9223372036854775807
 
498
select * from t3 where a=9223372036854775806;
 
499
a
 
500
9223372036854775806
 
501
delete from t3 where a=9223372036854775806;
 
502
select * from t3;
 
503
a
 
504
-9223372036854775808
 
505
-9223372036854775807
 
506
-1
 
507
0
 
508
1
 
509
9223372036854775804
 
510
9223372036854775805
 
511
9223372036854775807
 
512
drop table t3;