296
321
Table Op Msg_type Msg_text
297
322
test.t1 check status OK
299
CREATE TEMPORARY TABLE t1 (a varchar(300), b varchar(300), c varchar(300), d varchar(300), e varchar(300), KEY t1 (a, b, c, d, e)) ENGINE=MyISAM;
324
CREATE TABLE t1 (a varchar(300), b varchar(300), c varchar(300), d varchar(300), e varchar(300), KEY t1 (a, b, c, d, e)) ENGINE=MyISAM;
300
325
ERROR 42000: Specified key was too long; max key length is 1332 bytes
301
CREATE TEMPORARY TABLE t1 (a varchar(300), b varchar(300), c varchar(300), d varchar(300), e varchar(300)) ENGINE=MyISAM;
326
CREATE TABLE t1 (a varchar(300), b varchar(300), c varchar(300), d varchar(300), e varchar(300)) ENGINE=MyISAM;
302
327
ALTER TABLE t1 ADD INDEX t1 (a, b, c, d, e);
303
328
ERROR 42000: Specified key was too long; max key length is 1332 bytes
305
CREATE TEMPORARY TABLE t1 (a int not null, b int, c int, key(b), key(c), key(a,b), key(c,a)) ENGINE=MyISAM;
330
CREATE TABLE t1 (a int not null, b int, c int, key(b), key(c), key(a,b), key(c,a)) ENGINE=MyISAM;
306
331
INSERT into t1 values (0, null, 0), (0, null, 1), (0, null, 2), (0, null,3), (1,1,4);
307
332
create table t2 (a int not null, b int, c int, key(b), key(c), key(a));
308
333
INSERT into t2 values (1,1,1), (2,2,2);
309
alter table t1 ENGINE=MYISAM;
335
Table Op Msg_type Msg_text
336
test.t1 optimize status OK
310
337
show index from t1;
311
Table Unique Key_name Seq_in_index Column_name
338
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment Index_Comment
339
t1 1 b 1 b A 5 NULL NULL YES BTREE
340
t1 1 c 1 c A 5 NULL NULL YES BTREE
341
t1 1 a 1 a A 1 NULL NULL BTREE
342
t1 1 a 2 b A 5 NULL NULL YES BTREE
343
t1 1 c_2 1 c A 5 NULL NULL YES BTREE
344
t1 1 c_2 2 a A 5 NULL NULL BTREE
318
345
explain select * from t1,t2 where t1.a=t2.a;
319
346
id select_type table type possible_keys key key_len ref rows Extra
320
347
1 SIMPLE t2 ALL a NULL NULL NULL 2
321
1 SIMPLE t1 ref a a 4 test.t2.a 1
348
1 SIMPLE t1 ALL a NULL NULL NULL 5 Using where; Using join buffer
322
349
explain select * from t1,t2 force index(a) where t1.a=t2.a;
323
350
id select_type table type possible_keys key key_len ref rows Extra
324
351
1 SIMPLE t2 ALL a NULL NULL NULL 2
325
1 SIMPLE t1 ref a a 4 test.t2.a 1
352
1 SIMPLE t1 ALL a NULL NULL NULL 5 Using where; Using join buffer
326
353
explain select * from t1 force index(a),t2 force index(a) where t1.a=t2.a;
327
354
id select_type table type possible_keys key key_len ref rows Extra
328
355
1 SIMPLE t2 ALL a NULL NULL NULL 2
329
1 SIMPLE t1 ref a a 4 test.t2.a 1
356
1 SIMPLE t1 ref a a 4 test.t2.a 3
330
357
explain select * from t1,t2 where t1.b=t2.b;
331
358
id select_type table type possible_keys key key_len ref rows Extra
332
359
1 SIMPLE t2 ALL b NULL NULL NULL 2
333
1 SIMPLE t1 ALL b NULL NULL NULL 5 Using where; Using join buffer
360
1 SIMPLE t1 ref b b 5 test.t2.b 1
334
361
explain select * from t1,t2 force index(c) where t1.a=t2.a;
335
362
id select_type table type possible_keys key key_len ref rows Extra
336
363
1 SIMPLE t2 ALL NULL NULL NULL NULL 2
337
1 SIMPLE t1 ref a a 4 test.t2.a 1
364
1 SIMPLE t1 ALL a NULL NULL NULL 5 Using where; Using join buffer
338
365
explain select * from t1 where a=0 or a=2;
339
366
id select_type table type possible_keys key key_len ref rows Extra
340
367
1 SIMPLE t1 ALL a NULL NULL NULL 5 Using where
341
368
explain select * from t1 force index (a) where a=0 or a=2;
342
369
id select_type table type possible_keys key key_len ref rows Extra
343
1 SIMPLE t1 range a a 4 NULL 4 Using where
370
1 SIMPLE t1 range a a 4 NULL 4 Using where; Using MRR
344
371
explain select * from t1 where c=1;
345
372
id select_type table type possible_keys key key_len ref rows Extra
346
373
1 SIMPLE t1 ref c,c_2 c 5 const 1
621
CREATE TABLE t1(a CHAR(9), b VARCHAR(7)) ENGINE=MyISAM;
622
INSERT INTO t1(a) VALUES('xxxxxxxxx'),('xxxxxxxxx');
623
UPDATE t1 AS ta1,t1 AS ta2 SET ta1.b='aaaaaa',ta2.b='bbbbbb';
595
629
SET GLOBAL myisam_repair_threads=2;
596
630
SHOW VARIABLES LIKE 'myisam_repair%';
597
631
Variable_name Value
598
632
myisam_repair_threads 2
599
CREATE TEMPORARY TABLE t1 (
600
`_id` int NOT NULL default '0',
604
`loverlap` int default NULL,
605
`roverlap` int default NULL,
606
`lneighbor_id` int default NULL,
607
`rneighbor_id` int default NULL,
608
`length_` int default NULL,
611
`_obj_class` text NOT NULL,
613
UNIQUE KEY `sequence_name_index` (`name`(50)),
616
INSERT INTO t1 VALUES
617
(1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample1',''),
618
(2,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample2',''),
619
(3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample3',''),
620
(4,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample4',''),
621
(5,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample5',''),
622
(6,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample6',''),
623
(7,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample7',''),
624
(8,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample8',''),
625
(9,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample9','');
637
DELETE FROM t1 WHERE _id < 8;
638
show table status LIKE 't1';
639
Session Schema Name Type Engine Version Rows Avg_row_length Table_size Auto_increment
640
# test t1 TEMPORARY MyISAM # # # # #
642
Table Op Msg_type Msg_text
643
test.t1 check status OK
644
ALTER TABLE t1 ENGINE=MYISAM;
646
Table Op Msg_type Msg_text
647
test.t1 check status OK
648
show table status LIKE 't1';
649
Session Schema Name Type Engine Version Rows Avg_row_length Table_size Auto_increment
650
# test t1 TEMPORARY MyISAM # # # # #
634
`_id` int NOT NULL default '0',
638
`loverlap` int default NULL,
639
`roverlap` int default NULL,
640
`lneighbor_id` int default NULL,
641
`rneighbor_id` int default NULL,
642
`length_` int default NULL,
645
`_obj_class` text NOT NULL,
647
UNIQUE KEY `sequence_name_index` (`name`(50)),
650
INSERT INTO t1 VALUES
651
(1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample1',''),
652
(2,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample2',''),
653
(3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample3',''),
654
(4,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample4',''),
655
(5,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample5',''),
656
(6,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample6',''),
657
(7,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample7',''),
658
(8,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample8',''),
659
(9,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample9','');
671
DELETE FROM t1 WHERE _id < 8;
672
SHOW TABLE STATUS LIKE 't1';
673
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
674
t1 MyISAM 0 Dynamic 2 # # # # 168 # # # # # #
675
CHECK TABLE t1 EXTENDED;
676
Table Op Msg_type Msg_text
677
test.t1 check status OK
679
Table Op Msg_type Msg_text
680
test.t1 optimize status OK
681
CHECK TABLE t1 EXTENDED;
682
Table Op Msg_type Msg_text
683
test.t1 check status OK
684
SHOW TABLE STATUS LIKE 't1';
685
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
686
t1 MyISAM 0 Dynamic 2 # # # # 0 # # # # # #
693
`_id` int NOT NULL default '0',
697
`loverlap` int default NULL,
698
`roverlap` int default NULL,
699
`lneighbor_id` int default NULL,
700
`rneighbor_id` int default NULL,
701
`length_` int default NULL,
704
`_obj_class` text NOT NULL,
706
UNIQUE KEY `sequence_name_index` (`name`(50)),
709
INSERT INTO t1 VALUES
710
(1,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample1',''),
711
(2,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample2',''),
712
(3,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample3',''),
713
(4,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample4',''),
714
(5,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample5',''),
715
(6,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample6',''),
716
(7,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample7',''),
717
(8,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample8',''),
718
(9,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,'sample9','');
730
DELETE FROM t1 WHERE _id < 8;
731
SHOW TABLE STATUS LIKE 't1';
732
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
733
t1 MyISAM 0 Dynamic 2 # # # # 168 # # # # # #
734
CHECK TABLE t1 EXTENDED;
735
Table Op Msg_type Msg_text
736
test.t1 check status OK
737
REPAIR TABLE t1 QUICK;
738
Table Op Msg_type Msg_text
739
test.t1 repair status OK
740
CHECK TABLE t1 EXTENDED;
741
Table Op Msg_type Msg_text
742
test.t1 check status OK
743
SHOW TABLE STATUS LIKE 't1';
744
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
745
t1 MyISAM 0 Dynamic 2 # # # # 168 # # # # # #
651
746
SELECT _id FROM t1;
1438
CREATE TEMPORARY TABLE t1 (c1 INT, c2 INT, UNIQUE INDEX (c1), INDEX (c2)) ENGINE=MYISAM;
1439
show table status like 't1';
1440
Session Schema Name Type Engine Version Rows Avg_row_length Table_size Auto_increment
1441
# test t1 TEMPORARY MyISAM # # # # #
1557
CREATE TABLE t1 (c1 INT, c2 INT, UNIQUE INDEX (c1), INDEX (c2)) ENGINE=MYISAM;
1558
SHOW TABLE STATUS LIKE 't1';
1559
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
1560
t1 MyISAM 0 Fixed 0 # # # 1024 # # # # # # #
1442
1561
INSERT INTO t1 VALUES (1,1);
1443
show table status like 't1';
1444
Session Schema Name Type Engine Version Rows Avg_row_length Table_size Auto_increment
1445
# test t1 TEMPORARY MyISAM # # # # #
1446
ALTER TABLE t1 DISABLE KEYS;
1447
show table status like 't1';
1448
Session Schema Name Type Engine Version Rows Avg_row_length Table_size Auto_increment
1449
# test t1 TEMPORARY MyISAM # # # # #
1450
ALTER TABLE t1 ENABLE KEYS;
1451
show table status like 't1';
1452
Session Schema Name Type Engine Version Rows Avg_row_length Table_size Auto_increment
1453
# test t1 TEMPORARY MyISAM # # # # #
1454
ALTER TABLE t1 DISABLE KEYS;
1455
show table status like 't1';
1456
Session Schema Name Type Engine Version Rows Avg_row_length Table_size Auto_increment
1457
# test t1 TEMPORARY MyISAM # # # # #
1458
ALTER TABLE t1 ENABLE KEYS;
1459
show table status like 't1';
1460
Session Schema Name Type Engine Version Rows Avg_row_length Table_size Auto_increment
1461
# test t1 TEMPORARY MyISAM # # # # #
1562
SHOW TABLE STATUS LIKE 't1';
1563
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
1564
t1 MyISAM 0 Fixed 1 # # # 3072 # # # # # # #
1565
ALTER TABLE t1 DISABLE KEYS;
1566
SHOW TABLE STATUS LIKE 't1';
1567
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
1568
t1 MyISAM 0 Fixed 1 # # # 3072 # # # # # # #
1569
ALTER TABLE t1 ENABLE KEYS;
1570
SHOW TABLE STATUS LIKE 't1';
1571
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
1572
t1 MyISAM 0 Fixed 1 # # # 3072 # # # # # # #
1573
ALTER TABLE t1 DISABLE KEYS;
1574
SHOW TABLE STATUS LIKE 't1';
1575
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
1576
t1 MyISAM 0 Fixed 1 # # # 3072 # # # # # # #
1577
ALTER TABLE t1 ENABLE KEYS;
1578
SHOW TABLE STATUS LIKE 't1';
1579
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
1580
t1 MyISAM 0 Fixed 1 # # # 3072 # # # # # # #
1462
1581
# Enable keys with parallel repair
1463
1582
SET GLOBAL myisam_repair_threads=2;
1464
1583
ALTER TABLE t1 DISABLE KEYS;
1465
1584
ALTER TABLE t1 ENABLE KEYS;
1466
1585
SET GLOBAL myisam_repair_threads=1;
1586
CHECK TABLE t1 EXTENDED;
1468
1587
Table Op Msg_type Msg_text
1469
1588
test.t1 check status OK
1471
CREATE TABLE t1 (id int NOT NULL, ref int NOT NULL, INDEX (id));
1590
CREATE TABLE t1 (id int NOT NULL, ref int NOT NULL, INDEX (id)) ENGINE=MyISAM;
1472
1591
CREATE TABLE t2 LIKE t1;
1473
1592
INSERT INTO t2 (id, ref) VALUES (1,3), (2,1), (3,2), (4,5), (4,4);
1474
1593
INSERT INTO t1 SELECT * FROM t2;
1604
DELETE FROM a USING t1 AS a INNER JOIN t1 AS b USING (id) WHERE a.ref < b.ref;
1485
1611
DROP TABLE t1, t2;
1486
1612
End of 5.0 tests
1487
create temporary table t1 (a int not null, key `a` (a) key_block_size=1024) ENGINE=MyISAM;
1613
create table t1 (a int not null, key `a` (a) key_block_size=1024) ENGINE=MyISAM;
1488
1614
show create table t1;
1489
1615
Table Create Table
1490
t1 CREATE TEMPORARY TABLE `t1` (
1616
t1 CREATE TABLE `t1` (
1491
1617
`a` int NOT NULL,
1492
1618
KEY `a` (`a`) KEY_BLOCK_SIZE=1024
1493
1619
) ENGINE=MyISAM
1495
create temporary table t1 (a int not null, key `a` (a) key_block_size=2048) ENGINE=MyISAM;
1621
create table t1 (a int not null, key `a` (a) key_block_size=2048) ENGINE=MyISAM;
1496
1622
show create table t1;
1497
1623
Table Create Table
1498
t1 CREATE TEMPORARY TABLE `t1` (
1624
t1 CREATE TABLE `t1` (
1499
1625
`a` int NOT NULL,
1500
1626
KEY `a` (`a`) KEY_BLOCK_SIZE=2048
1501
1627
) ENGINE=MyISAM
1503
create temporary table t1 (a varchar(2048), key `a` (a)) ENGINE=MyISAM;
1505
Warning 1071 Specified key was too long; max key length is 1332 bytes
1506
show create table t1;
1508
t1 CREATE TEMPORARY TABLE `t1` (
1509
`a` varchar(2048) DEFAULT NULL,
1513
create temporary table t1 (a varchar(2048), key `a` (a) key_block_size=1024) ENGINE=MyISAM;
1515
Warning 1071 Specified key was too long; max key length is 1332 bytes
1516
show create table t1;
1518
t1 CREATE TEMPORARY TABLE `t1` (
1519
`a` varchar(2048) DEFAULT NULL,
1520
KEY `a` (`a`(333)) KEY_BLOCK_SIZE=6144
1523
create temporary table t1 (a int not null, b varchar(2048), key (a), key(b)) ENGINE=MyISAM key_block_size=1024;
1525
Warning 1071 Specified key was too long; max key length is 1332 bytes
1526
show create table t1;
1528
t1 CREATE TEMPORARY TABLE `t1` (
1629
create table t1 (a varchar(2048), key `a` (a)) ENGINE=MyISAM;
1631
Warning 1071 Specified key was too long; max key length is 1332 bytes
1632
show create table t1;
1634
t1 CREATE TABLE `t1` (
1635
`a` varchar(2048) DEFAULT NULL,
1639
create table t1 (a varchar(2048), key `a` (a) key_block_size=1024) ENGINE=MyISAM;
1641
Warning 1071 Specified key was too long; max key length is 1332 bytes
1642
show create table t1;
1644
t1 CREATE TABLE `t1` (
1645
`a` varchar(2048) DEFAULT NULL,
1646
KEY `a` (`a`()) KEY_BLOCK_SIZE=6144
1649
create table t1 (a int not null, b varchar(2048), key (a), key(b)) ENGINE=MyISAM key_block_size=1024;
1651
Warning 1071 Specified key was too long; max key length is 1332 bytes
1652
show create table t1;
1654
t1 CREATE TABLE `t1` (
1529
1655
`a` int NOT NULL,
1530
1656
`b` varchar(2048) DEFAULT NULL,
1532
KEY `b` (`b`(333)) KEY_BLOCK_SIZE=6144
1658
KEY `b` (`b`()) KEY_BLOCK_SIZE=6144
1533
1659
) ENGINE=MyISAM KEY_BLOCK_SIZE=1024
1534
1660
alter table t1 key_block_size=2048;
1535
1661
show create table t1;
1536
1662
Table Create Table
1537
t1 CREATE TEMPORARY TABLE `t1` (
1663
t1 CREATE TABLE `t1` (
1538
1664
`a` int NOT NULL,
1539
1665
`b` varchar(2048) DEFAULT NULL,
1540
1666
KEY `a` (`a`) KEY_BLOCK_SIZE=1024,
1541
KEY `b` (`b`(333)) KEY_BLOCK_SIZE=8192
1667
KEY `b` (`b`()) KEY_BLOCK_SIZE=8192
1542
1668
) ENGINE=MyISAM KEY_BLOCK_SIZE=2048
1543
1669
alter table t1 add c int, add key (c);
1544
1670
show create table t1;
1545
1671
Table Create Table
1546
t1 CREATE TEMPORARY TABLE `t1` (
1672
t1 CREATE TABLE `t1` (
1547
1673
`a` int NOT NULL,
1548
1674
`b` varchar(2048) DEFAULT NULL,
1549
1675
`c` int DEFAULT NULL,
1550
1676
KEY `a` (`a`) KEY_BLOCK_SIZE=1024,
1551
KEY `b` (`b`(333)) KEY_BLOCK_SIZE=8192,
1677
KEY `b` (`b`()) KEY_BLOCK_SIZE=8192,
1553
1679
) ENGINE=MyISAM KEY_BLOCK_SIZE=2048
1554
1680
alter table t1 key_block_size=0;
1555
1681
alter table t1 add d int, add key (d);
1556
1682
show create table t1;
1557
1683
Table Create Table
1558
t1 CREATE TEMPORARY TABLE `t1` (
1684
t1 CREATE TABLE `t1` (
1559
1685
`a` int NOT NULL,
1560
1686
`b` varchar(2048) DEFAULT NULL,
1561
1687
`c` int DEFAULT NULL,
1562
1688
`d` int DEFAULT NULL,
1563
1689
KEY `a` (`a`) KEY_BLOCK_SIZE=1024,
1564
KEY `b` (`b`(333)) KEY_BLOCK_SIZE=8192,
1690
KEY `b` (`b`()) KEY_BLOCK_SIZE=8192,
1565
1691
KEY `c` (`c`) KEY_BLOCK_SIZE=2048,
1567
1693
) ENGINE=MyISAM
1569
create temporary table t1 (a int not null, b varchar(2048), key (a), key(b)) ENGINE=MyISAM key_block_size=8192;
1695
create table t1 (a int not null, b varchar(2048), key (a), key(b)) ENGINE=MyISAM key_block_size=8192;
1571
1697
Warning 1071 Specified key was too long; max key length is 1332 bytes
1572
1698
show create table t1;
1573
1699
Table Create Table
1574
t1 CREATE TEMPORARY TABLE `t1` (
1700
t1 CREATE TABLE `t1` (
1575
1701
`a` int NOT NULL,
1576
1702
`b` varchar(2048) DEFAULT NULL,
1579
1705
) ENGINE=MyISAM KEY_BLOCK_SIZE=8192
1581
create temporary table t1 (a int not null, b varchar(2048), key (a) key_block_size=1024, key(b)) ENGINE=MyISAM key_block_size=8192;
1707
create table t1 (a int not null, b varchar(2048), key (a) key_block_size=1024, key(b)) ENGINE=MyISAM key_block_size=8192;
1583
1709
Warning 1071 Specified key was too long; max key length is 1332 bytes
1584
1710
show create table t1;
1585
1711
Table Create Table
1586
t1 CREATE TEMPORARY TABLE `t1` (
1712
t1 CREATE TABLE `t1` (
1587
1713
`a` int NOT NULL,
1588
1714
`b` varchar(2048) DEFAULT NULL,
1589
1715
KEY `a` (`a`) KEY_BLOCK_SIZE=1024,
1591
1717
) ENGINE=MyISAM KEY_BLOCK_SIZE=8192
1593
create temporary table t1 (a int not null, b int, key (a) key_block_size=1024, key(b) key_block_size=8192) ENGINE=MyISAM key_block_size=16384;
1719
create table t1 (a int not null, b int, key (a) key_block_size=1024, key(b) key_block_size=8192) ENGINE=MyISAM key_block_size=16384;
1594
1720
show create table t1;
1595
1721
Table Create Table
1596
t1 CREATE TEMPORARY TABLE `t1` (
1722
t1 CREATE TABLE `t1` (
1597
1723
`a` int NOT NULL,
1598
1724
`b` int DEFAULT NULL,
1599
1725
KEY `a` (`a`) KEY_BLOCK_SIZE=1024,
1600
1726
KEY `b` (`b`) KEY_BLOCK_SIZE=8192
1601
1727
) ENGINE=MyISAM KEY_BLOCK_SIZE=16384
1603
create temporary table t1 (a int not null, key `a` (a) key_block_size=512) ENGINE=MyISAM;
1729
create table t1 (a int not null, key `a` (a) key_block_size=512) ENGINE=MyISAM;
1604
1730
show create table t1;
1605
1731
Table Create Table
1606
t1 CREATE TEMPORARY TABLE `t1` (
1732
t1 CREATE TABLE `t1` (
1607
1733
`a` int NOT NULL,
1608
1734
KEY `a` (`a`) KEY_BLOCK_SIZE=1024
1609
1735
) ENGINE=MyISAM
1611
create temporary table t1 (a varchar(2048), key `a` (a) key_block_size=1000000000000000000) ENGINE=MyISAM;
1737
create table t1 (a varchar(2048), key `a` (a) key_block_size=1000000000000000000) ENGINE=MyISAM;
1613
1739
Warning 1071 Specified key was too long; max key length is 1332 bytes
1614
1740
show create table t1;
1615
1741
Table Create Table
1616
t1 CREATE TEMPORARY TABLE `t1` (
1742
t1 CREATE TABLE `t1` (
1617
1743
`a` varchar(2048) DEFAULT NULL,
1618
KEY `a` (`a`(333)) KEY_BLOCK_SIZE=6144
1744
KEY `a` (`a`()) KEY_BLOCK_SIZE=6144
1619
1745
) ENGINE=MyISAM
1621
create temporary table t1 (a int not null, key `a` (a) key_block_size=1025) ENGINE=MyISAM;
1747
create table t1 (a int not null, key `a` (a) key_block_size=1025) ENGINE=MyISAM;
1622
1748
show create table t1;
1623
1749
Table Create Table
1624
t1 CREATE TEMPORARY TABLE `t1` (
1750
t1 CREATE TABLE `t1` (
1625
1751
`a` int NOT NULL,
1626
1752
KEY `a` (`a`) KEY_BLOCK_SIZE=2048
1627
1753
) ENGINE=MyISAM
1629
create temporary table t1 (a int not null, key key_block_size=1024 (a)) ENGINE=MyISAM;
1755
create table t1 (a int not null, key key_block_size=1024 (a)) ENGINE=MyISAM;
1630
1756
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near '=1024 (a)) ENGINE=MyISAM' at line 1
1631
create temporary table t1 (a int not null, key `a` key_block_size=1024 (a)) ENGINE=MyISAM;
1757
create table t1 (a int not null, key `a` key_block_size=1024 (a)) ENGINE=MyISAM;
1632
1758
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your Drizzle server version for the right syntax to use near 'key_block_size=1024 (a)) ENGINE=MyISAM' at line 1
1633
CREATE temporary TABLE t1 (
1635
1761
c2 VARCHAR(300),
1636
1762
KEY (c1) KEY_BLOCK_SIZE 1024,