mirror of
https://github.com/MariaDB/server.git
synced 2025-01-19 13:32:33 +01:00
Merge bk-internal:/home/bk/mysql-5.1-new
into neptunus.(none):/home/msvensson/mysql/mysql-5.1
This commit is contained in:
commit
c9d14a0329
92 changed files with 1747 additions and 1779 deletions
|
@ -8,14 +8,14 @@
|
|||
DROP TABLE IF EXISTS t1, gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
--enable_warnings
|
||||
|
||||
CREATE TABLE gis_point (fid INTEGER, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER, g GEOMETRY);
|
||||
CREATE TABLE gis_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRY);
|
||||
|
||||
SHOW CREATE TABLE gis_point;
|
||||
SHOW FIELDS FROM gis_point;
|
||||
|
@ -141,6 +141,7 @@ DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gi
|
|||
# Check that ALTER TABLE doesn't loose geometry type
|
||||
#
|
||||
CREATE TABLE t1 (
|
||||
a INTEGER PRIMARY KEY AUTO_INCREMENT,
|
||||
gp point,
|
||||
ln linestring,
|
||||
pg polygon,
|
||||
|
@ -156,24 +157,24 @@ ALTER TABLE t1 ADD fid INT;
|
|||
SHOW FIELDS FROM t1;
|
||||
DROP TABLE t1;
|
||||
|
||||
create table t1 (a geometry not null);
|
||||
insert into t1 values (GeomFromText('Point(1 2)'));
|
||||
create table t1 (pk integer primary key auto_increment, a geometry not null);
|
||||
insert into t1 (a) values (GeomFromText('Point(1 2)'));
|
||||
-- error 1416
|
||||
insert into t1 values ('Garbage');
|
||||
insert into t1 (a) values ('Garbage');
|
||||
-- error 1416
|
||||
insert IGNORE into t1 values ('Garbage');
|
||||
insert IGNORE into t1 (a) values ('Garbage');
|
||||
|
||||
drop table t1;
|
||||
|
||||
create table t1 (fl geometry);
|
||||
create table t1 (pk integer primary key auto_increment, fl geometry);
|
||||
--error 1416
|
||||
insert into t1 values (1);
|
||||
insert into t1 (fl) values (1);
|
||||
--error 1416
|
||||
insert into t1 values (1.11);
|
||||
insert into t1 (fl) values (1.11);
|
||||
--error 1416
|
||||
insert into t1 values ("qwerty");
|
||||
insert into t1 (fl) values ("qwerty");
|
||||
--error 1416
|
||||
insert into t1 values (pointfromtext('point(1,1)'));
|
||||
insert into t1 (fl) values (pointfromtext('point(1,1)'));
|
||||
|
||||
drop table t1;
|
||||
|
||||
|
|
|
@ -468,25 +468,25 @@ delete from t1;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) character set koi8r default NULL
|
||||
`a` char(10) CHARACTER SET koi8r DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 DEFAULT CHARACTER SET latin1;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) character set koi8r default NULL
|
||||
`a` char(10) CHARACTER SET koi8r DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 CONVERT TO CHARACTER SET latin1;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) default NULL
|
||||
`a` char(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 DEFAULT CHARACTER SET cp1251;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) character set latin1 default NULL
|
||||
`a` char(10) CHARACTER SET latin1 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=cp1251
|
||||
drop table t1;
|
||||
create table t1 (myblob longblob,mytext longtext)
|
||||
|
@ -495,14 +495,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`myblob` longblob,
|
||||
`mytext` longtext collate latin1_general_cs
|
||||
`mytext` longtext COLLATE latin1_general_cs
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_cs
|
||||
alter table t1 character set latin2;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`myblob` longblob,
|
||||
`mytext` longtext character set latin1 collate latin1_general_cs
|
||||
`mytext` longtext CHARACTER SET latin1 COLLATE latin1_general_cs
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin2
|
||||
drop table t1;
|
||||
CREATE TABLE t1 (a int PRIMARY KEY, b INT UNIQUE);
|
||||
|
@ -511,7 +511,7 @@ SHOW CREATE TABLE t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` int(11) default NULL,
|
||||
`b` int(11) DEFAULT NULL,
|
||||
UNIQUE KEY `b` (`b`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
ALTER TABLE t1 DROP PRIMARY KEY;
|
||||
|
|
|
@ -36,16 +36,16 @@ create table t2 select * from t1 where 0=1 procedure analyse();
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`Field_name` varbinary(255) NOT NULL default '',
|
||||
`Min_value` varbinary(255) default NULL,
|
||||
`Max_value` varbinary(255) default NULL,
|
||||
`Min_length` bigint(11) NOT NULL default '0',
|
||||
`Max_length` bigint(11) NOT NULL default '0',
|
||||
`Empties_or_zeros` bigint(11) NOT NULL default '0',
|
||||
`Nulls` bigint(11) NOT NULL default '0',
|
||||
`Avg_value_or_avg_length` varbinary(255) NOT NULL default '',
|
||||
`Std` varbinary(255) default NULL,
|
||||
`Optimal_fieldtype` varbinary(64) NOT NULL default ''
|
||||
`Field_name` varbinary(255) NOT NULL DEFAULT '',
|
||||
`Min_value` varbinary(255) DEFAULT NULL,
|
||||
`Max_value` varbinary(255) DEFAULT NULL,
|
||||
`Min_length` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Max_length` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Empties_or_zeros` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Nulls` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Avg_value_or_avg_length` varbinary(255) NOT NULL DEFAULT '',
|
||||
`Std` varbinary(255) DEFAULT NULL,
|
||||
`Optimal_fieldtype` varbinary(64) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t1 where 0=1 procedure analyse();
|
||||
Field_name Min_value Max_value Min_length Max_length Empties_or_zeros Nulls Avg_value_or_avg_length Std Optimal_fieldtype
|
||||
|
@ -55,16 +55,16 @@ create table t2 select * from t1 where 0=1 procedure analyse();
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`Field_name` varbinary(255) NOT NULL default '',
|
||||
`Min_value` varbinary(255) default NULL,
|
||||
`Max_value` varbinary(255) default NULL,
|
||||
`Min_length` bigint(11) NOT NULL default '0',
|
||||
`Max_length` bigint(11) NOT NULL default '0',
|
||||
`Empties_or_zeros` bigint(11) NOT NULL default '0',
|
||||
`Nulls` bigint(11) NOT NULL default '0',
|
||||
`Avg_value_or_avg_length` varbinary(255) NOT NULL default '',
|
||||
`Std` varbinary(255) default NULL,
|
||||
`Optimal_fieldtype` varbinary(64) NOT NULL default ''
|
||||
`Field_name` varbinary(255) NOT NULL DEFAULT '',
|
||||
`Min_value` varbinary(255) DEFAULT NULL,
|
||||
`Max_value` varbinary(255) DEFAULT NULL,
|
||||
`Min_length` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Max_length` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Empties_or_zeros` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Nulls` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Avg_value_or_avg_length` varbinary(255) NOT NULL DEFAULT '',
|
||||
`Std` varbinary(255) DEFAULT NULL,
|
||||
`Optimal_fieldtype` varbinary(64) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t2;
|
||||
Field_name Min_value Max_value Min_length Max_length Empties_or_zeros Nulls Avg_value_or_avg_length Std Optimal_fieldtype
|
||||
|
@ -78,16 +78,16 @@ create table t2 select * from t1 where 0=1 procedure analyse();
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`Field_name` varbinary(255) NOT NULL default '',
|
||||
`Min_value` varbinary(255) default NULL,
|
||||
`Max_value` varbinary(255) default NULL,
|
||||
`Min_length` bigint(11) NOT NULL default '0',
|
||||
`Max_length` bigint(11) NOT NULL default '0',
|
||||
`Empties_or_zeros` bigint(11) NOT NULL default '0',
|
||||
`Nulls` bigint(11) NOT NULL default '0',
|
||||
`Avg_value_or_avg_length` varbinary(255) NOT NULL default '',
|
||||
`Std` varbinary(255) default NULL,
|
||||
`Optimal_fieldtype` varbinary(64) NOT NULL default ''
|
||||
`Field_name` varbinary(255) NOT NULL DEFAULT '',
|
||||
`Min_value` varbinary(255) DEFAULT NULL,
|
||||
`Max_value` varbinary(255) DEFAULT NULL,
|
||||
`Min_length` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Max_length` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Empties_or_zeros` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Nulls` bigint(11) NOT NULL DEFAULT '0',
|
||||
`Avg_value_or_avg_length` varbinary(255) NOT NULL DEFAULT '',
|
||||
`Std` varbinary(255) DEFAULT NULL,
|
||||
`Optimal_fieldtype` varbinary(64) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t2;
|
||||
Field_name Min_value Max_value Min_length Max_length Empties_or_zeros Nulls Avg_value_or_avg_length Std Optimal_fieldtype
|
||||
|
|
|
@ -12340,12 +12340,12 @@ ALTER TABLE t2 DROP COLUMN fld6;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`auto` int(11) default NULL,
|
||||
`fld1` int(6) unsigned zerofill NOT NULL default '000000',
|
||||
`companynr` tinyint(2) unsigned zerofill NOT NULL default '00',
|
||||
`fld3` char(30) NOT NULL default '',
|
||||
`fld4` char(35) NOT NULL default '',
|
||||
`fld5` char(35) NOT NULL default ''
|
||||
`auto` int(11) DEFAULT NULL,
|
||||
`fld1` int(6) unsigned zerofill NOT NULL DEFAULT '000000',
|
||||
`companynr` tinyint(2) unsigned zerofill NOT NULL DEFAULT '00',
|
||||
`fld3` char(30) NOT NULL DEFAULT '',
|
||||
`fld4` char(35) NOT NULL DEFAULT '',
|
||||
`fld5` char(35) NOT NULL DEFAULT ''
|
||||
) ENGINE=ARCHIVE DEFAULT CHARSET=latin1
|
||||
SELECT * FROM t2;
|
||||
auto fld1 companynr fld3 fld4 fld5
|
||||
|
|
|
@ -6,8 +6,8 @@ b bit(64)
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`pk1` int(11) NOT NULL auto_increment,
|
||||
`b` bit(64) default NULL,
|
||||
`pk1` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`b` bit(64) DEFAULT NULL,
|
||||
PRIMARY KEY (`pk1`)
|
||||
) ENGINE=ARCHIVE DEFAULT CHARSET=latin1
|
||||
insert into t1 values
|
||||
|
|
|
@ -1,50 +1,51 @@
|
|||
SET storage_engine=archive;
|
||||
DROP TABLE IF EXISTS t1, gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE gis_point (fid INTEGER, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER, g GEOMETRY);
|
||||
CREATE TABLE gis_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRY);
|
||||
SHOW CREATE TABLE gis_point;
|
||||
Table Create Table
|
||||
gis_point CREATE TABLE `gis_point` (
|
||||
`fid` int(11) default NULL,
|
||||
`g` point default NULL
|
||||
`fid` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`g` point DEFAULT NULL,
|
||||
PRIMARY KEY (`fid`)
|
||||
) ENGINE=ARCHIVE DEFAULT CHARSET=latin1
|
||||
SHOW FIELDS FROM gis_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g point YES NULL
|
||||
SHOW FIELDS FROM gis_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g linestring YES NULL
|
||||
SHOW FIELDS FROM gis_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g polygon YES NULL
|
||||
SHOW FIELDS FROM gis_multi_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipoint YES NULL
|
||||
SHOW FIELDS FROM gis_multi_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multilinestring YES NULL
|
||||
SHOW FIELDS FROM gis_multi_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipolygon YES NULL
|
||||
SHOW FIELDS FROM gis_geometrycollection;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometrycollection YES NULL
|
||||
SHOW FIELDS FROM gis_geometry;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometry YES NULL
|
||||
INSERT INTO gis_point VALUES
|
||||
(101, PointFromText('POINT(10 10)')),
|
||||
|
@ -407,6 +408,7 @@ Warnings:
|
|||
Note 1003 select `test`.`g1`.`fid` AS `first`,`test`.`g2`.`fid` AS `second`,within(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `w`,contains(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `c`,overlaps(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `o`,equals(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `e`,disjoint(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `d`,touches(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `t`,intersects(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `i`,crosses(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `r` from `test`.`gis_geometrycollection` `g1` join `test`.`gis_geometrycollection` `g2` order by `test`.`g1`.`fid`,`test`.`g2`.`fid`
|
||||
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE t1 (
|
||||
a INTEGER PRIMARY KEY AUTO_INCREMENT,
|
||||
gp point,
|
||||
ln linestring,
|
||||
pg polygon,
|
||||
|
@ -418,6 +420,7 @@ gm geometry
|
|||
);
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -429,6 +432,7 @@ gm geometry YES NULL
|
|||
ALTER TABLE t1 ADD fid INT;
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -439,20 +443,20 @@ gc geometrycollection YES NULL
|
|||
gm geometry YES NULL
|
||||
fid int(11) YES NULL
|
||||
DROP TABLE t1;
|
||||
create table t1 (a geometry not null);
|
||||
insert into t1 values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 values ('Garbage');
|
||||
create table t1 (pk integer primary key auto_increment, a geometry not null);
|
||||
insert into t1 (a) values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert IGNORE into t1 values ('Garbage');
|
||||
insert IGNORE into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
create table t1 (fl geometry);
|
||||
insert into t1 values (1);
|
||||
create table t1 (pk integer primary key auto_increment, fl geometry);
|
||||
insert into t1 (fl) values (1);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (1.11);
|
||||
insert into t1 (fl) values (1.11);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values ("qwerty");
|
||||
insert into t1 (fl) values ("qwerty");
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (pointfromtext('point(1,1)'));
|
||||
insert into t1 (fl) values (pointfromtext('point(1,1)'));
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
|
|
|
@ -1366,40 +1366,40 @@ concat('*',v,'*',c,'*',t,'*')
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1
|
||||
create table t2 like t1;
|
||||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1
|
||||
create table t3 select * from t1;
|
||||
show create table t3;
|
||||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1
|
||||
alter table t1 modify c varchar(10);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1
|
||||
alter table t1 modify v char(10);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`v` char(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1
|
||||
alter table t1 modify t varchar(10);
|
||||
|
@ -1408,9 +1408,9 @@ Note 1265 Data truncated for column 't' at row 2
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`t` varchar(10) default NULL
|
||||
`v` char(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` varchar(10) DEFAULT NULL
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1
|
||||
select concat('*',v,'*',c,'*',t,'*') from t1;
|
||||
concat('*',v,'*',c,'*',t,'*')
|
||||
|
@ -1421,8 +1421,8 @@ create table t1 (v varchar(10), c char(10), t text, key(v), key(c), key(t(10)));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `v` (`v`),
|
||||
KEY `c` (`c`),
|
||||
|
@ -1640,8 +1640,8 @@ alter table t1 modify v varchar(300), drop key v, drop key v_2, add key v (v);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(300) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(300) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10)),
|
||||
|
@ -1720,8 +1720,8 @@ alter table t1 drop key v, add key v (v(30));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(300) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(300) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10)),
|
||||
|
@ -1800,8 +1800,8 @@ alter table t1 modify v varchar(600), drop key v, add key v (v);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(600) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(600) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10)),
|
||||
|
@ -1878,8 +1878,8 @@ create table t1 (v varchar(10), c char(10), t text, key(v(5)), key(c(5)), key(t(
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `v` (`v`(5)),
|
||||
KEY `c` (`c`(5)),
|
||||
|
@ -1890,15 +1890,15 @@ create table t1 (v char(10) character set utf8);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) character set utf8 default NULL
|
||||
`v` char(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (v varchar(10), c char(10)) row_format=fixed;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1 ROW_FORMAT=FIXED
|
||||
insert into t1 values('a','a'),('a ','a ');
|
||||
select concat('*',v,'*',c,'*') from t1;
|
||||
|
@ -1940,7 +1940,7 @@ Note 1246 Converting column 'v' from VARCHAR to TEXT
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` mediumtext character set utf8
|
||||
`v` mediumtext CHARACTER SET utf8
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
set storage_engine=MyISAM;
|
||||
|
|
|
@ -1,50 +1,51 @@
|
|||
SET storage_engine=bdb;
|
||||
DROP TABLE IF EXISTS t1, gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE gis_point (fid INTEGER, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER, g GEOMETRY);
|
||||
CREATE TABLE gis_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRY);
|
||||
SHOW CREATE TABLE gis_point;
|
||||
Table Create Table
|
||||
gis_point CREATE TABLE `gis_point` (
|
||||
`fid` int(11) default NULL,
|
||||
`g` point default NULL
|
||||
`fid` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`g` point DEFAULT NULL,
|
||||
PRIMARY KEY (`fid`)
|
||||
) ENGINE=BerkeleyDB DEFAULT CHARSET=latin1
|
||||
SHOW FIELDS FROM gis_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g point YES NULL
|
||||
SHOW FIELDS FROM gis_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g linestring YES NULL
|
||||
SHOW FIELDS FROM gis_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g polygon YES NULL
|
||||
SHOW FIELDS FROM gis_multi_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipoint YES NULL
|
||||
SHOW FIELDS FROM gis_multi_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multilinestring YES NULL
|
||||
SHOW FIELDS FROM gis_multi_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipolygon YES NULL
|
||||
SHOW FIELDS FROM gis_geometrycollection;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometrycollection YES NULL
|
||||
SHOW FIELDS FROM gis_geometry;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometry YES NULL
|
||||
INSERT INTO gis_point VALUES
|
||||
(101, PointFromText('POINT(10 10)')),
|
||||
|
@ -407,6 +408,7 @@ Warnings:
|
|||
Note 1003 select `test`.`g1`.`fid` AS `first`,`test`.`g2`.`fid` AS `second`,within(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `w`,contains(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `c`,overlaps(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `o`,equals(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `e`,disjoint(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `d`,touches(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `t`,intersects(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `i`,crosses(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `r` from `test`.`gis_geometrycollection` `g1` join `test`.`gis_geometrycollection` `g2` order by `test`.`g1`.`fid`,`test`.`g2`.`fid`
|
||||
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE t1 (
|
||||
a INTEGER PRIMARY KEY AUTO_INCREMENT,
|
||||
gp point,
|
||||
ln linestring,
|
||||
pg polygon,
|
||||
|
@ -418,6 +420,7 @@ gm geometry
|
|||
);
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -429,6 +432,7 @@ gm geometry YES NULL
|
|||
ALTER TABLE t1 ADD fid INT;
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -439,20 +443,20 @@ gc geometrycollection YES NULL
|
|||
gm geometry YES NULL
|
||||
fid int(11) YES NULL
|
||||
DROP TABLE t1;
|
||||
create table t1 (a geometry not null);
|
||||
insert into t1 values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 values ('Garbage');
|
||||
create table t1 (pk integer primary key auto_increment, a geometry not null);
|
||||
insert into t1 (a) values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert IGNORE into t1 values ('Garbage');
|
||||
insert IGNORE into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
create table t1 (fl geometry);
|
||||
insert into t1 values (1);
|
||||
create table t1 (pk integer primary key auto_increment, fl geometry);
|
||||
insert into t1 (fl) values (1);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (1.11);
|
||||
insert into t1 (fl) values (1.11);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values ("qwerty");
|
||||
insert into t1 (fl) values ("qwerty");
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (pointfromtext('point(1,1)'));
|
||||
insert into t1 (fl) values (pointfromtext('point(1,1)'));
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
|
|
|
@ -174,14 +174,14 @@ create table t1 select 1 as 'a';
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bigint(1) NOT NULL default '0'
|
||||
`a` bigint(1) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 select 9223372036854775809 as 'a';
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bigint(19) unsigned NOT NULL default '0'
|
||||
`a` bigint(19) unsigned NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t1;
|
||||
a
|
||||
|
|
|
@ -138,7 +138,7 @@ create table t1 (a binary);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` binary(1) default NULL
|
||||
`a` binary(1) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (col1 binary(4));
|
||||
|
|
|
@ -99,18 +99,18 @@ CASE WHEN 1 THEN 0.1e1 else '1' END AS c12
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` varchar(1) character set latin1 collate latin1_danish_ci NOT NULL default '',
|
||||
`c2` varchar(1) character set latin1 collate latin1_danish_ci NOT NULL default '',
|
||||
`c3` varbinary(1) NOT NULL default '',
|
||||
`c4` varbinary(1) NOT NULL default '',
|
||||
`c5` varbinary(3) NOT NULL default '',
|
||||
`c6` varbinary(3) NOT NULL default '',
|
||||
`c7` decimal(2,1) NOT NULL default '0.0',
|
||||
`c8` decimal(2,1) NOT NULL default '0.0',
|
||||
`c9` decimal(2,1) default NULL,
|
||||
`c10` double NOT NULL default '0',
|
||||
`c11` double NOT NULL default '0',
|
||||
`c12` varbinary(5) NOT NULL default ''
|
||||
`c1` varchar(1) CHARACTER SET latin1 COLLATE latin1_danish_ci NOT NULL DEFAULT '',
|
||||
`c2` varchar(1) CHARACTER SET latin1 COLLATE latin1_danish_ci NOT NULL DEFAULT '',
|
||||
`c3` varbinary(1) NOT NULL DEFAULT '',
|
||||
`c4` varbinary(1) NOT NULL DEFAULT '',
|
||||
`c5` varbinary(3) NOT NULL DEFAULT '',
|
||||
`c6` varbinary(3) NOT NULL DEFAULT '',
|
||||
`c7` decimal(2,1) NOT NULL DEFAULT '0.0',
|
||||
`c8` decimal(2,1) NOT NULL DEFAULT '0.0',
|
||||
`c9` decimal(2,1) DEFAULT NULL,
|
||||
`c10` double NOT NULL DEFAULT '0',
|
||||
`c11` double NOT NULL DEFAULT '0',
|
||||
`c12` varbinary(5) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
SELECT CASE
|
||||
|
@ -151,13 +151,13 @@ Note 1003 select coalesce(1) AS `COALESCE(1)`,coalesce(1.0) AS `COALESCE(1.0)`,c
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`COALESCE(1)` int(1) NOT NULL default '0',
|
||||
`COALESCE(1.0)` decimal(2,1) unsigned NOT NULL default '0.0',
|
||||
`COALESCE('a')` varchar(1) NOT NULL default '',
|
||||
`COALESCE(1,1.0)` decimal(2,1) NOT NULL default '0.0',
|
||||
`COALESCE(1,'1')` varbinary(1) NOT NULL default '',
|
||||
`COALESCE(1.1,'1')` varbinary(3) NOT NULL default '',
|
||||
`COALESCE('a' COLLATE latin1_bin,'b')` varchar(1) character set latin1 collate latin1_bin NOT NULL default ''
|
||||
`COALESCE(1)` int(1) NOT NULL DEFAULT '0',
|
||||
`COALESCE(1.0)` decimal(2,1) unsigned NOT NULL DEFAULT '0.0',
|
||||
`COALESCE('a')` varchar(1) NOT NULL DEFAULT '',
|
||||
`COALESCE(1,1.0)` decimal(2,1) NOT NULL DEFAULT '0.0',
|
||||
`COALESCE(1,'1')` varbinary(1) NOT NULL DEFAULT '',
|
||||
`COALESCE(1.1,'1')` varbinary(3) NOT NULL DEFAULT '',
|
||||
`COALESCE('a' COLLATE latin1_bin,'b')` varchar(1) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
SELECT 'case+union+test'
|
||||
|
|
|
@ -157,7 +157,7 @@ create table t1 select cast(_koi8r'
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`t` varchar(4) character set cp1251 NOT NULL default ''
|
||||
`t` varchar(4) CHARACTER SET cp1251 NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
select
|
||||
|
@ -191,11 +191,11 @@ ab a ab a 6100
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` varbinary(2) NOT NULL default '',
|
||||
`c2` varbinary(2) NOT NULL default '',
|
||||
`c3` varbinary(2) NOT NULL default '',
|
||||
`c4` varbinary(2) NOT NULL default '',
|
||||
`c5` varbinary(2) NOT NULL default ''
|
||||
`c1` varbinary(2) NOT NULL DEFAULT '',
|
||||
`c2` varbinary(2) NOT NULL DEFAULT '',
|
||||
`c3` varbinary(2) NOT NULL DEFAULT '',
|
||||
`c4` varbinary(2) NOT NULL DEFAULT '',
|
||||
`c5` varbinary(2) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
select
|
||||
|
@ -224,11 +224,11 @@ c1 c2 c3 c4 c5
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` varchar(2) character set utf8 NOT NULL default '',
|
||||
`c2` varchar(2) character set utf8 NOT NULL default '',
|
||||
`c3` varchar(2) character set utf8 NOT NULL default '',
|
||||
`c4` varchar(2) character set utf8 NOT NULL default '',
|
||||
`c5` varchar(2) character set utf8 NOT NULL default ''
|
||||
`c1` varchar(2) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`c2` varchar(2) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`c3` varchar(2) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`c4` varchar(2) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`c5` varchar(2) CHARACTER SET utf8 NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (a binary(4), b char(4) character set koi8r);
|
||||
|
|
|
@ -21,7 +21,7 @@ alter table t1 add constraint constraint_2 unique key_2(a);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) default NULL,
|
||||
`a` int(11) DEFAULT NULL,
|
||||
UNIQUE KEY `constraint_1` (`a`),
|
||||
UNIQUE KEY `key_1` (`a`),
|
||||
UNIQUE KEY `key_2` (`a`)
|
||||
|
|
|
@ -44,7 +44,7 @@ create table `a/a` (a int);
|
|||
show create table `a/a`;
|
||||
Table Create Table
|
||||
a/a CREATE TABLE `a/a` (
|
||||
`a` int(11) default NULL
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
create table t1 like `a/a`;
|
||||
drop table `a/a`;
|
||||
|
@ -174,7 +174,7 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` int(11) default NULL,
|
||||
`b` int(11) DEFAULT NULL,
|
||||
PRIMARY KEY (`a`),
|
||||
KEY `b` (`b`),
|
||||
KEY `b_2` (`b`),
|
||||
|
@ -311,7 +311,7 @@ show create table t3;
|
|||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`id` int(11) NOT NULL,
|
||||
`name` char(20) default NULL
|
||||
`name` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t3;
|
||||
id name
|
||||
|
@ -334,7 +334,7 @@ show create table t3;
|
|||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`id` int(11) NOT NULL,
|
||||
`name` char(20) default NULL
|
||||
`name` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t3;
|
||||
id name
|
||||
|
@ -346,14 +346,14 @@ show create table t3;
|
|||
Table Create Table
|
||||
t3 CREATE TEMPORARY TABLE `t3` (
|
||||
`id` int(11) NOT NULL,
|
||||
`name` char(20) default NULL
|
||||
`name` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
create table t2 like t3;
|
||||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`id` int(11) NOT NULL,
|
||||
`name` char(20) default NULL
|
||||
`name` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t2;
|
||||
id name
|
||||
|
@ -447,21 +447,21 @@ create table t2 select ifnull(a,a), ifnull(b,b), ifnull(c,c), ifnull(d,d), ifnul
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`ifnull(a,a)` tinyint(4) default NULL,
|
||||
`ifnull(b,b)` smallint(6) default NULL,
|
||||
`ifnull(c,c)` mediumint(8) default NULL,
|
||||
`ifnull(d,d)` int(11) default NULL,
|
||||
`ifnull(e,e)` bigint(20) default NULL,
|
||||
`ifnull(f,f)` float(24,2) default NULL,
|
||||
`ifnull(g,g)` double(53,3) default NULL,
|
||||
`ifnull(h,h)` decimal(5,4) default NULL,
|
||||
`ifnull(i,i)` year(4) default NULL,
|
||||
`ifnull(j,j)` date default NULL,
|
||||
`ifnull(k,k)` datetime NOT NULL default '0000-00-00 00:00:00',
|
||||
`ifnull(l,l)` datetime default NULL,
|
||||
`ifnull(m,m)` varchar(1) default NULL,
|
||||
`ifnull(n,n)` varchar(3) default NULL,
|
||||
`ifnull(o,o)` varchar(10) default NULL
|
||||
`ifnull(a,a)` tinyint(4) DEFAULT NULL,
|
||||
`ifnull(b,b)` smallint(6) DEFAULT NULL,
|
||||
`ifnull(c,c)` mediumint(8) DEFAULT NULL,
|
||||
`ifnull(d,d)` int(11) DEFAULT NULL,
|
||||
`ifnull(e,e)` bigint(20) DEFAULT NULL,
|
||||
`ifnull(f,f)` float(24,2) DEFAULT NULL,
|
||||
`ifnull(g,g)` double(53,3) DEFAULT NULL,
|
||||
`ifnull(h,h)` decimal(5,4) DEFAULT NULL,
|
||||
`ifnull(i,i)` year(4) DEFAULT NULL,
|
||||
`ifnull(j,j)` date DEFAULT NULL,
|
||||
`ifnull(k,k)` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
|
||||
`ifnull(l,l)` datetime DEFAULT NULL,
|
||||
`ifnull(m,m)` varchar(1) DEFAULT NULL,
|
||||
`ifnull(n,n)` varchar(3) DEFAULT NULL,
|
||||
`ifnull(o,o)` varchar(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1,t2;
|
||||
create table t1(str varchar(10) default 'def',strnull varchar(10),intg int default '10',rel double default '3.14');
|
||||
|
@ -526,14 +526,14 @@ create table t1 (`primary` int, index(`primary`));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`primary` int(11) default NULL,
|
||||
`primary` int(11) DEFAULT NULL,
|
||||
KEY `primary_2` (`primary`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
create table t2 (`PRIMARY` int, index(`PRIMARY`));
|
||||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`PRIMARY` int(11) default NULL,
|
||||
`PRIMARY` int(11) DEFAULT NULL,
|
||||
KEY `PRIMARY_2` (`PRIMARY`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
create table t3 (a int);
|
||||
|
@ -546,7 +546,7 @@ alter table t4 add index(`primary`);
|
|||
show create table t4;
|
||||
Table Create Table
|
||||
t4 CREATE TABLE `t4` (
|
||||
`primary` int(11) default NULL,
|
||||
`primary` int(11) DEFAULT NULL,
|
||||
KEY `primary_2` (`primary`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
create table t5 (`PRIMARY` int);
|
||||
|
@ -554,7 +554,7 @@ alter table t5 add index(`PRIMARY`);
|
|||
show create table t5;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`PRIMARY` int(11) default NULL,
|
||||
`PRIMARY` int(11) DEFAULT NULL,
|
||||
KEY `PRIMARY_2` (`PRIMARY`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1, t2, t3, t4, t5;
|
||||
|
@ -642,7 +642,7 @@ primary key (a)
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(112) character set utf8 collate utf8_bin NOT NULL,
|
||||
`a` varchar(112) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
|
||||
PRIMARY KEY (`a`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
@ -657,7 +657,7 @@ b int not null, primary key (a)
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(12) character set utf8 collate utf8_bin NOT NULL,
|
||||
`a` varchar(12) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
|
||||
`b` int(11) NOT NULL,
|
||||
PRIMARY KEY (`a`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
@ -672,8 +672,8 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`b` int(11) NOT NULL,
|
||||
`a` varchar(12) character set utf8 collate utf8_bin NOT NULL,
|
||||
`c` bigint(1) NOT NULL default '0',
|
||||
`a` varchar(12) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
|
||||
`c` bigint(1) NOT NULL DEFAULT '0',
|
||||
PRIMARY KEY (`a`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
@ -684,9 +684,9 @@ b int null, primary key (a)
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`b` int(11) default NULL,
|
||||
`a` varchar(12) character set utf8 collate utf8_bin NOT NULL,
|
||||
`c` bigint(1) NOT NULL default '0',
|
||||
`b` int(11) DEFAULT NULL,
|
||||
`a` varchar(12) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
|
||||
`c` bigint(1) NOT NULL DEFAULT '0',
|
||||
PRIMARY KEY (`a`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
@ -697,7 +697,7 @@ b int not null, primary key (a)
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(12) character set utf8 collate utf8_bin NOT NULL,
|
||||
`a` varchar(12) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL,
|
||||
`b` int(11) NOT NULL,
|
||||
PRIMARY KEY (`a`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
@ -709,7 +709,7 @@ b int not null, primary key (a)
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(12) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`a` varchar(12) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`b` int(11) NOT NULL,
|
||||
PRIMARY KEY (`a`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
@ -745,29 +745,29 @@ select a1,a2 from t1;
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`a` int(11) default '3',
|
||||
`b` int(11) default '3',
|
||||
`a1` int(11) default NULL,
|
||||
`a2` int(11) default NULL
|
||||
`a` int(11) DEFAULT '3',
|
||||
`b` int(11) DEFAULT '3',
|
||||
`a1` int(11) DEFAULT NULL,
|
||||
`a2` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1, t2;
|
||||
create table t1 (i int) engine=myisam max_rows=100000000000;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL
|
||||
`i` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 MAX_ROWS=4294967295
|
||||
alter table t1 max_rows=100;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL
|
||||
`i` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 MAX_ROWS=100
|
||||
alter table t1 max_rows=100000000000;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL
|
||||
`i` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 MAX_ROWS=4294967295
|
||||
drop table t1;
|
||||
create table t1(f1 varchar(800) binary not null, key(f1)) engine = innodb
|
||||
|
|
|
@ -494,7 +494,7 @@ latin1_f CHAR(32) CHARACTER SET latin1 COLLATE latin1_bin;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`latin1_f` char(32) character set latin1 collate latin1_bin default NULL
|
||||
`latin1_f` char(32) CHARACTER SET latin1 COLLATE latin1_bin DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -503,7 +503,7 @@ ALTER TABLE t1 CHARACTER SET latin1 COLLATE latin1_bin;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`latin1_f` char(32) collate latin1_bin default NULL
|
||||
`latin1_f` char(32) COLLATE latin1_bin DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
|
|
@ -12,7 +12,7 @@ CREATE TABLE mysqltest2.t1 (a char(10));
|
|||
SHOW CREATE TABLE mysqltest2.t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) default NULL
|
||||
`a` char(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin5
|
||||
DROP TABLE mysqltest2.t1;
|
||||
ALTER DATABASE mysqltest2 DEFAULT CHARACTER SET latin7;
|
||||
|
@ -20,7 +20,7 @@ CREATE TABLE mysqltest2.t1 (a char(10));
|
|||
SHOW CREATE TABLE mysqltest2.t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) default NULL
|
||||
`a` char(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin7
|
||||
DROP DATABASE mysqltest2;
|
||||
CREATE DATABASE mysqltest2 CHARACTER SET latin2;
|
||||
|
@ -28,7 +28,7 @@ CREATE TABLE mysqltest2.t1 (a char(10));
|
|||
SHOW CREATE TABLE mysqltest2.t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) default NULL
|
||||
`a` char(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin2
|
||||
DROP DATABASE mysqltest2;
|
||||
USE mysqltest1;
|
||||
|
@ -36,14 +36,14 @@ CREATE TABLE t1 (a char(10));
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) default NULL
|
||||
`a` char(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=cp1251
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (a char(10)) DEFAULT CHARACTER SET latin1;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) default NULL
|
||||
`a` char(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (a char(10))
|
||||
|
@ -51,7 +51,7 @@ DEFAULT CHARACTER SET latin1 COLLATE latin1_german1_ci;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) collate latin1_german1_ci default NULL
|
||||
`a` char(10) COLLATE latin1_german1_ci DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_german1_ci
|
||||
DROP TABLE t1;
|
||||
create table t1 (a char) character set latin1 character set latin2;
|
||||
|
|
|
@ -224,8 +224,8 @@ create table t1 (word varchar(255) not null, word2 varchar(255) not null default
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`word` varchar(255) collate latin1_german2_ci NOT NULL,
|
||||
`word2` varchar(255) collate latin1_german2_ci NOT NULL default '',
|
||||
`word` varchar(255) COLLATE latin1_german2_ci NOT NULL,
|
||||
`word2` varchar(255) COLLATE latin1_german2_ci NOT NULL DEFAULT '',
|
||||
KEY `word` (`word`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_german2_ci
|
||||
insert into t1 (word) values ('ss'),(0xDF),(0xE4),('ae');
|
||||
|
@ -299,7 +299,7 @@ s1 CHAR(5) CHARACTER SET latin1 COLLATE latin1_german2_ci
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`s1` char(5) collate latin1_german2_ci default NULL
|
||||
`s1` char(5) COLLATE latin1_german2_ci DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_german2_ci
|
||||
INSERT INTO t1 VALUES ('Ü');
|
||||
INSERT INTO t1 VALUES ('ue');
|
||||
|
|
|
@ -7,22 +7,22 @@ koi8_ru_f CHAR(32) CHARACTER SET koi8r NOT NULL default ''
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`comment` char(32) character set latin1 NOT NULL,
|
||||
`koi8_ru_f` char(32) character set koi8r NOT NULL default ''
|
||||
`comment` char(32) CHARACTER SET latin1 NOT NULL,
|
||||
`koi8_ru_f` char(32) CHARACTER SET koi8r NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin5
|
||||
ALTER TABLE t1 CHANGE comment comment CHAR(32) CHARACTER SET latin2 NOT NULL;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`comment` char(32) character set latin2 NOT NULL,
|
||||
`koi8_ru_f` char(32) character set koi8r NOT NULL default ''
|
||||
`comment` char(32) CHARACTER SET latin2 NOT NULL,
|
||||
`koi8_ru_f` char(32) CHARACTER SET koi8r NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin5
|
||||
ALTER TABLE t1 ADD latin5_f CHAR(32) NOT NULL;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`comment` char(32) character set latin2 NOT NULL,
|
||||
`koi8_ru_f` char(32) character set koi8r NOT NULL default '',
|
||||
`comment` char(32) CHARACTER SET latin2 NOT NULL,
|
||||
`koi8_ru_f` char(32) CHARACTER SET koi8r NOT NULL DEFAULT '',
|
||||
`latin5_f` char(32) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin5
|
||||
ALTER TABLE t1 DEFAULT CHARSET=latin2;
|
||||
|
@ -31,8 +31,8 @@ SHOW CREATE TABLE t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`comment` char(32) NOT NULL,
|
||||
`koi8_ru_f` char(32) character set koi8r NOT NULL default '',
|
||||
`latin5_f` char(32) character set latin5 NOT NULL,
|
||||
`koi8_ru_f` char(32) CHARACTER SET koi8r NOT NULL DEFAULT '',
|
||||
`latin5_f` char(32) CHARACTER SET latin5 NOT NULL,
|
||||
`latin2_f` char(32) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin2
|
||||
ALTER TABLE t1 DROP latin2_f, DROP latin5_f;
|
||||
|
@ -40,7 +40,7 @@ SHOW CREATE TABLE t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`comment` char(32) NOT NULL,
|
||||
`koi8_ru_f` char(32) character set koi8r NOT NULL default ''
|
||||
`koi8_ru_f` char(32) CHARACTER SET koi8r NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin2
|
||||
INSERT INTO t1 (koi8_ru_f,comment) VALUES ('a','LAT SMALL A');
|
||||
INSERT INTO t1 (koi8_ru_f,comment) VALUES ('b','LAT SMALL B');
|
||||
|
|
|
@ -3,17 +3,17 @@ CREATE TABLE t1 SELECT _utf8'test' as c1, _utf8'тест' as c2;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` varchar(4) character set utf8 NOT NULL default '',
|
||||
`c2` varchar(4) character set utf8 NOT NULL default ''
|
||||
`c1` varchar(4) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`c2` varchar(4) CHARACTER SET utf8 NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DELETE FROM t1;
|
||||
ALTER TABLE t1 ADD c3 CHAR(4) CHARACTER SET utf8;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` varchar(4) character set utf8 NOT NULL default '',
|
||||
`c2` varchar(4) character set utf8 NOT NULL default '',
|
||||
`c3` char(4) character set utf8 default NULL
|
||||
`c1` varchar(4) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`c2` varchar(4) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`c3` char(4) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES ('aaaabbbbccccdddd','aaaabbbbccccdddd','aaaabbbbccccdddd');
|
||||
Warnings:
|
||||
|
@ -28,7 +28,7 @@ CREATE TABLE t1 (a CHAR(4) CHARACTER SET utf8, KEY key_a(a(3)));
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(4) character set utf8 default NULL,
|
||||
`a` char(4) CHARACTER SET utf8 DEFAULT NULL,
|
||||
KEY `key_a` (`a`(3))
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SHOW KEYS FROM t1;
|
||||
|
@ -38,7 +38,7 @@ ALTER TABLE t1 CHANGE a a CHAR(4);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(4) default NULL,
|
||||
`a` char(4) DEFAULT NULL,
|
||||
KEY `key_a` (`a`(3))
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SHOW KEYS FROM t1;
|
||||
|
@ -48,7 +48,7 @@ ALTER TABLE t1 CHANGE a a CHAR(4) CHARACTER SET utf8;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(4) character set utf8 default NULL,
|
||||
`a` char(4) CHARACTER SET utf8 DEFAULT NULL,
|
||||
KEY `key_a` (`a`(3))
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SHOW KEYS FROM t1;
|
||||
|
|
|
@ -6,7 +6,7 @@ CREATE TABLE t2 (a CHAR(10) CHARACTER SET utf8);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) character set cp1251 default NULL
|
||||
`a` char(10) CHARACTER SET cp1251 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SELECT a FROM t1;
|
||||
a
|
||||
|
@ -30,7 +30,7 @@ CREATE TABLE t2 (a TEXT CHARACTER SET utf8);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` text character set cp1251
|
||||
`a` text CHARACTER SET cp1251
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SELECT HEX(a) FROM t1;
|
||||
HEX(a)
|
||||
|
@ -50,7 +50,7 @@ Tables_in_test
|
|||
SHOW CREATE TABLE ÔÁÂĚÉĂÁ;
|
||||
Table Create Table
|
||||
ÔÁÂĚÉĂÁ CREATE TABLE `ÔÁÂĚÉĂÁ` (
|
||||
`ÐÏÌÅ` char(32) character set koi8r NOT NULL COMMENT 'ËÏÍÍÅÎÔÁÒÉÊ ÐÏÌÑ'
|
||||
`ÐÏÌÅ` char(32) CHARACTER SET koi8r NOT NULL COMMENT 'ËÏÍÍÅÎÔÁÒÉÊ ÐÏÌÑ'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='ËĎÍÍĹÎÔÁŇÉĘ ÔÁÂĚÉĂŮ'
|
||||
SHOW FIELDS FROM ÔÁÂĚÉĂÁ;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -62,7 +62,7 @@ Tables_in_test
|
|||
SHOW CREATE TABLE ňŕáëčöŕ;
|
||||
Table Create Table
|
||||
ňŕáëčöŕ CREATE TABLE `ňŕáëčöŕ` (
|
||||
`ïîëå` char(32) character set koi8r NOT NULL COMMENT 'êîììåíòàðèé ïîëÿ'
|
||||
`ïîëå` char(32) CHARACTER SET koi8r NOT NULL COMMENT 'êîììåíòàðèé ïîëÿ'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='ęîěěĺíňŕđčé ňŕáëčöű'
|
||||
SHOW FIELDS FROM ňŕáëčöŕ;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -74,7 +74,7 @@ Tables_in_test
|
|||
SHOW CREATE TABLE таблица;
|
||||
Table Create Table
|
||||
таблица CREATE TABLE `таблица` (
|
||||
`поле` char(32) character set koi8r NOT NULL COMMENT 'комментарий полÑ<C2BB>'
|
||||
`поле` char(32) CHARACTER SET koi8r NOT NULL COMMENT 'комментарий полÑ<C2BB>'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='комментарий таблицы'
|
||||
SHOW FIELDS FROM таблица;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -117,13 +117,13 @@ CREATE TABLE `тест` (`тест` int);
|
|||
SHOW CREATE TABLE `теŃ<C2B5>Ń‚`;
|
||||
Table Create Table
|
||||
теŃ<EFBFBD>Ń‚ CREATE TABLE `теŃ<C2B5>Ń‚` (
|
||||
`теÑ<C2B5>Ñ‚` int(11) default NULL
|
||||
`теÑ<C2B5>Ñ‚` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SET NAMES utf8;
|
||||
SHOW CREATE TABLE `теŃ<C2B5>Ń‚`;
|
||||
Table Create Table
|
||||
теŃ<EFBFBD>Ń‚ CREATE TABLE `теŃ<C2B5>Ń‚` (
|
||||
`теÑ<C2B5>Ñ‚` int(11) default NULL
|
||||
`теÑ<C2B5>Ñ‚` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE `теŃ<C2B5>Ń‚`;
|
||||
SET NAMES binary;
|
||||
|
@ -141,8 +141,8 @@ CREATE TABLE t1 (`
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`ä` char(128) default 'ä',
|
||||
`ä1` enum('ä1','ä2') default 'ä2'
|
||||
`ä` char(128) DEFAULT 'ä',
|
||||
`ä1` enum('ä1','ä2') DEFAULT 'ä2'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SHOW COLUMNS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -152,8 +152,8 @@ SET NAMES binary;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`ä` char(128) default 'ä',
|
||||
`ä1` enum('ä1','ä2') default 'ä2'
|
||||
`ä` char(128) DEFAULT 'ä',
|
||||
`ä1` enum('ä1','ä2') DEFAULT 'ä2'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SHOW COLUMNS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
|
|
@ -51,7 +51,7 @@ create table t1(c enum(0x9353,0x9373) character set sjis);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` enum('“S','“s') character set sjis default NULL
|
||||
`c` enum('“S','“s') CHARACTER SET sjis DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values (0x9353);
|
||||
insert into t1 values (0x9373);
|
||||
|
|
|
@ -120,7 +120,7 @@ PRIMARY KEY (recid)
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`recid` int(11) NOT NULL auto_increment,
|
||||
`recid` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`dyninfo` text,
|
||||
PRIMARY KEY (`recid`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=tis620
|
||||
|
|
|
@ -74,8 +74,8 @@ RPAD(_ucs2 X'0420',10,_ucs2 X'0421') r;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`l` varchar(10) character set ucs2 NOT NULL default '',
|
||||
`r` varchar(10) character set ucs2 NOT NULL default ''
|
||||
`l` varchar(10) CHARACTER SET ucs2 NOT NULL DEFAULT '',
|
||||
`r` varchar(10) CHARACTER SET ucs2 NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
create table t2(f1 Char(30));
|
||||
|
@ -523,7 +523,7 @@ create table t1 (a enum('x','y','z') character set ucs2);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` enum('x','y','z') character set ucs2 default NULL
|
||||
`a` enum('x','y','z') CHARACTER SET ucs2 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('x');
|
||||
insert into t1 values ('y');
|
||||
|
@ -537,7 +537,7 @@ alter table t1 change a a enum('x','y','z','d','e','
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` enum('x','y','z','d','e','ä','ö','ü') character set ucs2 default NULL
|
||||
`a` enum('x','y','z','d','e','ä','ö','ü') CHARACTER SET ucs2 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('D');
|
||||
insert into t1 values ('E ');
|
||||
|
@ -559,7 +559,7 @@ create table t1 (a set ('x','y','z','
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` set('x','y','z','ä','ö','ü') character set ucs2 default NULL
|
||||
`a` set('x','y','z','ä','ö','ü') CHARACTER SET ucs2 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('x');
|
||||
insert into t1 values ('y');
|
||||
|
|
|
@ -118,8 +118,8 @@ b enum('
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(1) NOT NULL default '',
|
||||
`b` enum('あ','い') default NULL
|
||||
`a` char(1) NOT NULL DEFAULT '',
|
||||
`b` enum('あ','い') DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=ujis
|
||||
SHOW COLUMNS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
|
|
@ -124,7 +124,7 @@ create table t1 select date_format("2004-01-19 10:10:10", "%Y-%m-%d");
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`date_format("2004-01-19 10:10:10", "%Y-%m-%d")` varbinary(10) default NULL
|
||||
`date_format("2004-01-19 10:10:10", "%Y-%m-%d")` varbinary(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t1;
|
||||
date_format("2004-01-19 10:10:10", "%Y-%m-%d")
|
||||
|
@ -275,7 +275,7 @@ create table t1 (a enum('aaaa','проба') character set utf8);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` enum('aaaa','проба') character set utf8 default NULL
|
||||
`a` enum('aaaa','проба') CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('проба');
|
||||
select * from t1;
|
||||
|
@ -285,7 +285,7 @@ create table t2 select ifnull(a,a) from t1;
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`ifnull(a,a)` varchar(5) character set utf8 default NULL
|
||||
`ifnull(a,a)` varchar(5) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t2;
|
||||
ifnull(a,a)
|
||||
|
@ -411,7 +411,7 @@ unique key a using hash (c(1))
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` char(10) character set utf8 default NULL,
|
||||
`c` char(10) CHARACTER SET utf8 DEFAULT NULL,
|
||||
UNIQUE KEY `a` USING HASH (`c`(1))
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('a'),('b'),('c'),('d'),('e'),('f');
|
||||
|
@ -447,7 +447,7 @@ unique key a using btree (c(1))
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` char(10) character set utf8 default NULL,
|
||||
`c` char(10) CHARACTER SET utf8 DEFAULT NULL,
|
||||
UNIQUE KEY `a` USING BTREE (`c`(1))
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('a'),('b'),('c'),('d'),('e'),('f');
|
||||
|
@ -569,7 +569,7 @@ unique key a using hash (c(1))
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` char(10) character set utf8 collate utf8_bin default NULL,
|
||||
`c` char(10) CHARACTER SET utf8 COLLATE utf8_bin DEFAULT NULL,
|
||||
UNIQUE KEY `a` USING HASH (`c`(1))
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('a'),('b'),('c'),('d'),('e'),('f');
|
||||
|
@ -605,7 +605,7 @@ unique key a using btree (c(1))
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` char(10) character set utf8 collate utf8_bin default NULL,
|
||||
`c` char(10) CHARACTER SET utf8 COLLATE utf8_bin DEFAULT NULL,
|
||||
UNIQUE KEY `a` USING BTREE (`c`(1))
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('a'),('b'),('c'),('d'),('e'),('f');
|
||||
|
@ -809,8 +809,8 @@ create table t2 select concat(a,_utf8'') as a, concat(b,_utf8'')as b from t1;
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`a` varchar(5) character set utf8 NOT NULL default '',
|
||||
`b` varchar(15) character set utf8 NOT NULL default ''
|
||||
`a` varchar(5) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`b` varchar(15) CHARACTER SET utf8 NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t2;
|
||||
drop table t1;
|
||||
|
|
|
@ -67,9 +67,9 @@ ENGINE=MyISAM DEFAULT CHARACTER SET = latin1 COLLATE latin1_bin;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`a` varchar(30) collate latin1_bin NOT NULL default ' ',
|
||||
`b` varchar(1) collate latin1_bin NOT NULL default ' ',
|
||||
`c` varchar(4) collate latin1_bin NOT NULL default '0000',
|
||||
`a` varchar(30) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`b` varchar(1) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`c` varchar(4) COLLATE latin1_bin NOT NULL DEFAULT '0000',
|
||||
`d` tinyblob,
|
||||
`e` tinyblob,
|
||||
`f` tinyblob,
|
||||
|
@ -83,17 +83,17 @@ t2 CREATE TABLE `t2` (
|
|||
`n` tinyblob,
|
||||
`o` tinyblob,
|
||||
`p` tinyblob,
|
||||
`q` varchar(30) collate latin1_bin NOT NULL default ' ',
|
||||
`r` varchar(30) collate latin1_bin NOT NULL default ' ',
|
||||
`q` varchar(30) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`r` varchar(30) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`s` tinyblob,
|
||||
`t` varchar(4) collate latin1_bin NOT NULL default ' ',
|
||||
`u` varchar(1) collate latin1_bin NOT NULL default ' ',
|
||||
`v` varchar(30) collate latin1_bin NOT NULL default ' ',
|
||||
`w` varchar(30) collate latin1_bin NOT NULL default ' ',
|
||||
`t` varchar(4) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`u` varchar(1) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`v` varchar(30) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`w` varchar(30) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`x` tinyblob,
|
||||
`y` varchar(5) collate latin1_bin NOT NULL default ' ',
|
||||
`z` varchar(20) collate latin1_bin NOT NULL default ' ',
|
||||
`a1` varchar(30) collate latin1_bin NOT NULL default ' ',
|
||||
`y` varchar(5) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`z` varchar(20) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`a1` varchar(30) COLLATE latin1_bin NOT NULL DEFAULT ' ',
|
||||
`b1` tinyblob
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_bin
|
||||
INSERT into t2 (b) values ('1');
|
||||
|
|
|
@ -236,22 +236,22 @@ ALTER TABLE mysql.event MODIFY db char(20) character set utf8 collate utf8_bin d
|
|||
SHOW CREATE TABLE mysql.event;
|
||||
Table Create Table
|
||||
event CREATE TABLE `event` (
|
||||
`db` char(20) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`name` char(64) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`db` char(20) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`name` char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`body` longblob NOT NULL,
|
||||
`definer` char(77) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`execute_at` datetime default NULL,
|
||||
`interval_value` int(11) default NULL,
|
||||
`interval_field` enum('YEAR','QUARTER','MONTH','DAY','HOUR','MINUTE','WEEK','SECOND','MICROSECOND','YEAR_MONTH','DAY_HOUR','DAY_MINUTE','DAY_SECOND','HOUR_MINUTE','HOUR_SECOND','MINUTE_SECOND','DAY_MICROSECOND','HOUR_MICROSECOND','MINUTE_MICROSECOND','SECOND_MICROSECOND') default NULL,
|
||||
`created` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`modified` timestamp NOT NULL default '0000-00-00 00:00:00',
|
||||
`last_executed` datetime default NULL,
|
||||
`starts` datetime default NULL,
|
||||
`ends` datetime default NULL,
|
||||
`status` enum('ENABLED','DISABLED') NOT NULL default 'ENABLED',
|
||||
`on_completion` enum('DROP','PRESERVE') NOT NULL default 'DROP',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE') NOT NULL default '',
|
||||
`comment` char(64) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`definer` char(77) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`execute_at` datetime DEFAULT NULL,
|
||||
`interval_value` int(11) DEFAULT NULL,
|
||||
`interval_field` enum('YEAR','QUARTER','MONTH','DAY','HOUR','MINUTE','WEEK','SECOND','MICROSECOND','YEAR_MONTH','DAY_HOUR','DAY_MINUTE','DAY_SECOND','HOUR_MINUTE','HOUR_SECOND','MINUTE_SECOND','DAY_MICROSECOND','HOUR_MICROSECOND','MINUTE_MICROSECOND','SECOND_MICROSECOND') DEFAULT NULL,
|
||||
`created` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`modified` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
|
||||
`last_executed` datetime DEFAULT NULL,
|
||||
`starts` datetime DEFAULT NULL,
|
||||
`ends` datetime DEFAULT NULL,
|
||||
`status` enum('ENABLED','DISABLED') NOT NULL DEFAULT 'ENABLED',
|
||||
`on_completion` enum('DROP','PRESERVE') NOT NULL DEFAULT 'DROP',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE') NOT NULL DEFAULT '',
|
||||
`comment` char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`definer`,`db`,`name`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='Events'
|
||||
SELECT event_name FROM INFORMATION_SCHEMA.EVENTS;
|
||||
|
|
|
@ -78,7 +78,7 @@ SHOW CREATE TABLE federated.t2;
|
|||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`id` int(20) NOT NULL,
|
||||
`name` varchar(32) NOT NULL default ''
|
||||
`name` varchar(32) NOT NULL DEFAULT ''
|
||||
) ENGINE=FEDERATED DEFAULT CHARSET=latin1 CONNECTION='mysql://root@127.0.0.1:SLAVE_PORT/federated/t1'
|
||||
INSERT INTO federated.t2 (id, name) VALUES (1, 'foo');
|
||||
INSERT INTO federated.t2 (id, name) VALUES (2, 'fee');
|
||||
|
|
|
@ -248,7 +248,7 @@ t2 1 tix 1 inhalt NULL NULL NULL NULL YES FULLTEXT
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`ticket` int(11) default NULL,
|
||||
`ticket` int(11) DEFAULT NULL,
|
||||
`inhalt` text,
|
||||
KEY `tig` (`ticket`),
|
||||
FULLTEXT KEY `tix` (`inhalt`)
|
||||
|
@ -454,7 +454,7 @@ CREATE TABLE t1 (a VARCHAR(10000), FULLTEXT(a));
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(10000) default NULL,
|
||||
`a` varchar(10000) DEFAULT NULL,
|
||||
FULLTEXT KEY `a` (`a`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
|
|
@ -458,7 +458,7 @@ create table t2 select group_concat(a) as a from t1;
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`a` varchar(400) character set cp1250 default NULL
|
||||
`a` varchar(400) CHARACTER SET cp1250 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select collation(group_concat(a,_koi8r'test')) from t1;
|
||||
collation(group_concat(a,_koi8r'test'))
|
||||
|
|
|
@ -677,21 +677,21 @@ latin2 2 latin2 2
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(1) character set latin2 default NULL
|
||||
`a` char(1) CHARACTER SET latin2 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
create table t2 select max(a),min(a) from t1;
|
||||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`max(a)` char(1) character set latin2 default NULL,
|
||||
`min(a)` char(1) character set latin2 default NULL
|
||||
`max(a)` char(1) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`min(a)` char(1) CHARACTER SET latin2 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t2;
|
||||
create table t2 select concat(a) from t1;
|
||||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`concat(a)` varchar(1) character set latin2 default NULL
|
||||
`concat(a)` varchar(1) CHARACTER SET latin2 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t2,t1;
|
||||
create table t1 (a int);
|
||||
|
@ -780,7 +780,7 @@ create table t2 select MAX(b) from t1 group by a;
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`MAX(b)` datetime default NULL
|
||||
`MAX(b)` datetime DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1, t2;
|
||||
create table t1(f1 datetime);
|
||||
|
|
|
@ -156,7 +156,7 @@ create table t1 select round(1, 6);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`round(1, 6)` decimal(7,6) NOT NULL default '0.000000'
|
||||
`round(1, 6)` decimal(7,6) NOT NULL DEFAULT '0.000000'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select * from t1;
|
||||
round(1, 6)
|
||||
|
|
|
@ -55,8 +55,8 @@ create table t1 as select uuid(), length(uuid());
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`uuid()` varchar(36) character set utf8 NOT NULL default '',
|
||||
`length(uuid())` int(10) NOT NULL default '0'
|
||||
`uuid()` varchar(36) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`length(uuid())` int(10) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (a timestamp default '2005-05-05 01:01:01',
|
||||
|
|
|
@ -719,37 +719,37 @@ Warning 1265 Data truncated for column 'format(130,10)' at row 1
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`bin(130)` varchar(64) NOT NULL default '',
|
||||
`oct(130)` varchar(64) NOT NULL default '',
|
||||
`conv(130,16,10)` varchar(64) NOT NULL default '',
|
||||
`hex(130)` varchar(6) NOT NULL default '',
|
||||
`char(130)` varbinary(1) NOT NULL default '',
|
||||
`format(130,10)` varchar(4) NOT NULL default '',
|
||||
`left(_latin2'a',1)` varchar(1) character set latin2 NOT NULL default '',
|
||||
`right(_latin2'a',1)` varchar(1) character set latin2 NOT NULL default '',
|
||||
`lcase(_latin2'a')` varchar(1) character set latin2 NOT NULL default '',
|
||||
`ucase(_latin2'a')` varchar(1) character set latin2 NOT NULL default '',
|
||||
`substring(_latin2'a',1,1)` varchar(1) character set latin2 NOT NULL default '',
|
||||
`concat(_latin2'a',_latin2'b')` varchar(2) character set latin2 NOT NULL default '',
|
||||
`lpad(_latin2'a',4,_latin2'b')` varchar(4) character set latin2 NOT NULL default '',
|
||||
`rpad(_latin2'a',4,_latin2'b')` varchar(4) character set latin2 NOT NULL default '',
|
||||
`concat_ws(_latin2'a',_latin2'b')` varchar(1) character set latin2 NOT NULL default '',
|
||||
`make_set(255,_latin2'a',_latin2'b',_latin2'c')` varchar(5) character set latin2 NOT NULL default '',
|
||||
`export_set(255,_latin2'y',_latin2'n',_latin2' ')` varchar(127) character set latin2 NOT NULL default '',
|
||||
`trim(_latin2' a ')` varchar(3) character set latin2 NOT NULL default '',
|
||||
`ltrim(_latin2' a ')` varchar(3) character set latin2 NOT NULL default '',
|
||||
`rtrim(_latin2' a ')` varchar(3) character set latin2 NOT NULL default '',
|
||||
`trim(LEADING _latin2' ' FROM _latin2' a ')` varchar(3) character set latin2 NOT NULL default '',
|
||||
`trim(TRAILING _latin2' ' FROM _latin2' a ')` varchar(3) character set latin2 NOT NULL default '',
|
||||
`trim(BOTH _latin2' ' FROM _latin2' a ')` varchar(3) character set latin2 NOT NULL default '',
|
||||
`repeat(_latin2'a',10)` varchar(10) character set latin2 NOT NULL default '',
|
||||
`reverse(_latin2'ab')` varchar(2) character set latin2 NOT NULL default '',
|
||||
`quote(_latin2'ab')` varchar(6) character set latin2 NOT NULL default '',
|
||||
`soundex(_latin2'ab')` varchar(4) character set latin2 NOT NULL default '',
|
||||
`substring(_latin2'ab',1)` varchar(2) character set latin2 NOT NULL default '',
|
||||
`insert(_latin2'abcd',2,3,_latin2'ef')` varchar(6) character set latin2 NOT NULL default '',
|
||||
`replace(_latin2'abcd',_latin2'b',_latin2'B')` varchar(4) character set latin2 NOT NULL default '',
|
||||
`encode('abcd','ab')` varbinary(4) NOT NULL default ''
|
||||
`bin(130)` varchar(64) NOT NULL DEFAULT '',
|
||||
`oct(130)` varchar(64) NOT NULL DEFAULT '',
|
||||
`conv(130,16,10)` varchar(64) NOT NULL DEFAULT '',
|
||||
`hex(130)` varchar(6) NOT NULL DEFAULT '',
|
||||
`char(130)` varbinary(1) NOT NULL DEFAULT '',
|
||||
`format(130,10)` varchar(4) NOT NULL DEFAULT '',
|
||||
`left(_latin2'a',1)` varchar(1) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`right(_latin2'a',1)` varchar(1) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`lcase(_latin2'a')` varchar(1) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`ucase(_latin2'a')` varchar(1) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`substring(_latin2'a',1,1)` varchar(1) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`concat(_latin2'a',_latin2'b')` varchar(2) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`lpad(_latin2'a',4,_latin2'b')` varchar(4) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`rpad(_latin2'a',4,_latin2'b')` varchar(4) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`concat_ws(_latin2'a',_latin2'b')` varchar(1) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`make_set(255,_latin2'a',_latin2'b',_latin2'c')` varchar(5) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`export_set(255,_latin2'y',_latin2'n',_latin2' ')` varchar(127) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`trim(_latin2' a ')` varchar(3) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`ltrim(_latin2' a ')` varchar(3) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`rtrim(_latin2' a ')` varchar(3) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`trim(LEADING _latin2' ' FROM _latin2' a ')` varchar(3) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`trim(TRAILING _latin2' ' FROM _latin2' a ')` varchar(3) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`trim(BOTH _latin2' ' FROM _latin2' a ')` varchar(3) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`repeat(_latin2'a',10)` varchar(10) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`reverse(_latin2'ab')` varchar(2) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`quote(_latin2'ab')` varchar(6) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`soundex(_latin2'ab')` varchar(4) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`substring(_latin2'ab',1)` varchar(2) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`insert(_latin2'abcd',2,3,_latin2'ef')` varchar(6) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`replace(_latin2'abcd',_latin2'b',_latin2'B')` varchar(4) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`encode('abcd','ab')` varbinary(4) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (a char character set latin2);
|
||||
|
|
|
@ -46,9 +46,9 @@ create table t1 (version char(60)) select database(), user(), version() as 'vers
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`database()` varchar(34) character set utf8 default NULL,
|
||||
`user()` varchar(77) character set utf8 NOT NULL default '',
|
||||
`version` char(60) default NULL
|
||||
`database()` varchar(34) CHARACTER SET utf8 DEFAULT NULL,
|
||||
`user()` varchar(77) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`version` char(60) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
select charset(charset(_utf8'a')), charset(collation(_utf8'a'));
|
||||
|
@ -61,8 +61,8 @@ create table t1 select charset(_utf8'a'), collation(_utf8'a');
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`charset(_utf8'a')` varchar(64) character set utf8 NOT NULL default '',
|
||||
`collation(_utf8'a')` varchar(64) character set utf8 NOT NULL default ''
|
||||
`charset(_utf8'a')` varchar(64) CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`collation(_utf8'a')` varchar(64) CHARACTER SET utf8 NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
select TRUE,FALSE,NULL;
|
||||
|
|
|
@ -7,7 +7,7 @@ SPATIAL KEY(g)
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`fid` int(11) NOT NULL auto_increment,
|
||||
`fid` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`g` geometry NOT NULL,
|
||||
PRIMARY KEY (`fid`),
|
||||
SPATIAL KEY `g` (`g`(32))
|
||||
|
@ -290,7 +290,7 @@ ALTER TABLE t2 ADD SPATIAL KEY(g);
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`fid` int(11) NOT NULL auto_increment,
|
||||
`fid` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`g` geometry NOT NULL,
|
||||
PRIMARY KEY (`fid`),
|
||||
SPATIAL KEY `g` (`g`(32))
|
||||
|
|
|
@ -263,41 +263,41 @@ concat('*',v,'*',c,'*',t,'*')
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`t` varchar(50) default NULL
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` varchar(50) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
create table t2 like t1;
|
||||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`t` varchar(50) default NULL
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` varchar(50) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
create table t3 select * from t1;
|
||||
show create table t3;
|
||||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`t` varchar(50) default NULL
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` varchar(50) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
alter table t1 modify c varchar(10);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`t` varchar(50) default NULL
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` varchar(50) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
alter table t1 modify v char(10);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`t` varchar(50) default NULL
|
||||
`v` char(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` varchar(50) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
alter table t1 modify t varchar(10);
|
||||
Warnings:
|
||||
|
@ -305,9 +305,9 @@ Warning 1265 Data truncated for column 't' at row 2
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`t` varchar(10) default NULL
|
||||
`v` char(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` varchar(10) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
select concat('*',v,'*',c,'*',t,'*') from t1;
|
||||
concat('*',v,'*',c,'*',t,'*')
|
||||
|
@ -318,9 +318,9 @@ create table t1 (v varchar(10), c char(10), t varchar(50), key(v), key(c), key(t
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`t` varchar(50) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` varchar(50) DEFAULT NULL,
|
||||
KEY `v` (`v`),
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10))
|
||||
|
@ -553,9 +553,9 @@ create table t1 (v varchar(10), c char(10), t varchar(50), key using btree (v),
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`t` varchar(50) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` varchar(50) DEFAULT NULL,
|
||||
KEY `v` USING BTREE (`v`),
|
||||
KEY `c` USING BTREE (`c`),
|
||||
KEY `t` USING BTREE (`t`(10))
|
||||
|
@ -644,9 +644,9 @@ create table t1 (v varchar(10), c char(10), t varchar(50), key(v(5)), key(c(5)),
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`t` varchar(50) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` varchar(50) DEFAULT NULL,
|
||||
KEY `v` (`v`(5)),
|
||||
KEY `c` (`c`(5)),
|
||||
KEY `t` (`t`(5))
|
||||
|
@ -656,7 +656,7 @@ create table t1 (v varchar(65530), key(v(10)));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(65530) default NULL,
|
||||
`v` varchar(65530) DEFAULT NULL,
|
||||
KEY `v` (`v`(10))
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
insert into t1 values(repeat('a',65530));
|
||||
|
|
|
@ -244,8 +244,8 @@ t1 CREATE TABLE `t1` (
|
|||
`t_vers` varchar(4) NOT NULL,
|
||||
`t_rele` varchar(2) NOT NULL,
|
||||
`t_cust` varchar(4) NOT NULL,
|
||||
`filler1` char(250) default NULL,
|
||||
`filler2` char(250) default NULL,
|
||||
`filler1` char(250) DEFAULT NULL,
|
||||
`filler2` char(250) DEFAULT NULL,
|
||||
PRIMARY KEY (`t_cpac`,`t_vers`,`t_rele`,`t_cust`),
|
||||
UNIQUE KEY `IX_4` (`t_cust`,`t_cpac`,`t_vers`,`t_rele`),
|
||||
KEY `IX_5` (`t_vers`,`t_rele`,`t_cust`)
|
||||
|
|
|
@ -433,7 +433,7 @@ alter table t1 add constraint constraint_2 unique key_2(a);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL default '0',
|
||||
`a` int(11) NOT NULL DEFAULT '0',
|
||||
PRIMARY KEY (`a`),
|
||||
UNIQUE KEY `constraint_1` (`a`),
|
||||
UNIQUE KEY `key_1` (`a`),
|
||||
|
@ -506,19 +506,19 @@ drop table t1;
|
|||
SHOW CREATE TABLE INFORMATION_SCHEMA.character_sets;
|
||||
Table Create Table
|
||||
CHARACTER_SETS CREATE TEMPORARY TABLE `CHARACTER_SETS` (
|
||||
`CHARACTER_SET_NAME` varchar(64) NOT NULL default '',
|
||||
`DEFAULT_COLLATE_NAME` varchar(64) NOT NULL default '',
|
||||
`DESCRIPTION` varchar(60) NOT NULL default '',
|
||||
`MAXLEN` bigint(3) NOT NULL default '0'
|
||||
`CHARACTER_SET_NAME` varchar(64) NOT NULL DEFAULT '',
|
||||
`DEFAULT_COLLATE_NAME` varchar(64) NOT NULL DEFAULT '',
|
||||
`DESCRIPTION` varchar(60) NOT NULL DEFAULT '',
|
||||
`MAXLEN` bigint(3) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=utf8
|
||||
set names latin2;
|
||||
SHOW CREATE TABLE INFORMATION_SCHEMA.character_sets;
|
||||
Table Create Table
|
||||
CHARACTER_SETS CREATE TEMPORARY TABLE `CHARACTER_SETS` (
|
||||
`CHARACTER_SET_NAME` varchar(64) NOT NULL default '',
|
||||
`DEFAULT_COLLATE_NAME` varchar(64) NOT NULL default '',
|
||||
`DESCRIPTION` varchar(60) NOT NULL default '',
|
||||
`MAXLEN` bigint(3) NOT NULL default '0'
|
||||
`CHARACTER_SET_NAME` varchar(64) NOT NULL DEFAULT '',
|
||||
`DEFAULT_COLLATE_NAME` varchar(64) NOT NULL DEFAULT '',
|
||||
`DESCRIPTION` varchar(60) NOT NULL DEFAULT '',
|
||||
`MAXLEN` bigint(3) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=utf8
|
||||
set names latin1;
|
||||
create table t1 select * from information_schema.CHARACTER_SETS
|
||||
|
@ -530,10 +530,10 @@ alter table t1 default character set utf8;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`CHARACTER_SET_NAME` varchar(64) NOT NULL default '',
|
||||
`DEFAULT_COLLATE_NAME` varchar(64) NOT NULL default '',
|
||||
`DESCRIPTION` varchar(60) NOT NULL default '',
|
||||
`MAXLEN` bigint(3) NOT NULL default '0'
|
||||
`CHARACTER_SET_NAME` varchar(64) NOT NULL DEFAULT '',
|
||||
`DEFAULT_COLLATE_NAME` varchar(64) NOT NULL DEFAULT '',
|
||||
`DESCRIPTION` varchar(60) NOT NULL DEFAULT '',
|
||||
`MAXLEN` bigint(3) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8
|
||||
drop table t1;
|
||||
create view v1 as select * from information_schema.TABLES;
|
||||
|
|
|
@ -856,7 +856,7 @@ create table t1 (a char(20), index (a(5))) engine=innodb;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(20) default NULL,
|
||||
`a` char(20) DEFAULT NULL,
|
||||
KEY `a` (`a`(5))
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
@ -1587,7 +1587,7 @@ create table t2 (id int(11) not null auto_increment, id2 int(11) not null, const
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`id` int(11) NOT NULL auto_increment,
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`id2` int(11) NOT NULL,
|
||||
PRIMARY KEY (`id`),
|
||||
KEY `id` (`id`,`id2`),
|
||||
|
@ -1598,7 +1598,7 @@ create table t2 (id int(11) not null auto_increment, id2 int(11) not null, const
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`id` int(11) NOT NULL auto_increment,
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`id2` int(11) NOT NULL,
|
||||
KEY `t1_id_fk` (`id`),
|
||||
CONSTRAINT `t1_id_fk` FOREIGN KEY (`id`) REFERENCES `t1` (`id`)
|
||||
|
@ -1607,7 +1607,7 @@ alter table t2 add index id_test (id), add index id_test2 (id,id2);
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`id` int(11) NOT NULL auto_increment,
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`id2` int(11) NOT NULL,
|
||||
KEY `id_test` (`id`),
|
||||
KEY `id_test2` (`id`,`id2`),
|
||||
|
@ -1620,8 +1620,8 @@ create table t2 (a int auto_increment primary key, b int, index(b), foreign key
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`a` int(11) NOT NULL auto_increment,
|
||||
`b` int(11) default NULL,
|
||||
`a` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`b` int(11) DEFAULT NULL,
|
||||
PRIMARY KEY (`a`),
|
||||
UNIQUE KEY `b_2` (`b`),
|
||||
KEY `b` (`b`),
|
||||
|
@ -1632,8 +1632,8 @@ create table t2 (a int auto_increment primary key, b int, foreign key (b) refere
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`a` int(11) NOT NULL auto_increment,
|
||||
`b` int(11) default NULL,
|
||||
`a` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`b` int(11) DEFAULT NULL,
|
||||
PRIMARY KEY (`a`),
|
||||
UNIQUE KEY `b` (`b`),
|
||||
CONSTRAINT `t2_ibfk_1` FOREIGN KEY (`b`) REFERENCES `t1` (`id`),
|
||||
|
@ -1843,40 +1843,40 @@ concat('*',v,'*',c,'*',t,'*')
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
create table t2 like t1;
|
||||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
create table t3 select * from t1;
|
||||
show create table t3;
|
||||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
alter table t1 modify c varchar(10);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
alter table t1 modify v char(10);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`v` char(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
alter table t1 modify t varchar(10);
|
||||
|
@ -1885,9 +1885,9 @@ Note 1265 Data truncated for column 't' at row 2
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`t` varchar(10) default NULL
|
||||
`v` char(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` varchar(10) DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
select concat('*',v,'*',c,'*',t,'*') from t1;
|
||||
concat('*',v,'*',c,'*',t,'*')
|
||||
|
@ -1898,8 +1898,8 @@ create table t1 (v varchar(10), c char(10), t text, key(v), key(c), key(t(10)));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `v` (`v`),
|
||||
KEY `c` (`c`),
|
||||
|
@ -2117,8 +2117,8 @@ alter table t1 modify v varchar(300), drop key v, drop key v_2, add key v (v);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(300) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(300) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10)),
|
||||
|
@ -2197,8 +2197,8 @@ alter table t1 drop key v, add key v (v(30));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(300) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(300) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10)),
|
||||
|
@ -2277,8 +2277,8 @@ alter table t1 modify v varchar(600), drop key v, add key v (v);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(600) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(600) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10)),
|
||||
|
@ -2355,8 +2355,8 @@ create table t1 (v varchar(10), c char(10), t text, key(v(5)), key(c(5)), key(t(
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `v` (`v`(5)),
|
||||
KEY `c` (`c`(5)),
|
||||
|
@ -2367,15 +2367,15 @@ create table t1 (v char(10) character set utf8);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) character set utf8 default NULL
|
||||
`v` char(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (v varchar(10), c char(10)) row_format=fixed;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ROW_FORMAT=FIXED
|
||||
insert into t1 values('a','a'),('a ','a ');
|
||||
select concat('*',v,'*',c,'*') from t1;
|
||||
|
@ -2417,7 +2417,7 @@ Note 1246 Converting column 'v' from VARCHAR to TEXT
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` mediumtext character set utf8
|
||||
`v` mediumtext CHARACTER SET utf8
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
set storage_engine=MyISAM;
|
||||
|
@ -2544,8 +2544,8 @@ character set = latin1 engine = innodb;
|
|||
show create table t9;
|
||||
Table Create Table
|
||||
t9 CREATE TABLE `t9` (
|
||||
`col1` varchar(512) default NULL,
|
||||
`col2` varchar(512) default NULL,
|
||||
`col1` varchar(512) DEFAULT NULL,
|
||||
`col2` varchar(512) DEFAULT NULL,
|
||||
KEY `col1` (`col1`,`col2`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
drop table t1, t2, t3, t4, t5, t6, t7, t8, t9;
|
||||
|
@ -2568,7 +2568,7 @@ Warning 1071 Specified key was too long; max key length is 767 bytes
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`col1` varchar(768) default NULL,
|
||||
`col1` varchar(768) DEFAULT NULL,
|
||||
KEY `col1` (`col1`(767))
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
drop table t1, t2, t3, t4;
|
||||
|
|
|
@ -1,50 +1,51 @@
|
|||
SET storage_engine=innodb;
|
||||
DROP TABLE IF EXISTS t1, gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE gis_point (fid INTEGER, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER, g GEOMETRY);
|
||||
CREATE TABLE gis_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRY);
|
||||
SHOW CREATE TABLE gis_point;
|
||||
Table Create Table
|
||||
gis_point CREATE TABLE `gis_point` (
|
||||
`fid` int(11) default NULL,
|
||||
`g` point default NULL
|
||||
`fid` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`g` point DEFAULT NULL,
|
||||
PRIMARY KEY (`fid`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
SHOW FIELDS FROM gis_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g point YES NULL
|
||||
SHOW FIELDS FROM gis_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g linestring YES NULL
|
||||
SHOW FIELDS FROM gis_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g polygon YES NULL
|
||||
SHOW FIELDS FROM gis_multi_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipoint YES NULL
|
||||
SHOW FIELDS FROM gis_multi_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multilinestring YES NULL
|
||||
SHOW FIELDS FROM gis_multi_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipolygon YES NULL
|
||||
SHOW FIELDS FROM gis_geometrycollection;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometrycollection YES NULL
|
||||
SHOW FIELDS FROM gis_geometry;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometry YES NULL
|
||||
INSERT INTO gis_point VALUES
|
||||
(101, PointFromText('POINT(10 10)')),
|
||||
|
@ -407,6 +408,7 @@ Warnings:
|
|||
Note 1003 select `test`.`g1`.`fid` AS `first`,`test`.`g2`.`fid` AS `second`,within(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `w`,contains(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `c`,overlaps(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `o`,equals(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `e`,disjoint(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `d`,touches(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `t`,intersects(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `i`,crosses(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `r` from `test`.`gis_geometrycollection` `g1` join `test`.`gis_geometrycollection` `g2` order by `test`.`g1`.`fid`,`test`.`g2`.`fid`
|
||||
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE t1 (
|
||||
a INTEGER PRIMARY KEY AUTO_INCREMENT,
|
||||
gp point,
|
||||
ln linestring,
|
||||
pg polygon,
|
||||
|
@ -418,6 +420,7 @@ gm geometry
|
|||
);
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -429,6 +432,7 @@ gm geometry YES NULL
|
|||
ALTER TABLE t1 ADD fid INT;
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -439,20 +443,20 @@ gc geometrycollection YES NULL
|
|||
gm geometry YES NULL
|
||||
fid int(11) YES NULL
|
||||
DROP TABLE t1;
|
||||
create table t1 (a geometry not null);
|
||||
insert into t1 values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 values ('Garbage');
|
||||
create table t1 (pk integer primary key auto_increment, a geometry not null);
|
||||
insert into t1 (a) values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert IGNORE into t1 values ('Garbage');
|
||||
insert IGNORE into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
create table t1 (fl geometry);
|
||||
insert into t1 values (1);
|
||||
create table t1 (pk integer primary key auto_increment, fl geometry);
|
||||
insert into t1 (fl) values (1);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (1.11);
|
||||
insert into t1 (fl) values (1.11);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values ("qwerty");
|
||||
insert into t1 (fl) values ("qwerty");
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (pointfromtext('point(1,1)'));
|
||||
insert into t1 (fl) values (pointfromtext('point(1,1)'));
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
|
|
|
@ -242,8 +242,8 @@ create table t1 (c varchar(30) character set utf8, t text character set utf8, un
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` varchar(30) character set utf8 default NULL,
|
||||
`t` text character set utf8,
|
||||
`c` varchar(30) CHARACTER SET utf8 DEFAULT NULL,
|
||||
`t` text CHARACTER SET utf8,
|
||||
UNIQUE KEY `c` (`c`(2)),
|
||||
UNIQUE KEY `t` (`t`(3))
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
@ -350,24 +350,24 @@ create table t1 (a varchar(10), b varchar(10), key(a(10),b(10)));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(10) default NULL,
|
||||
`b` varchar(10) default NULL,
|
||||
`a` varchar(10) DEFAULT NULL,
|
||||
`b` varchar(10) DEFAULT NULL,
|
||||
KEY `a` (`a`,`b`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 modify b varchar(20);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(10) default NULL,
|
||||
`b` varchar(20) default NULL,
|
||||
`a` varchar(10) DEFAULT NULL,
|
||||
`b` varchar(20) DEFAULT NULL,
|
||||
KEY `a` (`a`,`b`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 modify a varchar(20);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(20) default NULL,
|
||||
`b` varchar(20) default NULL,
|
||||
`a` varchar(20) DEFAULT NULL,
|
||||
`b` varchar(20) DEFAULT NULL,
|
||||
KEY `a` (`a`,`b`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
@ -412,10 +412,10 @@ index (c2, c4));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` int(11) default NULL,
|
||||
`c2` char(12) NOT NULL default '',
|
||||
`c3` varchar(123) NOT NULL default '',
|
||||
`c4` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`c1` int(11) DEFAULT NULL,
|
||||
`c2` char(12) NOT NULL DEFAULT '',
|
||||
`c3` varchar(123) NOT NULL DEFAULT '',
|
||||
`c4` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`c2`,`c3`),
|
||||
UNIQUE KEY `i4` (`c4`),
|
||||
KEY `c1` (`c1`),
|
||||
|
@ -445,10 +445,10 @@ ERROR 42000: Can't DROP 'PRIMARY'; check that column/key exists
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` int(11) NOT NULL default '0',
|
||||
`c2` char(12) NOT NULL default '',
|
||||
`c3` varchar(123) NOT NULL default '',
|
||||
`c4` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`c1` int(11) NOT NULL DEFAULT '0',
|
||||
`c2` char(12) NOT NULL DEFAULT '',
|
||||
`c3` varchar(123) NOT NULL DEFAULT '',
|
||||
`c4` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
KEY `i1` (`c1`),
|
||||
KEY `i5` (`c1`,`c2`,`c3`,`c4`),
|
||||
KEY `c1` (`c1`),
|
||||
|
|
|
@ -173,7 +173,7 @@ show create table t3;
|
|||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` char(20) default NULL,
|
||||
`b` char(20) DEFAULT NULL,
|
||||
KEY `a` (`a`)
|
||||
) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`)
|
||||
create table t4 (a int not null, b char(10), key(a)) engine=MERGE UNION=(t1,t2);
|
||||
|
@ -191,7 +191,7 @@ show create table t5;
|
|||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` char(20) default NULL,
|
||||
`b` char(20) DEFAULT NULL,
|
||||
KEY `a` (`a`)
|
||||
) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`mysqltest`.`t6`)
|
||||
alter table t5 engine=myisam;
|
||||
|
@ -314,14 +314,14 @@ show create table t5;
|
|||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` int(11) NOT NULL auto_increment,
|
||||
`b` int(11) NOT NULL AUTO_INCREMENT,
|
||||
PRIMARY KEY (`a`,`b`)
|
||||
) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 INSERT_METHOD=FIRST UNION=(`t1`,`t2`)
|
||||
show create table t6;
|
||||
Table Create Table
|
||||
t6 CREATE TABLE `t6` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` int(11) NOT NULL auto_increment,
|
||||
`b` int(11) NOT NULL AUTO_INCREMENT,
|
||||
PRIMARY KEY (`a`,`b`)
|
||||
) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 INSERT_METHOD=LAST UNION=(`t1`,`t2`)
|
||||
insert into t1 values (1,NULL),(1,NULL),(1,NULL),(1,NULL);
|
||||
|
|
|
@ -746,40 +746,40 @@ concat('*',v,'*',c,'*',t,'*')
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
create table t2 like t1;
|
||||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
create table t3 select * from t1;
|
||||
show create table t3;
|
||||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 modify c varchar(10);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 modify v char(10);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`v` char(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 modify t varchar(10);
|
||||
|
@ -788,9 +788,9 @@ Note 1265 Data truncated for column 't' at row 2
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) default NULL,
|
||||
`c` varchar(10) default NULL,
|
||||
`t` varchar(10) default NULL
|
||||
`v` char(10) DEFAULT NULL,
|
||||
`c` varchar(10) DEFAULT NULL,
|
||||
`t` varchar(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select concat('*',v,'*',c,'*',t,'*') from t1;
|
||||
concat('*',v,'*',c,'*',t,'*')
|
||||
|
@ -801,8 +801,8 @@ create table t1 (v varchar(10), c char(10), t text, key(v), key(c), key(t(10)));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `v` (`v`),
|
||||
KEY `c` (`c`),
|
||||
|
@ -1020,8 +1020,8 @@ alter table t1 modify v varchar(300), drop key v, drop key v_2, add key v (v);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(300) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(300) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10)),
|
||||
|
@ -1100,8 +1100,8 @@ alter table t1 drop key v, add key v (v(30));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(300) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(300) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10)),
|
||||
|
@ -1180,8 +1180,8 @@ alter table t1 modify v varchar(600), drop key v, add key v (v);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(600) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(600) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `c` (`c`),
|
||||
KEY `t` (`t`(10)),
|
||||
|
@ -1258,8 +1258,8 @@ create table t1 (v varchar(10), c char(10), t text, key(v(5)), key(c(5)), key(t(
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL,
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL,
|
||||
`t` text,
|
||||
KEY `v` (`v`(5)),
|
||||
KEY `c` (`c`(5)),
|
||||
|
@ -1270,15 +1270,15 @@ create table t1 (v char(10) character set utf8);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` char(10) character set utf8 default NULL
|
||||
`v` char(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (v varchar(10), c char(10)) row_format=fixed;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(10) default NULL,
|
||||
`c` char(10) default NULL
|
||||
`v` varchar(10) DEFAULT NULL,
|
||||
`c` char(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=FIXED
|
||||
insert into t1 values('a','a'),('a ','a ');
|
||||
select concat('*',v,'*',c,'*') from t1;
|
||||
|
@ -1320,7 +1320,7 @@ Note 1246 Converting column 'v' from VARCHAR to TEXT
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` mediumtext character set utf8
|
||||
`v` mediumtext CHARACTER SET utf8
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (v varchar(65535));
|
||||
|
|
|
@ -111,8 +111,8 @@ CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET l
|
|||
USE `test`;
|
||||
DROP TABLE IF EXISTS `t1`;
|
||||
CREATE TABLE `t1` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -121,8 +121,8 @@ INSERT DELAYED IGNORE INTO `t1` VALUES (1,'first value'),(2,'first value'),(3,'
|
|||
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t2`;
|
||||
CREATE TABLE `t2` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -131,8 +131,8 @@ INSERT DELAYED IGNORE INTO `t2` VALUES (1,'first value'),(2,'first value'),(3,'
|
|||
/*!40000 ALTER TABLE `t2` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t3`;
|
||||
CREATE TABLE `t3` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -141,8 +141,8 @@ INSERT DELAYED IGNORE INTO `t3` VALUES (1,'first value'),(2,'first value'),(3,'
|
|||
/*!40000 ALTER TABLE `t3` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t4`;
|
||||
CREATE TABLE `t4` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -151,8 +151,8 @@ INSERT DELAYED IGNORE INTO `t4` VALUES (1,'first value'),(2,'first value'),(3,'
|
|||
/*!40000 ALTER TABLE `t4` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t5`;
|
||||
CREATE TABLE `t5` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=ARCHIVE DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -161,8 +161,8 @@ INSERT DELAYED IGNORE INTO `t5` VALUES (1,'first value'),(2,'first value'),(3,'
|
|||
/*!40000 ALTER TABLE `t5` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t6`;
|
||||
CREATE TABLE `t6` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -196,8 +196,8 @@ CREATE DATABASE /*!32312 IF NOT EXISTS*/ `test` /*!40100 DEFAULT CHARACTER SET l
|
|||
USE `test`;
|
||||
DROP TABLE IF EXISTS `t1`;
|
||||
CREATE TABLE `t1` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -206,8 +206,8 @@ INSERT DELAYED INTO `t1` VALUES (1,'first value'),(2,'first value'),(3,'first v
|
|||
/*!40000 ALTER TABLE `t1` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t2`;
|
||||
CREATE TABLE `t2` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -216,8 +216,8 @@ INSERT DELAYED INTO `t2` VALUES (1,'first value'),(2,'first value'),(3,'first v
|
|||
/*!40000 ALTER TABLE `t2` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t3`;
|
||||
CREATE TABLE `t3` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -226,8 +226,8 @@ INSERT DELAYED INTO `t3` VALUES (1,'first value'),(2,'first value'),(3,'first v
|
|||
/*!40000 ALTER TABLE `t3` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t4`;
|
||||
CREATE TABLE `t4` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -236,8 +236,8 @@ INSERT DELAYED INTO `t4` VALUES (1,'first value'),(2,'first value'),(3,'first v
|
|||
/*!40000 ALTER TABLE `t4` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t5`;
|
||||
CREATE TABLE `t5` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=ARCHIVE DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
@ -246,8 +246,8 @@ INSERT DELAYED INTO `t5` VALUES (1,'first value'),(2,'first value'),(3,'first v
|
|||
/*!40000 ALTER TABLE `t5` ENABLE KEYS */;
|
||||
DROP TABLE IF EXISTS `t6`;
|
||||
CREATE TABLE `t6` (
|
||||
`id` int(8) default NULL,
|
||||
`name` varchar(32) default NULL
|
||||
`id` int(8) DEFAULT NULL,
|
||||
`name` varchar(32) DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1;
|
||||
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -7,7 +7,7 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`pk1` int(11) NOT NULL,
|
||||
`b` bit(64) default NULL,
|
||||
`b` bit(64) DEFAULT NULL,
|
||||
PRIMARY KEY (`pk1`)
|
||||
) ENGINE=ndbcluster DEFAULT CHARSET=latin1 PARTITION BY KEY ()
|
||||
insert into t1 values
|
||||
|
|
|
@ -170,7 +170,7 @@ CREATE TABLE test.t6 (pk1 MEDIUMINT NOT NULL AUTO_INCREMENT, c2 VARCHAR(220) NOT
|
|||
SHOW CREATE TABLE test.t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` varchar(150) NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -179,7 +179,7 @@ t1 CREATE TABLE `t1` (
|
|||
SHOW CREATE TABLE test.t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` text NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -188,7 +188,7 @@ t2 CREATE TABLE `t2` (
|
|||
SHOW CREATE TABLE test.t3;
|
||||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` varchar(202) NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -197,7 +197,7 @@ t3 CREATE TABLE `t3` (
|
|||
SHOW CREATE TABLE test.t4;
|
||||
Table Create Table
|
||||
t4 CREATE TABLE `t4` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` varchar(180) NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -206,7 +206,7 @@ t4 CREATE TABLE `t4` (
|
|||
SHOW CREATE TABLE test.t5;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` text NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -215,7 +215,7 @@ t5 CREATE TABLE `t5` (
|
|||
SHOW CREATE TABLE test.t6;
|
||||
Table Create Table
|
||||
t6 CREATE TABLE `t6` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` varchar(220) NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -336,7 +336,7 @@ ENGINE =NDB;
|
|||
SHOW CREATE TABLE test.t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` varchar(150) NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -345,7 +345,7 @@ t1 CREATE TABLE `t1` (
|
|||
SHOW CREATE TABLE test.t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` text NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -354,7 +354,7 @@ t2 CREATE TABLE `t2` (
|
|||
SHOW CREATE TABLE test.t3;
|
||||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` varchar(202) NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -363,7 +363,7 @@ t3 CREATE TABLE `t3` (
|
|||
SHOW CREATE TABLE test.t4;
|
||||
Table Create Table
|
||||
t4 CREATE TABLE `t4` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` varchar(180) NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -372,7 +372,7 @@ t4 CREATE TABLE `t4` (
|
|||
SHOW CREATE TABLE test.t5;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` text NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
@ -381,7 +381,7 @@ t5 CREATE TABLE `t5` (
|
|||
SHOW CREATE TABLE test.t6;
|
||||
Table Create Table
|
||||
t6 CREATE TABLE `t6` (
|
||||
`pk1` mediumint(9) NOT NULL auto_increment,
|
||||
`pk1` mediumint(9) NOT NULL AUTO_INCREMENT,
|
||||
`c2` varchar(220) NOT NULL,
|
||||
`c3` int(11) NOT NULL,
|
||||
`c4` bit(1) NOT NULL,
|
||||
|
|
|
@ -1,66 +1,51 @@
|
|||
SET storage_engine=ndbcluster;
|
||||
DROP TABLE IF EXISTS t1, gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE gis_point (fid INTEGER, g POINT);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_line (fid INTEGER, g LINESTRING);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_polygon (fid INTEGER, g POLYGON);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_multi_point (fid INTEGER, g MULTIPOINT);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_multi_line (fid INTEGER, g MULTILINESTRING);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER, g MULTIPOLYGON);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER, g GEOMETRYCOLLECTION);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_geometry (fid INTEGER, g GEOMETRY);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRY);
|
||||
SHOW CREATE TABLE gis_point;
|
||||
Table Create Table
|
||||
gis_point CREATE TABLE `gis_point` (
|
||||
`fid` int(11) default NULL,
|
||||
`g` point default NULL
|
||||
`fid` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`g` point DEFAULT NULL,
|
||||
PRIMARY KEY (`fid`)
|
||||
) ENGINE=ndbcluster DEFAULT CHARSET=latin1 PARTITION BY KEY ()
|
||||
SHOW FIELDS FROM gis_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g point YES NULL
|
||||
SHOW FIELDS FROM gis_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g linestring YES NULL
|
||||
SHOW FIELDS FROM gis_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g polygon YES NULL
|
||||
SHOW FIELDS FROM gis_multi_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipoint YES NULL
|
||||
SHOW FIELDS FROM gis_multi_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multilinestring YES NULL
|
||||
SHOW FIELDS FROM gis_multi_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipolygon YES NULL
|
||||
SHOW FIELDS FROM gis_geometrycollection;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometrycollection YES NULL
|
||||
SHOW FIELDS FROM gis_geometry;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometry YES NULL
|
||||
INSERT INTO gis_point VALUES
|
||||
(101, PointFromText('POINT(10 10)')),
|
||||
|
@ -423,6 +408,7 @@ Warnings:
|
|||
Note 1003 select `test`.`g1`.`fid` AS `first`,`test`.`g2`.`fid` AS `second`,within(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `w`,contains(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `c`,overlaps(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `o`,equals(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `e`,disjoint(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `d`,touches(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `t`,intersects(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `i`,crosses(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `r` from `test`.`gis_geometrycollection` `g1` join `test`.`gis_geometrycollection` `g2` order by `test`.`g1`.`fid`,`test`.`g2`.`fid`
|
||||
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE t1 (
|
||||
a INTEGER PRIMARY KEY AUTO_INCREMENT,
|
||||
gp point,
|
||||
ln linestring,
|
||||
pg polygon,
|
||||
|
@ -432,10 +418,9 @@ mpg multipolygon,
|
|||
gc geometrycollection,
|
||||
gm geometry
|
||||
);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -445,10 +430,9 @@ mpg multipolygon YES NULL
|
|||
gc geometrycollection YES NULL
|
||||
gm geometry YES NULL
|
||||
ALTER TABLE t1 ADD fid INT;
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -459,90 +443,71 @@ gc geometrycollection YES NULL
|
|||
gm geometry YES NULL
|
||||
fid int(11) YES NULL
|
||||
DROP TABLE t1;
|
||||
create table t1 (a geometry not null);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
insert into t1 values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 values ('Garbage');
|
||||
create table t1 (pk integer primary key auto_increment, a geometry not null);
|
||||
insert into t1 (a) values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert IGNORE into t1 values ('Garbage');
|
||||
insert IGNORE into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
create table t1 (fl geometry);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
insert into t1 values (1);
|
||||
create table t1 (pk integer primary key auto_increment, fl geometry);
|
||||
insert into t1 (fl) values (1);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (1.11);
|
||||
insert into t1 (fl) values (1.11);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values ("qwerty");
|
||||
insert into t1 (fl) values ("qwerty");
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (pointfromtext('point(1,1)'));
|
||||
insert into t1 (fl) values (pointfromtext('point(1,1)'));
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
set engine_condition_pushdown = on;
|
||||
DROP TABLE IF EXISTS t1, gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE gis_point (fid INTEGER, g POINT);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_line (fid INTEGER, g LINESTRING);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_polygon (fid INTEGER, g POLYGON);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_multi_point (fid INTEGER, g MULTIPOINT);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_multi_line (fid INTEGER, g MULTILINESTRING);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER, g MULTIPOLYGON);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER, g GEOMETRYCOLLECTION);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_geometry (fid INTEGER, g GEOMETRY);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
CREATE TABLE gis_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POINT);
|
||||
CREATE TABLE gis_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g LINESTRING);
|
||||
CREATE TABLE gis_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g POLYGON);
|
||||
CREATE TABLE gis_multi_point (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOINT);
|
||||
CREATE TABLE gis_multi_line (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTILINESTRING);
|
||||
CREATE TABLE gis_multi_polygon (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g MULTIPOLYGON);
|
||||
CREATE TABLE gis_geometrycollection (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRYCOLLECTION);
|
||||
CREATE TABLE gis_geometry (fid INTEGER PRIMARY KEY AUTO_INCREMENT, g GEOMETRY);
|
||||
SHOW CREATE TABLE gis_point;
|
||||
Table Create Table
|
||||
gis_point CREATE TABLE `gis_point` (
|
||||
`fid` int(11) default NULL,
|
||||
`g` point default NULL
|
||||
`fid` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`g` point DEFAULT NULL,
|
||||
PRIMARY KEY (`fid`)
|
||||
) ENGINE=ndbcluster DEFAULT CHARSET=latin1 PARTITION BY KEY ()
|
||||
SHOW FIELDS FROM gis_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g point YES NULL
|
||||
SHOW FIELDS FROM gis_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g linestring YES NULL
|
||||
SHOW FIELDS FROM gis_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g polygon YES NULL
|
||||
SHOW FIELDS FROM gis_multi_point;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipoint YES NULL
|
||||
SHOW FIELDS FROM gis_multi_line;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multilinestring YES NULL
|
||||
SHOW FIELDS FROM gis_multi_polygon;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g multipolygon YES NULL
|
||||
SHOW FIELDS FROM gis_geometrycollection;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometrycollection YES NULL
|
||||
SHOW FIELDS FROM gis_geometry;
|
||||
Field Type Null Key Default Extra
|
||||
fid int(11) YES NULL
|
||||
fid int(11) NO PRI NULL auto_increment
|
||||
g geometry YES NULL
|
||||
INSERT INTO gis_point VALUES
|
||||
(101, PointFromText('POINT(10 10)')),
|
||||
|
@ -905,6 +870,7 @@ Warnings:
|
|||
Note 1003 select `test`.`g1`.`fid` AS `first`,`test`.`g2`.`fid` AS `second`,within(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `w`,contains(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `c`,overlaps(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `o`,equals(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `e`,disjoint(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `d`,touches(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `t`,intersects(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `i`,crosses(`test`.`g1`.`g`,`test`.`g2`.`g`) AS `r` from `test`.`gis_geometrycollection` `g1` join `test`.`gis_geometrycollection` `g2` order by `test`.`g1`.`fid`,`test`.`g2`.`fid`
|
||||
DROP TABLE gis_point, gis_line, gis_polygon, gis_multi_point, gis_multi_line, gis_multi_polygon, gis_geometrycollection, gis_geometry;
|
||||
CREATE TABLE t1 (
|
||||
a INTEGER PRIMARY KEY AUTO_INCREMENT,
|
||||
gp point,
|
||||
ln linestring,
|
||||
pg polygon,
|
||||
|
@ -914,10 +880,9 @@ mpg multipolygon,
|
|||
gc geometrycollection,
|
||||
gm geometry
|
||||
);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -927,10 +892,9 @@ mpg multipolygon YES NULL
|
|||
gc geometrycollection YES NULL
|
||||
gm geometry YES NULL
|
||||
ALTER TABLE t1 ADD fid INT;
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
SHOW FIELDS FROM t1;
|
||||
Field Type Null Key Default Extra
|
||||
a int(11) NO PRI NULL auto_increment
|
||||
gp point YES NULL
|
||||
ln linestring YES NULL
|
||||
pg polygon YES NULL
|
||||
|
@ -941,24 +905,20 @@ gc geometrycollection YES NULL
|
|||
gm geometry YES NULL
|
||||
fid int(11) YES NULL
|
||||
DROP TABLE t1;
|
||||
create table t1 (a geometry not null);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
insert into t1 values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 values ('Garbage');
|
||||
create table t1 (pk integer primary key auto_increment, a geometry not null);
|
||||
insert into t1 (a) values (GeomFromText('Point(1 2)'));
|
||||
insert into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert IGNORE into t1 values ('Garbage');
|
||||
insert IGNORE into t1 (a) values ('Garbage');
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
create table t1 (fl geometry);
|
||||
Warnings:
|
||||
Error 1538 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK'
|
||||
insert into t1 values (1);
|
||||
create table t1 (pk integer primary key auto_increment, fl geometry);
|
||||
insert into t1 (fl) values (1);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (1.11);
|
||||
insert into t1 (fl) values (1.11);
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values ("qwerty");
|
||||
insert into t1 (fl) values ("qwerty");
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
insert into t1 values (pointfromtext('point(1,1)'));
|
||||
insert into t1 (fl) values (pointfromtext('point(1,1)'));
|
||||
ERROR 22003: Cannot get geometry object from data you send to the GEOMETRY field
|
||||
drop table t1;
|
||||
|
|
|
@ -73,10 +73,10 @@ NDBT_ProgramExit: 0 - OK
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL default '0',
|
||||
`b` char(10) character set latin1 collate latin1_bin NOT NULL default '',
|
||||
`c` int(11) NOT NULL default '0',
|
||||
`d` int(11) default NULL,
|
||||
`a` int(11) NOT NULL DEFAULT '0',
|
||||
`b` char(10) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL DEFAULT '',
|
||||
`c` int(11) NOT NULL DEFAULT '0',
|
||||
`d` int(11) DEFAULT NULL,
|
||||
PRIMARY KEY USING HASH (`a`,`b`,`c`)
|
||||
) ENGINE=ndbcluster DEFAULT CHARSET=latin1 PARTITION BY KEY (b)
|
||||
DROP TABLE t1;
|
||||
|
|
|
@ -227,44 +227,44 @@ rpad(null, 10, 'str') as c38;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c00` binary(0) default NULL,
|
||||
`c01` varchar(6) character set latin2 default NULL,
|
||||
`c02` varchar(6) character set latin2 default NULL,
|
||||
`c03` varchar(6) character set latin2 NOT NULL default '',
|
||||
`c04` varchar(6) character set latin2 default NULL,
|
||||
`c05` varchar(6) character set latin2 default NULL,
|
||||
`c06` varchar(6) character set latin2 default NULL,
|
||||
`c07` varchar(6) character set latin2 default NULL,
|
||||
`c08` varchar(6) character set latin2 default NULL,
|
||||
`c09` varchar(6) character set latin2 default NULL,
|
||||
`c10` varchar(6) character set latin2 default NULL,
|
||||
`c11` varchar(6) character set latin2 default NULL,
|
||||
`c12` varchar(6) character set latin2 default NULL,
|
||||
`c13` varchar(6) character set latin2 default NULL,
|
||||
`c14` char(0) character set latin2 default NULL,
|
||||
`c15` char(0) character set latin2 default NULL,
|
||||
`c16` varchar(6) character set latin2 default NULL,
|
||||
`c17` varchar(6) character set latin2 default NULL,
|
||||
`c18` char(0) character set latin2 default NULL,
|
||||
`c19` varchar(6) character set latin2 default NULL,
|
||||
`c20` varchar(6) character set latin2 default NULL,
|
||||
`c21` varchar(6) character set latin2 default NULL,
|
||||
`c22` varchar(6) character set latin2 default NULL,
|
||||
`c23` varchar(9) character set latin2 default NULL,
|
||||
`c24` varchar(9) character set latin2 default NULL,
|
||||
`c25` varchar(12) character set latin2 default NULL,
|
||||
`c26` varchar(7) character set latin2 default NULL,
|
||||
`c27` varchar(7) character set latin2 default NULL,
|
||||
`c29` varchar(381) character set latin2 default NULL,
|
||||
`c30` varchar(317) character set latin2 default NULL,
|
||||
`c31` varchar(192) character set latin2 default NULL,
|
||||
`c32` char(0) character set latin2 default NULL,
|
||||
`c33` varchar(3) character set latin2 default NULL,
|
||||
`c34` varchar(3) character set latin2 default NULL,
|
||||
`c35` varchar(3) character set latin2 default NULL,
|
||||
`c36` varchar(3) character set latin2 default NULL,
|
||||
`c37` varchar(10) character set latin2 default NULL,
|
||||
`c38` varchar(10) character set latin2 default NULL
|
||||
`c00` binary(0) DEFAULT NULL,
|
||||
`c01` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c02` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c03` varchar(6) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`c04` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c05` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c06` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c07` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c08` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c09` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c10` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c11` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c12` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c13` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c14` char(0) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c15` char(0) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c16` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c17` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c18` char(0) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c19` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c20` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c21` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c22` varchar(6) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c23` varchar(9) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c24` varchar(9) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c25` varchar(12) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c26` varchar(7) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c27` varchar(7) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c29` varchar(381) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c30` varchar(317) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c31` varchar(192) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c32` char(0) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c33` varchar(3) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c34` varchar(3) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c35` varchar(3) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c36` varchar(3) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c37` varchar(10) CHARACTER SET latin2 DEFAULT NULL,
|
||||
`c38` varchar(10) CHARACTER SET latin2 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
select
|
||||
|
|
|
@ -184,7 +184,7 @@ PARTITIONS 1
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) default NULL
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1 PARTITION BY LIST (a) (PARTITION x1 VALUES IN (1) ENGINE = MEMORY)
|
||||
drop table t1;
|
||||
CREATE TABLE t1 (a int, unique(a))
|
||||
|
@ -208,7 +208,7 @@ PARTITIONS 5;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) default NULL
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (a) PARTITIONS 5
|
||||
drop table t1;
|
||||
CREATE TABLE t1 (a int)
|
||||
|
@ -247,7 +247,7 @@ alter table t1 reorganize partition p2 into (partition p2 values less than (30))
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) default NULL
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (a) (PARTITION p0 VALUES LESS THAN (10) ENGINE = MyISAM, PARTITION p1 VALUES LESS THAN (20) ENGINE = MyISAM, PARTITION p2 VALUES LESS THAN (30) ENGINE = MyISAM)
|
||||
drop table t1;
|
||||
CREATE TABLE t1 (a int, b int)
|
||||
|
@ -267,8 +267,8 @@ ALTER TABLE t1 REORGANIZE PARTITION x0,x1,x2 INTO
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) default NULL,
|
||||
`b` int(11) default NULL
|
||||
`a` int(11) DEFAULT NULL,
|
||||
`b` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (a) (PARTITION x1 VALUES LESS THAN (6) ENGINE = MyISAM, PARTITION x3 VALUES LESS THAN (8) ENGINE = MyISAM, PARTITION x4 VALUES LESS THAN (10) ENGINE = MyISAM, PARTITION x5 VALUES LESS THAN (12) ENGINE = MyISAM, PARTITION x6 VALUES LESS THAN (14) ENGINE = MyISAM, PARTITION x7 VALUES LESS THAN (16) ENGINE = MyISAM, PARTITION x8 VALUES LESS THAN (18) ENGINE = MyISAM, PARTITION x9 VALUES LESS THAN (20) ENGINE = MyISAM)
|
||||
drop table t1;
|
||||
create table t1 (a int not null, b int not null) partition by LIST (a+b) (
|
||||
|
|
|
@ -39,8 +39,8 @@ CREATE TABLE t1 ( f1 INTEGER, f2 char(20)) ENGINE = 'MYISAM';
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -90,8 +90,8 @@ PARTITION BY HASH(f1) PARTITIONS 2;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) PARTITIONS 2
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -145,8 +145,8 @@ PARTITION part2 STORAGE ENGINE = 'MYISAM'
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM)
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -203,8 +203,8 @@ SUBPARTITION subpart22 STORAGE ENGINE = 'MYISAM')
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) (PARTITION part1 VALUES LESS THAN (100) (SUBPARTITION subpart11 ENGINE = MyISAM, SUBPARTITION subpart12 ENGINE = MyISAM), PARTITION part2 VALUES LESS THAN (2147483647) (SUBPARTITION subpart21 ENGINE = MyISAM, SUBPARTITION subpart22 ENGINE = MyISAM))
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -258,8 +258,8 @@ PARTITION part2
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM)
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -311,8 +311,8 @@ PARTITION part2 STORAGE ENGINE = 'MYISAM'
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM)
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -369,8 +369,8 @@ SUBPARTITION subpart22 STORAGE ENGINE = 'MYISAM')
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) (PARTITION part1 VALUES LESS THAN (100) (SUBPARTITION subpart11 ENGINE = MyISAM, SUBPARTITION subpart12 ENGINE = MyISAM), PARTITION part2 VALUES LESS THAN (2147483647) (SUBPARTITION subpart21 ENGINE = MyISAM, SUBPARTITION subpart22 ENGINE = MyISAM))
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -427,8 +427,8 @@ SUBPARTITION subpart22 )
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) (PARTITION part1 VALUES LESS THAN (100) (SUBPARTITION subpart11 ENGINE = MyISAM, SUBPARTITION subpart12 ENGINE = MyISAM), PARTITION part2 VALUES LESS THAN (2147483647) (SUBPARTITION subpart21 ENGINE = MyISAM, SUBPARTITION subpart22 ENGINE = MyISAM))
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -487,8 +487,8 @@ SUBPARTITION subpart22 STORAGE ENGINE = 'MYISAM')
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) (PARTITION part1 VALUES LESS THAN (100) (SUBPARTITION subpart11 ENGINE = MyISAM, SUBPARTITION subpart12 ENGINE = MyISAM), PARTITION part2 VALUES LESS THAN (2147483647) (SUBPARTITION subpart21 ENGINE = MyISAM, SUBPARTITION subpart22 ENGINE = MyISAM))
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -545,8 +545,8 @@ SUBPARTITION subpart22)
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) (PARTITION part1 VALUES LESS THAN (100) (SUBPARTITION subpart11 ENGINE = MyISAM, SUBPARTITION subpart12 ENGINE = MyISAM), PARTITION part2 VALUES LESS THAN (2147483647) (SUBPARTITION subpart21 ENGINE = MyISAM, SUBPARTITION subpart22 ENGINE = MyISAM))
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -601,8 +601,8 @@ PARTITION part2 STORAGE ENGINE = 'MYISAM'
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM)
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -659,8 +659,8 @@ SUBPARTITION subpart22 STORAGE ENGINE = 'MYISAM')
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) (PARTITION part1 VALUES LESS THAN (100) (SUBPARTITION subpart11 ENGINE = MyISAM, SUBPARTITION subpart12 ENGINE = MyISAM), PARTITION part2 VALUES LESS THAN (2147483647) (SUBPARTITION subpart21 ENGINE = MyISAM, SUBPARTITION subpart22 ENGINE = MyISAM))
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -719,8 +719,8 @@ SUBPARTITION subpart22 STORAGE ENGINE = 'MYISAM')
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) (PARTITION part1 VALUES LESS THAN (100) (SUBPARTITION subpart11 ENGINE = MyISAM, SUBPARTITION subpart12 ENGINE = MyISAM), PARTITION part2 VALUES LESS THAN (2147483647) (SUBPARTITION subpart21 ENGINE = MyISAM, SUBPARTITION subpart22 ENGINE = MyISAM))
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -780,8 +780,8 @@ PARTITION BY HASH(f1);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1)
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -831,8 +831,8 @@ PARTITION BY HASH(f1) (PARTITION part1, PARTITION part2);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM)
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -889,8 +889,8 @@ PARTITION BY RANGE(f1) SUBPARTITION BY HASH(f1) (PARTITION part1 VALUES LESS THA
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) (PARTITION part1 VALUES LESS THAN (100) (SUBPARTITION subpart11 ENGINE = MyISAM, SUBPARTITION subpart12 ENGINE = MyISAM), PARTITION part2 VALUES LESS THAN (200) (SUBPARTITION subpart21 ENGINE = MyISAM, SUBPARTITION subpart22 ENGINE = MyISAM), PARTITION part3 VALUES LESS THAN (2147483647) (SUBPARTITION subpart31 ENGINE = MyISAM, SUBPARTITION subpart32 ENGINE = MyISAM))
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -942,8 +942,8 @@ PARTITION BY HASH(f1) PARTITIONS 2;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) PARTITIONS 2
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -994,8 +994,8 @@ SUBPARTITIONS 2
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) SUBPARTITIONS 2 (PARTITION part1 VALUES LESS THAN (100) , PARTITION part2 VALUES LESS THAN (2147483647) )
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -1044,8 +1044,8 @@ PARTITION BY HASH(f1) PARTITIONS 1;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) PARTITIONS 1
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -1096,8 +1096,8 @@ SUBPARTITIONS 1
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) SUBPARTITIONS 1 (PARTITION part1 VALUES LESS THAN (100) , PARTITION part2 VALUES LESS THAN (2147483647) )
|
||||
SELECT COUNT(*) = 0 AS my_value FROM t1;
|
||||
my_value
|
||||
|
@ -1302,8 +1302,8 @@ PARTITION BY HASH(f1) PARTITIONS 2 ( PARTITION part1, PARTITION part2 ) ;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM)
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 ( f1 INTEGER, f2 char(20))
|
||||
|
@ -1317,8 +1317,8 @@ PARTITION part2 VALUES LESS THAN (2147483647)
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (f1) SUBPARTITION BY HASH (f1) (PARTITION part1 VALUES LESS THAN (1000) (SUBPARTITION subpart11 ENGINE = MyISAM, SUBPARTITION subpart12 ENGINE = MyISAM), PARTITION part2 VALUES LESS THAN (2147483647) (SUBPARTITION subpart21 ENGINE = MyISAM, SUBPARTITION subpart22 ENGINE = MyISAM))
|
||||
DROP TABLE t1;
|
||||
# 3.3.2 (positive) number of partition/subpartition ,
|
||||
|
@ -1426,16 +1426,16 @@ CREATE TABLE t1 ( f1 INTEGER, f2 char(20));
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
ALTER TABLE t1 ADD PARTITION (PARTITION part1);
|
||||
Got one of the listed errors
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
# 5.1.2 Add one partition to a table with one partition
|
||||
|
@ -1444,16 +1444,16 @@ PARTITION BY HASH(f1);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1)
|
||||
INSERT INTO t1 SELECT * FROM t0_template WHERE f1 BETWEEN 1 AND 100 - 1;
|
||||
ALTER TABLE t1 ADD PARTITION (PARTITION part1);
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION p0 ENGINE = MyISAM, PARTITION part1 ENGINE = MyISAM)
|
||||
INSERT INTO t1 SELECT * FROM t0_template WHERE f1 BETWEEN 100 AND 200;
|
||||
SELECT (COUNT(*) = 200) AND (MIN(f1) = 1) AND (MAX(f1) = 200)
|
||||
|
@ -1500,16 +1500,16 @@ PARTITION BY HASH(f1) (PARTITION part1, PARTITION part3);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part3 ENGINE = MyISAM)
|
||||
INSERT INTO t1 SELECT * FROM t0_template WHERE f1 BETWEEN 1 AND 100 - 1;
|
||||
ALTER TABLE t1 ADD PARTITION (PARTITION part0);
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part3 ENGINE = MyISAM, PARTITION part0 ENGINE = MyISAM)
|
||||
INSERT INTO t1 SELECT * FROM t0_template WHERE f1 BETWEEN 100 AND 200;
|
||||
SELECT (COUNT(*) = 200) AND (MIN(f1) = 1) AND (MAX(f1) = 200)
|
||||
|
@ -1555,8 +1555,8 @@ ALTER TABLE t1 ADD PARTITION (PARTITION part2);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part3 ENGINE = MyISAM, PARTITION part0 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM)
|
||||
INSERT INTO t1 SELECT * FROM t0_template WHERE f1 BETWEEN 100 AND 200;
|
||||
SELECT (COUNT(*) = 200) AND (MIN(f1) = 1) AND (MAX(f1) = 200)
|
||||
|
@ -1601,8 +1601,8 @@ INSERT INTO t1 SELECT * FROM t0_template WHERE f1 BETWEEN 1 AND 100 - 1;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part3 ENGINE = MyISAM, PARTITION part0 ENGINE = MyISAM, PARTITION part2 ENGINE = MyISAM)
|
||||
INSERT INTO t1 SELECT * FROM t0_template WHERE f1 BETWEEN 100 AND 200;
|
||||
SELECT (COUNT(*) = 200) AND (MIN(f1) = 1) AND (MAX(f1) = 200)
|
||||
|
@ -1649,15 +1649,15 @@ PARTITION BY HASH(f1) (PARTITION part1, PARTITION part3);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part3 ENGINE = MyISAM)
|
||||
INSERT INTO t1 SELECT * FROM t0_template WHERE f1 BETWEEN 1 AND 100 - 1;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) default NULL,
|
||||
`f2` char(20) default NULL
|
||||
`f1` int(11) DEFAULT NULL,
|
||||
`f2` char(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY HASH (f1) (PARTITION part1 ENGINE = MyISAM, PARTITION part3 ENGINE = MyISAM)
|
||||
INSERT INTO t1 SELECT * FROM t0_template WHERE f1 BETWEEN 100 AND 200;
|
||||
SELECT (COUNT(*) = 200) AND (MIN(f1) = 1) AND (MAX(f1) = 200)
|
||||
|
|
|
@ -129,13 +129,13 @@ CREATE TABLE t1 (a INT);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) default NULL
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
ALTER TABLE t1 PARTITION BY KEY(a) PARTITIONS 2;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) default NULL
|
||||
`a` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY KEY (a) PARTITIONS 2
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE t1 (a INT) PARTITION BY HASH(a);
|
||||
|
|
|
@ -151,7 +151,7 @@ t1 CREATE TABLE `t1` (
|
|||
`a` int(11) NOT NULL,
|
||||
`b` int(11) NOT NULL,
|
||||
`c` int(11) NOT NULL,
|
||||
`d` int(11) default NULL,
|
||||
`d` int(11) DEFAULT NULL,
|
||||
PRIMARY KEY (`a`,`b`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 PARTITION BY RANGE (a) SUBPARTITION BY HASH (a+b) (PARTITION x1 VALUES LESS THAN (1) (SUBPARTITION x11 ENGINE = MyISAM, SUBPARTITION x12 ENGINE = MyISAM), PARTITION x2 VALUES LESS THAN (5) (SUBPARTITION x21 ENGINE = MyISAM, SUBPARTITION x22 ENGINE = MyISAM))
|
||||
drop table t1;
|
||||
|
|
|
@ -1775,31 +1775,31 @@ NULL as const12, @arg12 as param12,
|
|||
show create table t5 ;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`const01` bigint(1) NOT NULL default '0',
|
||||
`param01` bigint(20) default NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL default '0.0',
|
||||
`param02` decimal(65,30) default NULL,
|
||||
`const03` double NOT NULL default '0',
|
||||
`param03` double default NULL,
|
||||
`const04` varchar(3) NOT NULL default '',
|
||||
`const01` bigint(1) NOT NULL DEFAULT '0',
|
||||
`param01` bigint(20) DEFAULT NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL DEFAULT '0.0',
|
||||
`param02` decimal(65,30) DEFAULT NULL,
|
||||
`const03` double NOT NULL DEFAULT '0',
|
||||
`param03` double DEFAULT NULL,
|
||||
`const04` varchar(3) NOT NULL DEFAULT '',
|
||||
`param04` longtext,
|
||||
`const05` varbinary(3) NOT NULL default '',
|
||||
`const05` varbinary(3) NOT NULL DEFAULT '',
|
||||
`param05` longblob,
|
||||
`const06` varchar(10) NOT NULL default '',
|
||||
`const06` varchar(10) NOT NULL DEFAULT '',
|
||||
`param06` longtext,
|
||||
`const07` date default NULL,
|
||||
`const07` date DEFAULT NULL,
|
||||
`param07` longblob,
|
||||
`const08` varchar(19) NOT NULL default '',
|
||||
`const08` varchar(19) NOT NULL DEFAULT '',
|
||||
`param08` longtext,
|
||||
`const09` datetime default NULL,
|
||||
`const09` datetime DEFAULT NULL,
|
||||
`param09` longblob,
|
||||
`const10` int(10) NOT NULL default '0',
|
||||
`param10` bigint(20) default NULL,
|
||||
`const11` int(4) default NULL,
|
||||
`param11` bigint(20) default NULL,
|
||||
`const12` binary(0) default NULL,
|
||||
`param12` bigint(20) default NULL,
|
||||
`param13` decimal(65,30) default NULL,
|
||||
`const10` int(10) NOT NULL DEFAULT '0',
|
||||
`param10` bigint(20) DEFAULT NULL,
|
||||
`const11` int(4) DEFAULT NULL,
|
||||
`param11` bigint(20) DEFAULT NULL,
|
||||
`const12` binary(0) DEFAULT NULL,
|
||||
`param12` bigint(20) DEFAULT NULL,
|
||||
`param13` decimal(65,30) DEFAULT NULL,
|
||||
`param14` longtext,
|
||||
`param15` longblob
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
|
|
@ -1758,31 +1758,31 @@ NULL as const12, @arg12 as param12,
|
|||
show create table t5 ;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`const01` bigint(1) NOT NULL default '0',
|
||||
`param01` bigint(20) default NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL default '0.0',
|
||||
`param02` decimal(65,30) default NULL,
|
||||
`const03` double NOT NULL default '0',
|
||||
`param03` double default NULL,
|
||||
`const04` varchar(3) NOT NULL default '',
|
||||
`const01` bigint(1) NOT NULL DEFAULT '0',
|
||||
`param01` bigint(20) DEFAULT NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL DEFAULT '0.0',
|
||||
`param02` decimal(65,30) DEFAULT NULL,
|
||||
`const03` double NOT NULL DEFAULT '0',
|
||||
`param03` double DEFAULT NULL,
|
||||
`const04` varchar(3) NOT NULL DEFAULT '',
|
||||
`param04` longtext,
|
||||
`const05` varbinary(3) NOT NULL default '',
|
||||
`const05` varbinary(3) NOT NULL DEFAULT '',
|
||||
`param05` longblob,
|
||||
`const06` varchar(10) NOT NULL default '',
|
||||
`const06` varchar(10) NOT NULL DEFAULT '',
|
||||
`param06` longtext,
|
||||
`const07` date default NULL,
|
||||
`const07` date DEFAULT NULL,
|
||||
`param07` longblob,
|
||||
`const08` varchar(19) NOT NULL default '',
|
||||
`const08` varchar(19) NOT NULL DEFAULT '',
|
||||
`param08` longtext,
|
||||
`const09` datetime default NULL,
|
||||
`const09` datetime DEFAULT NULL,
|
||||
`param09` longblob,
|
||||
`const10` int(10) NOT NULL default '0',
|
||||
`param10` bigint(20) default NULL,
|
||||
`const11` int(4) default NULL,
|
||||
`param11` bigint(20) default NULL,
|
||||
`const12` binary(0) default NULL,
|
||||
`param12` bigint(20) default NULL,
|
||||
`param13` decimal(65,30) default NULL,
|
||||
`const10` int(10) NOT NULL DEFAULT '0',
|
||||
`param10` bigint(20) DEFAULT NULL,
|
||||
`const11` int(4) DEFAULT NULL,
|
||||
`param11` bigint(20) DEFAULT NULL,
|
||||
`const12` binary(0) DEFAULT NULL,
|
||||
`param12` bigint(20) DEFAULT NULL,
|
||||
`param13` decimal(65,30) DEFAULT NULL,
|
||||
`param14` longtext,
|
||||
`param15` longblob
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
|
|
@ -1759,31 +1759,31 @@ NULL as const12, @arg12 as param12,
|
|||
show create table t5 ;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`const01` bigint(1) NOT NULL default '0',
|
||||
`param01` bigint(20) default NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL default '0.0',
|
||||
`param02` decimal(65,30) default NULL,
|
||||
`const03` double NOT NULL default '0',
|
||||
`param03` double default NULL,
|
||||
`const04` varchar(3) NOT NULL default '',
|
||||
`const01` bigint(1) NOT NULL DEFAULT '0',
|
||||
`param01` bigint(20) DEFAULT NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL DEFAULT '0.0',
|
||||
`param02` decimal(65,30) DEFAULT NULL,
|
||||
`const03` double NOT NULL DEFAULT '0',
|
||||
`param03` double DEFAULT NULL,
|
||||
`const04` varchar(3) NOT NULL DEFAULT '',
|
||||
`param04` longtext,
|
||||
`const05` varbinary(3) NOT NULL default '',
|
||||
`const05` varbinary(3) NOT NULL DEFAULT '',
|
||||
`param05` longblob,
|
||||
`const06` varchar(10) NOT NULL default '',
|
||||
`const06` varchar(10) NOT NULL DEFAULT '',
|
||||
`param06` longtext,
|
||||
`const07` date default NULL,
|
||||
`const07` date DEFAULT NULL,
|
||||
`param07` longblob,
|
||||
`const08` varchar(19) NOT NULL default '',
|
||||
`const08` varchar(19) NOT NULL DEFAULT '',
|
||||
`param08` longtext,
|
||||
`const09` datetime default NULL,
|
||||
`const09` datetime DEFAULT NULL,
|
||||
`param09` longblob,
|
||||
`const10` int(10) NOT NULL default '0',
|
||||
`param10` bigint(20) default NULL,
|
||||
`const11` int(4) default NULL,
|
||||
`param11` bigint(20) default NULL,
|
||||
`const12` binary(0) default NULL,
|
||||
`param12` bigint(20) default NULL,
|
||||
`param13` decimal(65,30) default NULL,
|
||||
`const10` int(10) NOT NULL DEFAULT '0',
|
||||
`param10` bigint(20) DEFAULT NULL,
|
||||
`const11` int(4) DEFAULT NULL,
|
||||
`param11` bigint(20) DEFAULT NULL,
|
||||
`const12` binary(0) DEFAULT NULL,
|
||||
`param12` bigint(20) DEFAULT NULL,
|
||||
`param13` decimal(65,30) DEFAULT NULL,
|
||||
`param14` longtext,
|
||||
`param15` longblob
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
|
|
@ -1695,31 +1695,31 @@ NULL as const12, @arg12 as param12,
|
|||
show create table t5 ;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`const01` bigint(1) NOT NULL default '0',
|
||||
`param01` bigint(20) default NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL default '0.0',
|
||||
`param02` decimal(65,30) default NULL,
|
||||
`const03` double NOT NULL default '0',
|
||||
`param03` double default NULL,
|
||||
`const04` varchar(3) NOT NULL default '',
|
||||
`const01` bigint(1) NOT NULL DEFAULT '0',
|
||||
`param01` bigint(20) DEFAULT NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL DEFAULT '0.0',
|
||||
`param02` decimal(65,30) DEFAULT NULL,
|
||||
`const03` double NOT NULL DEFAULT '0',
|
||||
`param03` double DEFAULT NULL,
|
||||
`const04` varchar(3) NOT NULL DEFAULT '',
|
||||
`param04` longtext,
|
||||
`const05` varbinary(3) NOT NULL default '',
|
||||
`const05` varbinary(3) NOT NULL DEFAULT '',
|
||||
`param05` longblob,
|
||||
`const06` varchar(10) NOT NULL default '',
|
||||
`const06` varchar(10) NOT NULL DEFAULT '',
|
||||
`param06` longtext,
|
||||
`const07` date default NULL,
|
||||
`const07` date DEFAULT NULL,
|
||||
`param07` longblob,
|
||||
`const08` varchar(19) NOT NULL default '',
|
||||
`const08` varchar(19) NOT NULL DEFAULT '',
|
||||
`param08` longtext,
|
||||
`const09` datetime default NULL,
|
||||
`const09` datetime DEFAULT NULL,
|
||||
`param09` longblob,
|
||||
`const10` int(10) NOT NULL default '0',
|
||||
`param10` bigint(20) default NULL,
|
||||
`const11` int(4) default NULL,
|
||||
`param11` bigint(20) default NULL,
|
||||
`const12` binary(0) default NULL,
|
||||
`param12` bigint(20) default NULL,
|
||||
`param13` decimal(65,30) default NULL,
|
||||
`const10` int(10) NOT NULL DEFAULT '0',
|
||||
`param10` bigint(20) DEFAULT NULL,
|
||||
`const11` int(4) DEFAULT NULL,
|
||||
`param11` bigint(20) DEFAULT NULL,
|
||||
`const12` binary(0) DEFAULT NULL,
|
||||
`param12` bigint(20) DEFAULT NULL,
|
||||
`param13` decimal(65,30) DEFAULT NULL,
|
||||
`param14` longtext,
|
||||
`param15` longblob
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
@ -4709,31 +4709,31 @@ NULL as const12, @arg12 as param12,
|
|||
show create table t5 ;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`const01` bigint(1) NOT NULL default '0',
|
||||
`param01` bigint(20) default NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL default '0.0',
|
||||
`param02` decimal(65,30) default NULL,
|
||||
`const03` double NOT NULL default '0',
|
||||
`param03` double default NULL,
|
||||
`const04` varchar(3) NOT NULL default '',
|
||||
`const01` bigint(1) NOT NULL DEFAULT '0',
|
||||
`param01` bigint(20) DEFAULT NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL DEFAULT '0.0',
|
||||
`param02` decimal(65,30) DEFAULT NULL,
|
||||
`const03` double NOT NULL DEFAULT '0',
|
||||
`param03` double DEFAULT NULL,
|
||||
`const04` varchar(3) NOT NULL DEFAULT '',
|
||||
`param04` longtext,
|
||||
`const05` varbinary(3) NOT NULL default '',
|
||||
`const05` varbinary(3) NOT NULL DEFAULT '',
|
||||
`param05` longblob,
|
||||
`const06` varchar(10) NOT NULL default '',
|
||||
`const06` varchar(10) NOT NULL DEFAULT '',
|
||||
`param06` longtext,
|
||||
`const07` date default NULL,
|
||||
`const07` date DEFAULT NULL,
|
||||
`param07` longblob,
|
||||
`const08` varchar(19) NOT NULL default '',
|
||||
`const08` varchar(19) NOT NULL DEFAULT '',
|
||||
`param08` longtext,
|
||||
`const09` datetime default NULL,
|
||||
`const09` datetime DEFAULT NULL,
|
||||
`param09` longblob,
|
||||
`const10` int(10) NOT NULL default '0',
|
||||
`param10` bigint(20) default NULL,
|
||||
`const11` int(4) default NULL,
|
||||
`param11` bigint(20) default NULL,
|
||||
`const12` binary(0) default NULL,
|
||||
`param12` bigint(20) default NULL,
|
||||
`param13` decimal(65,30) default NULL,
|
||||
`const10` int(10) NOT NULL DEFAULT '0',
|
||||
`param10` bigint(20) DEFAULT NULL,
|
||||
`const11` int(4) DEFAULT NULL,
|
||||
`param11` bigint(20) DEFAULT NULL,
|
||||
`const12` binary(0) DEFAULT NULL,
|
||||
`param12` bigint(20) DEFAULT NULL,
|
||||
`param13` decimal(65,30) DEFAULT NULL,
|
||||
`param14` longtext,
|
||||
`param15` longblob
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
|
|
@ -1758,31 +1758,31 @@ NULL as const12, @arg12 as param12,
|
|||
show create table t5 ;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`const01` bigint(1) NOT NULL default '0',
|
||||
`param01` bigint(20) default NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL default '0.0',
|
||||
`param02` decimal(65,30) default NULL,
|
||||
`const03` double NOT NULL default '0',
|
||||
`param03` double default NULL,
|
||||
`const04` varchar(3) NOT NULL default '',
|
||||
`const01` bigint(1) NOT NULL DEFAULT '0',
|
||||
`param01` bigint(20) DEFAULT NULL,
|
||||
`const02` decimal(2,1) unsigned NOT NULL DEFAULT '0.0',
|
||||
`param02` decimal(65,30) DEFAULT NULL,
|
||||
`const03` double NOT NULL DEFAULT '0',
|
||||
`param03` double DEFAULT NULL,
|
||||
`const04` varchar(3) NOT NULL DEFAULT '',
|
||||
`param04` longtext,
|
||||
`const05` varbinary(3) NOT NULL default '',
|
||||
`const05` varbinary(3) NOT NULL DEFAULT '',
|
||||
`param05` longblob,
|
||||
`const06` varchar(10) NOT NULL default '',
|
||||
`const06` varchar(10) NOT NULL DEFAULT '',
|
||||
`param06` longtext,
|
||||
`const07` date default NULL,
|
||||
`const07` date DEFAULT NULL,
|
||||
`param07` longblob,
|
||||
`const08` varchar(19) NOT NULL default '',
|
||||
`const08` varchar(19) NOT NULL DEFAULT '',
|
||||
`param08` longtext,
|
||||
`const09` datetime default NULL,
|
||||
`const09` datetime DEFAULT NULL,
|
||||
`param09` longblob,
|
||||
`const10` int(10) NOT NULL default '0',
|
||||
`param10` bigint(20) default NULL,
|
||||
`const11` int(4) default NULL,
|
||||
`param11` bigint(20) default NULL,
|
||||
`const12` binary(0) default NULL,
|
||||
`param12` bigint(20) default NULL,
|
||||
`param13` decimal(65,30) default NULL,
|
||||
`const10` int(10) NOT NULL DEFAULT '0',
|
||||
`param10` bigint(20) DEFAULT NULL,
|
||||
`const11` int(4) DEFAULT NULL,
|
||||
`param11` bigint(20) DEFAULT NULL,
|
||||
`const12` binary(0) DEFAULT NULL,
|
||||
`param12` bigint(20) DEFAULT NULL,
|
||||
`param13` decimal(65,30) DEFAULT NULL,
|
||||
`param14` longtext,
|
||||
`param15` longblob
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
|
|
@ -33,14 +33,14 @@ id created
|
|||
show create table t3;
|
||||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`id` int(11) NOT NULL auto_increment,
|
||||
`created` datetime default NULL,
|
||||
`id` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`created` datetime DEFAULT NULL,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show create table t5;
|
||||
Table Create Table
|
||||
t5 CREATE TABLE `t5` (
|
||||
`id` int(11) NOT NULL default '0',
|
||||
`created` datetime default NULL
|
||||
`id` int(11) NOT NULL DEFAULT '0',
|
||||
`created` datetime DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t2,t3,t5;
|
||||
|
|
|
@ -16,14 +16,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 engine=myisam;
|
||||
|
@ -31,14 +31,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ', 'Must make it bug free for the customer',654321.4321,15.21,0,1965,"2005-11-14");
|
||||
|
@ -65,14 +65,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ', 'Must make it bug free for the customer',654321.4321,15.21,0,1965,"2005-11-14");
|
||||
|
@ -99,14 +99,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ', 'Must make it bug free for the customer',654321.4321,15.21,0,1965,"2005-11-14");
|
||||
|
@ -133,14 +133,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
alter table t1 engine=myisam;
|
||||
|
@ -148,14 +148,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ', 'Must make it bug free for the customer',654321.4321,15.21,0,1965,"2005-11-14");
|
||||
|
@ -182,14 +182,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ', 'Must make it bug free for the customer',654321.4321,15.21,0,1965,"2005-11-14");
|
||||
|
@ -216,14 +216,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ', 'Must make it bug free for the customer',654321.4321,15.21,0,1965,"2005-11-14");
|
||||
|
@ -250,14 +250,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
alter table t1 engine=myisam;
|
||||
|
@ -265,14 +265,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ', 'Must make it bug free for the customer',654321.4321,15.21,0,1965,"2005-11-14");
|
||||
|
@ -299,14 +299,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ', 'Must make it bug free for the customer',654321.4321,15.21,0,1965,"2005-11-14");
|
||||
|
@ -333,14 +333,14 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` mediumint(9) NOT NULL,
|
||||
`b1` bit(8) default NULL,
|
||||
`vc` varchar(255) default NULL,
|
||||
`bc` char(255) default NULL,
|
||||
`d` decimal(10,4) default '0.0000',
|
||||
`f` float default '0',
|
||||
`total` bigint(20) unsigned default NULL,
|
||||
`y` year(4) default NULL,
|
||||
`t` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b1` bit(8) DEFAULT NULL,
|
||||
`vc` varchar(255) DEFAULT NULL,
|
||||
`bc` char(255) DEFAULT NULL,
|
||||
`d` decimal(10,4) DEFAULT '0.0000',
|
||||
`f` float DEFAULT '0',
|
||||
`total` bigint(20) unsigned DEFAULT NULL,
|
||||
`y` year(4) DEFAULT NULL,
|
||||
`t` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 VALUES(42,1,'Testing MySQL databases is a cool ', 'Must make it bug free for the customer',654321.4321,15.21,0,1965,"2005-11-14");
|
||||
|
|
|
@ -29,9 +29,9 @@ insert into t2 values(fn1(2));
|
|||
SHOW CREATE TABLE test.t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL default '0',
|
||||
`a` int(11) NOT NULL DEFAULT '0',
|
||||
`blob_column` longblob,
|
||||
`vchar_column` varchar(100) default NULL,
|
||||
`vchar_column` varchar(100) DEFAULT NULL,
|
||||
PRIMARY KEY (`a`)
|
||||
) ENGINE=ndbcluster DEFAULT CHARSET=latin1 PARTITION BY KEY ()
|
||||
DROP PROCEDURE test.p1;
|
||||
|
|
|
@ -103,21 +103,21 @@ c int not null comment 'int column',
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`test_set` set('val1','val2','val3') NOT NULL default '',
|
||||
`name` char(20) default 'O''Brien' COMMENT 'O''Brien as default',
|
||||
`test_set` set('val1','val2','val3') NOT NULL DEFAULT '',
|
||||
`name` char(20) DEFAULT 'O''Brien' COMMENT 'O''Brien as default',
|
||||
`c` int(11) NOT NULL COMMENT 'int column',
|
||||
`c-b` int(11) default NULL COMMENT 'name with a minus',
|
||||
`space 2` int(11) default NULL COMMENT 'name with a space'
|
||||
`c-b` int(11) DEFAULT NULL COMMENT 'name with a minus',
|
||||
`space 2` int(11) DEFAULT NULL COMMENT 'name with a space'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='it''s a table'
|
||||
set sql_quote_show_create=0;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE t1 (
|
||||
test_set set('val1','val2','val3') NOT NULL default '',
|
||||
`name` char(20) default 'O''Brien' COMMENT 'O''Brien as default',
|
||||
test_set set('val1','val2','val3') NOT NULL DEFAULT '',
|
||||
`name` char(20) DEFAULT 'O''Brien' COMMENT 'O''Brien as default',
|
||||
c int(11) NOT NULL COMMENT 'int column',
|
||||
`c-b` int(11) default NULL COMMENT 'name with a minus',
|
||||
`space 2` int(11) default NULL COMMENT 'name with a space'
|
||||
`c-b` int(11) DEFAULT NULL COMMENT 'name with a minus',
|
||||
`space 2` int(11) DEFAULT NULL COMMENT 'name with a space'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='it''s a table'
|
||||
set sql_quote_show_create=1;
|
||||
show full columns from t1;
|
||||
|
@ -162,7 +162,7 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` varchar(10) default NULL,
|
||||
`b` varchar(10) DEFAULT NULL,
|
||||
KEY `b` (`b`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 MIN_ROWS=10 MAX_ROWS=100 AVG_ROW_LENGTH=10 PACK_KEYS=1 CHECKSUM=1 DELAY_KEY_WRITE=1 ROW_FORMAT=FIXED COMMENT='test'
|
||||
alter table t1 MAX_ROWS=200 ROW_FORMAT=dynamic PACK_KEYS=0;
|
||||
|
@ -170,7 +170,7 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` varchar(10) default NULL,
|
||||
`b` varchar(10) DEFAULT NULL,
|
||||
KEY `b` (`b`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 MIN_ROWS=10 MAX_ROWS=200 AVG_ROW_LENGTH=10 PACK_KEYS=0 CHECKSUM=1 DELAY_KEY_WRITE=1 ROW_FORMAT=DYNAMIC COMMENT='test'
|
||||
ALTER TABLE t1 AVG_ROW_LENGTH=0 CHECKSUM=0 COMMENT="" MIN_ROWS=0 MAX_ROWS=0 PACK_KEYS=DEFAULT DELAY_KEY_WRITE=0 ROW_FORMAT=default;
|
||||
|
@ -178,7 +178,7 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` varchar(10) default NULL,
|
||||
`b` varchar(10) DEFAULT NULL,
|
||||
KEY `b` (`b`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
@ -227,23 +227,23 @@ index(type_short)
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`type_bool` tinyint(1) NOT NULL default '0',
|
||||
`type_tiny` tinyint(4) NOT NULL auto_increment,
|
||||
`type_short` smallint(3) default NULL,
|
||||
`type_mediumint` mediumint(9) default NULL,
|
||||
`type_bigint` bigint(20) default NULL,
|
||||
`type_decimal` decimal(5,2) default NULL,
|
||||
`type_numeric` decimal(5,2) default NULL,
|
||||
`empty_char` char(0) default NULL,
|
||||
`type_char` char(2) default NULL,
|
||||
`type_varchar` varchar(10) default NULL,
|
||||
`type_timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`type_date` date NOT NULL default '0000-00-00',
|
||||
`type_time` time NOT NULL default '00:00:00',
|
||||
`type_datetime` datetime NOT NULL default '0000-00-00 00:00:00',
|
||||
`type_year` year(4) default NULL,
|
||||
`type_enum` enum('red','green','blue') default NULL,
|
||||
`type_set` enum('red','green','blue') default NULL,
|
||||
`type_bool` tinyint(1) NOT NULL DEFAULT '0',
|
||||
`type_tiny` tinyint(4) NOT NULL AUTO_INCREMENT,
|
||||
`type_short` smallint(3) DEFAULT NULL,
|
||||
`type_mediumint` mediumint(9) DEFAULT NULL,
|
||||
`type_bigint` bigint(20) DEFAULT NULL,
|
||||
`type_decimal` decimal(5,2) DEFAULT NULL,
|
||||
`type_numeric` decimal(5,2) DEFAULT NULL,
|
||||
`empty_char` char(0) DEFAULT NULL,
|
||||
`type_char` char(2) DEFAULT NULL,
|
||||
`type_varchar` varchar(10) DEFAULT NULL,
|
||||
`type_timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`type_date` date NOT NULL DEFAULT '0000-00-00',
|
||||
`type_time` time NOT NULL DEFAULT '00:00:00',
|
||||
`type_datetime` datetime NOT NULL DEFAULT '0000-00-00 00:00:00',
|
||||
`type_year` year(4) DEFAULT NULL,
|
||||
`type_enum` enum('red','green','blue') DEFAULT NULL,
|
||||
`type_set` enum('red','green','blue') DEFAULT NULL,
|
||||
`type_tinyblob` tinyblob,
|
||||
`type_blob` blob,
|
||||
`type_medium_blob` mediumblob,
|
||||
|
@ -283,28 +283,28 @@ CREATE TABLE ```ab``cd``` (i INT);
|
|||
SHOW CREATE TABLE ```ab``cd```;
|
||||
Table Create Table
|
||||
`ab`cd` CREATE TABLE ```ab``cd``` (
|
||||
i int(11) default NULL
|
||||
i int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE ```ab``cd```;
|
||||
CREATE TABLE ```ab````cd``` (i INT);
|
||||
SHOW CREATE TABLE ```ab````cd```;
|
||||
Table Create Table
|
||||
`ab``cd` CREATE TABLE ```ab````cd``` (
|
||||
i int(11) default NULL
|
||||
i int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE ```ab````cd```;
|
||||
CREATE TABLE ```a` (i INT);
|
||||
SHOW CREATE TABLE ```a`;
|
||||
Table Create Table
|
||||
`a CREATE TABLE ```a` (
|
||||
i int(11) default NULL
|
||||
i int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE ```a`;
|
||||
CREATE TABLE `a.1` (i INT);
|
||||
SHOW CREATE TABLE `a.1`;
|
||||
Table Create Table
|
||||
a.1 CREATE TABLE `a.1` (
|
||||
i int(11) default NULL
|
||||
i int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE `a.1`;
|
||||
SET sql_mode= 'ANSI_QUOTES';
|
||||
|
@ -312,7 +312,7 @@ CREATE TABLE """a" (i INT);
|
|||
SHOW CREATE TABLE """a";
|
||||
Table Create Table
|
||||
"a CREATE TABLE """a" (
|
||||
i int(11) default NULL
|
||||
i int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE """a";
|
||||
SET sql_mode= '';
|
||||
|
@ -321,14 +321,14 @@ CREATE TABLE t1 (i INT);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE t1 (
|
||||
i int(11) default NULL
|
||||
i int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
CREATE TABLE `table` (i INT);
|
||||
SHOW CREATE TABLE `table`;
|
||||
Table Create Table
|
||||
table CREATE TABLE `table` (
|
||||
i int(11) default NULL
|
||||
i int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE `table`;
|
||||
SET sql_quote_show_create= @old_sql_quote_show_create;
|
||||
|
@ -451,7 +451,7 @@ CREATE TABLE t1 (i int, KEY (i)) ENGINE=MEMORY;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL,
|
||||
`i` int(11) DEFAULT NULL,
|
||||
KEY `i` (`i`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
@ -459,7 +459,7 @@ CREATE TABLE t1 (i int, KEY USING HASH (i)) ENGINE=MEMORY;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL,
|
||||
`i` int(11) DEFAULT NULL,
|
||||
KEY `i` USING HASH (`i`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
@ -467,7 +467,7 @@ CREATE TABLE t1 (i int, KEY USING BTREE (i)) ENGINE=MEMORY;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL,
|
||||
`i` int(11) DEFAULT NULL,
|
||||
KEY `i` USING BTREE (`i`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
@ -475,7 +475,7 @@ CREATE TABLE t1 (i int, KEY (i)) ENGINE=MyISAM;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL,
|
||||
`i` int(11) DEFAULT NULL,
|
||||
KEY `i` (`i`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
@ -483,7 +483,7 @@ CREATE TABLE t1 (i int, KEY USING BTREE (i)) ENGINE=MyISAM;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL,
|
||||
`i` int(11) DEFAULT NULL,
|
||||
KEY `i` USING BTREE (`i`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
@ -491,14 +491,14 @@ CREATE TABLE t1 (i int, KEY (i)) ENGINE=MyISAM;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL,
|
||||
`i` int(11) DEFAULT NULL,
|
||||
KEY `i` (`i`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
ALTER TABLE t1 ENGINE=MEMORY;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL,
|
||||
`i` int(11) DEFAULT NULL,
|
||||
KEY `i` (`i`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
@ -506,14 +506,14 @@ CREATE TABLE t1 (i int, KEY USING BTREE (i)) ENGINE=MyISAM;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL,
|
||||
`i` int(11) DEFAULT NULL,
|
||||
KEY `i` USING BTREE (`i`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
ALTER TABLE t1 ENGINE=MEMORY;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL,
|
||||
`i` int(11) DEFAULT NULL,
|
||||
KEY `i` USING BTREE (`i`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
DROP TABLE t1;
|
||||
|
|
|
@ -667,12 +667,12 @@ END|
|
|||
CALL p1(NOW());
|
||||
Table Create Table
|
||||
t1 CREATE TABLE "t1" (
|
||||
"x" varbinary(19) default NULL
|
||||
"x" varbinary(19) DEFAULT NULL
|
||||
)
|
||||
CALL p1('test');
|
||||
Table Create Table
|
||||
t1 CREATE TABLE "t1" (
|
||||
"x" varbinary(19) default NULL
|
||||
"x" varbinary(19) DEFAULT NULL
|
||||
)
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'x' at row 1
|
||||
|
|
|
@ -2418,7 +2418,7 @@ create table t3 as select bug2773()|
|
|||
show create table t3|
|
||||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`bug2773()` int(11) default NULL
|
||||
`bug2773()` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t3|
|
||||
drop function bug2773|
|
||||
|
@ -2479,7 +2479,7 @@ tinyint 1 -128 127 0 0 YES YES NO YES YES NO NULL,0 A very small integer
|
|||
tinyint unsigned 1 0 255 0 0 YES YES YES YES YES NO NULL,0 A very small integer
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` char(16) NOT NULL default '',
|
||||
`id` char(16) NOT NULL DEFAULT '',
|
||||
`data` int(11) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
Database Create Database
|
||||
|
@ -2533,7 +2533,7 @@ tinyint 1 -128 127 0 0 YES YES NO YES YES NO NULL,0 A very small integer
|
|||
tinyint unsigned 1 0 255 0 0 YES YES YES YES YES NO NULL,0 A very small integer
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`id` char(16) NOT NULL default '',
|
||||
`id` char(16) NOT NULL DEFAULT '',
|
||||
`data` int(11) NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
Database Create Database
|
||||
|
@ -3852,7 +3852,7 @@ end|
|
|||
call bug12589_1()|
|
||||
Table Create Table
|
||||
tm1 CREATE TEMPORARY TABLE `tm1` (
|
||||
`spv1` decimal(3,3) default NULL
|
||||
`spv1` decimal(3,3) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
Warnings:
|
||||
Warning 1264 Out of range value for column 'spv1' at row 1
|
||||
|
@ -3860,12 +3860,12 @@ Warning 1366 Incorrect decimal value: 'test' for column 'spv1' at row 1
|
|||
call bug12589_2()|
|
||||
Table Create Table
|
||||
tm1 CREATE TEMPORARY TABLE `tm1` (
|
||||
`spv1` decimal(6,3) default NULL
|
||||
`spv1` decimal(6,3) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
call bug12589_3()|
|
||||
Table Create Table
|
||||
tm1 CREATE TEMPORARY TABLE `tm1` (
|
||||
`spv1` decimal(6,3) default NULL
|
||||
`spv1` decimal(6,3) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop procedure bug12589_1|
|
||||
drop procedure bug12589_2|
|
||||
|
|
|
@ -14,9 +14,9 @@ sql_mode
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL auto_increment,
|
||||
`pseudo` varchar(35) character set latin2 NOT NULL default '',
|
||||
`email` varchar(60) character set latin2 NOT NULL default '',
|
||||
`a` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`pseudo` varchar(35) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`email` varchar(60) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`a`),
|
||||
UNIQUE KEY `email` USING BTREE (`email`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
|
||||
|
@ -27,9 +27,9 @@ sql_mode ANSI_QUOTES
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE "t1" (
|
||||
"a" int(11) NOT NULL auto_increment,
|
||||
"pseudo" varchar(35) character set latin2 NOT NULL default '',
|
||||
"email" varchar(60) character set latin2 NOT NULL default '',
|
||||
"a" int(11) NOT NULL AUTO_INCREMENT,
|
||||
"pseudo" varchar(35) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
"email" varchar(60) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
PRIMARY KEY ("a"),
|
||||
UNIQUE KEY "email" USING BTREE ("email")
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
|
||||
|
@ -40,9 +40,9 @@ sql_mode NO_TABLE_OPTIONS
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL auto_increment,
|
||||
`pseudo` varchar(35) character set latin2 NOT NULL default '',
|
||||
`email` varchar(60) character set latin2 NOT NULL default '',
|
||||
`a` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`pseudo` varchar(35) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`email` varchar(60) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`a`),
|
||||
UNIQUE KEY `email` USING BTREE (`email`)
|
||||
)
|
||||
|
@ -53,9 +53,9 @@ sql_mode NO_KEY_OPTIONS
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL auto_increment,
|
||||
`pseudo` varchar(35) character set latin2 NOT NULL default '',
|
||||
`email` varchar(60) character set latin2 NOT NULL default '',
|
||||
`a` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`pseudo` varchar(35) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
`email` varchar(60) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`a`),
|
||||
UNIQUE KEY `email` (`email`)
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
|
||||
|
@ -67,8 +67,8 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL,
|
||||
`pseudo` varchar(35) NOT NULL default '',
|
||||
`email` varchar(60) NOT NULL default '',
|
||||
`pseudo` varchar(35) NOT NULL DEFAULT '',
|
||||
`email` varchar(60) NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`a`),
|
||||
UNIQUE KEY `email` (`email`)
|
||||
) TYPE=HEAP ROW_FORMAT=DYNAMIC
|
||||
|
@ -80,8 +80,8 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE "t1" (
|
||||
"a" int(11) NOT NULL,
|
||||
"pseudo" varchar(35) character set latin2 NOT NULL default '',
|
||||
"email" varchar(60) character set latin2 NOT NULL default '',
|
||||
"pseudo" varchar(35) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
"email" varchar(60) CHARACTER SET latin2 NOT NULL DEFAULT '',
|
||||
PRIMARY KEY ("a"),
|
||||
UNIQUE KEY "email" ("email")
|
||||
)
|
||||
|
@ -95,25 +95,25 @@ set @@sql_mode="";
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) default NULL,
|
||||
`b` char(10) character set latin1 collate latin1_bin default NULL,
|
||||
`c` binary(10) default NULL
|
||||
`a` char(10) DEFAULT NULL,
|
||||
`b` char(10) CHARACTER SET latin1 COLLATE latin1_bin DEFAULT NULL,
|
||||
`c` binary(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
set @@sql_mode="mysql323";
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) default NULL,
|
||||
`b` char(10) binary default NULL,
|
||||
`c` binary(10) default NULL
|
||||
`a` char(10) DEFAULT NULL,
|
||||
`b` char(10) binary DEFAULT NULL,
|
||||
`c` binary(10) DEFAULT NULL
|
||||
) TYPE=MyISAM
|
||||
set @@sql_mode="mysql40";
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` char(10) default NULL,
|
||||
`b` char(10) binary default NULL,
|
||||
`c` binary(10) default NULL
|
||||
`a` char(10) DEFAULT NULL,
|
||||
`b` char(10) binary DEFAULT NULL,
|
||||
`c` binary(10) DEFAULT NULL
|
||||
) TYPE=MyISAM
|
||||
drop table t1;
|
||||
set session sql_mode = '';
|
||||
|
@ -121,7 +121,7 @@ create table t1 ( min_num dec(6,6) default .000001);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`min_num` decimal(6,6) default '0.000001'
|
||||
`min_num` decimal(6,6) DEFAULT '0.000001'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1 ;
|
||||
set session sql_mode = 'IGNORE_SPACE';
|
||||
|
@ -129,14 +129,14 @@ create table t1 ( min_num dec(6,6) default 0.000001);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`min_num` decimal(6,6) default '0.000001'
|
||||
`min_num` decimal(6,6) DEFAULT '0.000001'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1 ;
|
||||
create table t1 ( min_num dec(6,6) default .000001);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`min_num` decimal(6,6) default '0.000001'
|
||||
`min_num` decimal(6,6) DEFAULT '0.000001'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1 ;
|
||||
set @@SQL_MODE=NULL;
|
||||
|
@ -148,8 +148,8 @@ f2 timestamp default current_timestamp on update current_timestamp);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE "t1" (
|
||||
"f1" int(11) NOT NULL auto_increment,
|
||||
"f2" timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
"f1" int(11) NOT NULL AUTO_INCREMENT,
|
||||
"f2" timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY ("f1")
|
||||
)
|
||||
set session sql_mode=no_field_options;
|
||||
|
@ -157,7 +157,7 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` int(11) NOT NULL,
|
||||
`f2` timestamp NOT NULL default CURRENT_TIMESTAMP,
|
||||
`f2` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`f1`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
|
|
@ -1009,7 +1009,7 @@ CREATE TABLE t1 (col1 INT NOT NULL default 99, col2 CHAR(6) NOT NULL);
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE "t1" (
|
||||
"col1" int(11) NOT NULL default '99',
|
||||
"col1" int(11) NOT NULL DEFAULT '99',
|
||||
"col2" char(6) NOT NULL
|
||||
)
|
||||
INSERT INTO t1 VALUES (1, 'hello');
|
||||
|
@ -1266,8 +1266,8 @@ alter table t1 add primary key(a);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL default '0',
|
||||
`b` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`a` int(11) NOT NULL DEFAULT '0',
|
||||
`b` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`a`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
@ -1276,8 +1276,8 @@ alter table t1 add primary key(a);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL default '0',
|
||||
`b` timestamp NOT NULL default '2005-01-02 03:04:05',
|
||||
`a` int(11) NOT NULL DEFAULT '0',
|
||||
`b` timestamp NOT NULL DEFAULT '2005-01-02 03:04:05',
|
||||
PRIMARY KEY (`a`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
|
|
@ -1087,24 +1087,24 @@ CREATE TABLE t1 SELECT * FROM (SELECT 1 as a,(SELECT 1)) a;
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bigint(1) NOT NULL default '0',
|
||||
`(SELECT 1)` bigint(1) NOT NULL default '0'
|
||||
`a` bigint(1) NOT NULL DEFAULT '0',
|
||||
`(SELECT 1)` bigint(1) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
CREATE TABLE t1 SELECT * FROM (SELECT 1 as a,(SELECT a)) a;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bigint(1) NOT NULL default '0',
|
||||
`(SELECT a)` bigint(1) NOT NULL default '0'
|
||||
`a` bigint(1) NOT NULL DEFAULT '0',
|
||||
`(SELECT a)` bigint(1) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
CREATE TABLE t1 SELECT * FROM (SELECT 1 as a,(SELECT a+0)) a;
|
||||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bigint(1) NOT NULL default '0',
|
||||
`(SELECT a+0)` bigint(3) NOT NULL default '0'
|
||||
`a` bigint(1) NOT NULL DEFAULT '0',
|
||||
`(SELECT a+0)` bigint(3) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
CREATE TABLE t1 SELECT (SELECT 1 as a UNION SELECT 1+1 limit 1,1) as a;
|
||||
|
@ -1114,7 +1114,7 @@ a
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bigint(20) NOT NULL default '0'
|
||||
`a` bigint(20) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (a int);
|
||||
|
|
|
@ -36,7 +36,7 @@ alter table t9 add column c int not null;
|
|||
show create table t9;
|
||||
Table Create Table
|
||||
t9 CREATE TABLE `t9` (
|
||||
`a` int(11) NOT NULL auto_increment,
|
||||
`a` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`b` char(16) NOT NULL,
|
||||
`c` int(11) NOT NULL,
|
||||
PRIMARY KEY (`a`)
|
||||
|
@ -48,7 +48,7 @@ drop table t1;
|
|||
SHOW CREATE TABLE t9;
|
||||
Table Create Table
|
||||
t9 CREATE TABLE `t9` (
|
||||
`a` int(11) NOT NULL auto_increment,
|
||||
`a` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`b` char(16) NOT NULL,
|
||||
`c` int(11) NOT NULL,
|
||||
`d` int(11) NOT NULL,
|
||||
|
@ -66,7 +66,7 @@ count(*)
|
|||
show create table mysqltest.t9;
|
||||
Table Create Table
|
||||
t9 CREATE TABLE `t9` (
|
||||
`a` int(11) NOT NULL auto_increment,
|
||||
`a` int(11) NOT NULL AUTO_INCREMENT,
|
||||
`b` char(16) NOT NULL,
|
||||
`c` int(11) NOT NULL,
|
||||
`d` int(11) NOT NULL,
|
||||
|
@ -84,24 +84,24 @@ show create table t1;
|
|||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` int(11) default NULL
|
||||
`b` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL,
|
||||
`b` int(11) default NULL
|
||||
`b` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL
|
||||
`i` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` int(11) default NULL
|
||||
`i` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
|
|
@ -5,7 +5,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -13,7 +13,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
|
@ -21,7 +21,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -29,7 +29,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
|
@ -37,7 +37,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -45,7 +45,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
|
@ -53,7 +53,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -61,7 +61,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
|
@ -69,7 +69,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -77,7 +77,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
|
@ -85,7 +85,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -93,7 +93,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
|
@ -101,7 +101,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -109,7 +109,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
|
@ -117,7 +117,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -125,7 +125,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
|
@ -133,7 +133,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -141,7 +141,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x1 x2 int;
|
||||
|
@ -149,7 +149,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
ALTER TABLE t1 CHANGE x2 x1 int;
|
||||
|
@ -157,7 +157,7 @@ CREATE TABLE t2 LIKE t1;
|
|||
SHOW CREATE TABLE t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`xx` int(11) default NULL
|
||||
`xx` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
DROP TABLE t2;
|
||||
DROP TABLE t1;
|
||||
|
|
|
@ -25,214 +25,214 @@ user
|
|||
show create table db;
|
||||
Table Create Table
|
||||
db CREATE TABLE `db` (
|
||||
`Host` char(60) collate utf8_bin NOT NULL default '',
|
||||
`Db` char(64) collate utf8_bin NOT NULL default '',
|
||||
`User` char(16) collate utf8_bin NOT NULL default '',
|
||||
`Select_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Insert_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Update_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Delete_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Drop_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Grant_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`References_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Index_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Alter_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_tmp_table_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Lock_tables_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_view_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Show_view_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_routine_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Alter_routine_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Execute_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Event_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Trigger_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Host` char(60) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Db` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`User` char(16) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Select_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Insert_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Update_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Delete_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Drop_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Grant_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`References_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Index_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Alter_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_tmp_table_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Lock_tables_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_view_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Show_view_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_routine_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Alter_routine_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Execute_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Event_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Trigger_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
PRIMARY KEY (`Host`,`Db`,`User`),
|
||||
KEY `User` (`User`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Database privileges'
|
||||
show create table host;
|
||||
Table Create Table
|
||||
host CREATE TABLE `host` (
|
||||
`Host` char(60) collate utf8_bin NOT NULL default '',
|
||||
`Db` char(64) collate utf8_bin NOT NULL default '',
|
||||
`Select_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Insert_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Update_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Delete_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Drop_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Grant_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`References_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Index_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Alter_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_tmp_table_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Lock_tables_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_view_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Show_view_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_routine_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Alter_routine_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Execute_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Trigger_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Host` char(60) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Db` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Select_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Insert_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Update_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Delete_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Drop_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Grant_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`References_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Index_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Alter_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_tmp_table_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Lock_tables_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_view_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Show_view_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_routine_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Alter_routine_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Execute_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Trigger_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
PRIMARY KEY (`Host`,`Db`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Host privileges; Merged with database privileges'
|
||||
show create table user;
|
||||
Table Create Table
|
||||
user CREATE TABLE `user` (
|
||||
`Host` char(60) collate utf8_bin NOT NULL default '',
|
||||
`User` char(16) collate utf8_bin NOT NULL default '',
|
||||
`Password` char(41) character set latin1 collate latin1_bin NOT NULL default '',
|
||||
`Select_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Insert_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Update_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Delete_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Drop_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Reload_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Shutdown_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Process_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`File_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Grant_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`References_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Index_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Alter_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Show_db_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Super_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_tmp_table_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Lock_tables_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Execute_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Repl_slave_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Repl_client_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_view_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Show_view_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_routine_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Alter_routine_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Create_user_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Event_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`Trigger_priv` enum('N','Y') character set utf8 NOT NULL default 'N',
|
||||
`ssl_type` enum('','ANY','X509','SPECIFIED') character set utf8 NOT NULL default '',
|
||||
`Host` char(60) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`User` char(16) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Password` char(41) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL DEFAULT '',
|
||||
`Select_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Insert_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Update_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Delete_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Drop_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Reload_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Shutdown_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Process_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`File_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Grant_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`References_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Index_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Alter_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Show_db_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Super_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_tmp_table_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Lock_tables_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Execute_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Repl_slave_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Repl_client_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_view_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Show_view_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_routine_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Alter_routine_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Create_user_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Event_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`Trigger_priv` enum('N','Y') CHARACTER SET utf8 NOT NULL DEFAULT 'N',
|
||||
`ssl_type` enum('','ANY','X509','SPECIFIED') CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`ssl_cipher` blob NOT NULL,
|
||||
`x509_issuer` blob NOT NULL,
|
||||
`x509_subject` blob NOT NULL,
|
||||
`max_questions` int(11) unsigned NOT NULL default '0',
|
||||
`max_updates` int(11) unsigned NOT NULL default '0',
|
||||
`max_connections` int(11) unsigned NOT NULL default '0',
|
||||
`max_user_connections` int(11) unsigned NOT NULL default '0',
|
||||
`max_questions` int(11) unsigned NOT NULL DEFAULT '0',
|
||||
`max_updates` int(11) unsigned NOT NULL DEFAULT '0',
|
||||
`max_connections` int(11) unsigned NOT NULL DEFAULT '0',
|
||||
`max_user_connections` int(11) unsigned NOT NULL DEFAULT '0',
|
||||
PRIMARY KEY (`Host`,`User`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Users and global privileges'
|
||||
show create table func;
|
||||
Table Create Table
|
||||
func CREATE TABLE `func` (
|
||||
`name` char(64) collate utf8_bin NOT NULL default '',
|
||||
`ret` tinyint(1) NOT NULL default '0',
|
||||
`dl` char(128) collate utf8_bin NOT NULL default '',
|
||||
`type` enum('function','aggregate') character set utf8 NOT NULL,
|
||||
`name` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`ret` tinyint(1) NOT NULL DEFAULT '0',
|
||||
`dl` char(128) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`type` enum('function','aggregate') CHARACTER SET utf8 NOT NULL,
|
||||
PRIMARY KEY (`name`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='User defined functions'
|
||||
show create table tables_priv;
|
||||
Table Create Table
|
||||
tables_priv CREATE TABLE `tables_priv` (
|
||||
`Host` char(60) collate utf8_bin NOT NULL default '',
|
||||
`Db` char(64) collate utf8_bin NOT NULL default '',
|
||||
`User` char(16) collate utf8_bin NOT NULL default '',
|
||||
`Table_name` char(64) collate utf8_bin NOT NULL default '',
|
||||
`Grantor` char(77) collate utf8_bin NOT NULL default '',
|
||||
`Timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`Table_priv` set('Select','Insert','Update','Delete','Create','Drop','Grant','References','Index','Alter','Create View','Show view','Trigger') character set utf8 NOT NULL default '',
|
||||
`Column_priv` set('Select','Insert','Update','References') character set utf8 NOT NULL default '',
|
||||
`Host` char(60) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Db` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`User` char(16) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Table_name` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Grantor` char(77) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`Table_priv` set('Select','Insert','Update','Delete','Create','Drop','Grant','References','Index','Alter','Create View','Show view','Trigger') CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`Column_priv` set('Select','Insert','Update','References') CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`Host`,`Db`,`User`,`Table_name`),
|
||||
KEY `Grantor` (`Grantor`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Table privileges'
|
||||
show create table columns_priv;
|
||||
Table Create Table
|
||||
columns_priv CREATE TABLE `columns_priv` (
|
||||
`Host` char(60) collate utf8_bin NOT NULL default '',
|
||||
`Db` char(64) collate utf8_bin NOT NULL default '',
|
||||
`User` char(16) collate utf8_bin NOT NULL default '',
|
||||
`Table_name` char(64) collate utf8_bin NOT NULL default '',
|
||||
`Column_name` char(64) collate utf8_bin NOT NULL default '',
|
||||
`Timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`Column_priv` set('Select','Insert','Update','References') character set utf8 NOT NULL default '',
|
||||
`Host` char(60) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Db` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`User` char(16) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Table_name` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Column_name` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`Column_priv` set('Select','Insert','Update','References') CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`Host`,`Db`,`User`,`Table_name`,`Column_name`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Column privileges'
|
||||
show create table procs_priv;
|
||||
Table Create Table
|
||||
procs_priv CREATE TABLE `procs_priv` (
|
||||
`Host` char(60) collate utf8_bin NOT NULL default '',
|
||||
`Db` char(64) collate utf8_bin NOT NULL default '',
|
||||
`User` char(16) collate utf8_bin NOT NULL default '',
|
||||
`Routine_name` char(64) collate utf8_bin NOT NULL default '',
|
||||
`Routine_type` enum('FUNCTION','PROCEDURE') collate utf8_bin NOT NULL,
|
||||
`Grantor` char(77) collate utf8_bin NOT NULL default '',
|
||||
`Proc_priv` set('Execute','Alter Routine','Grant') character set utf8 NOT NULL default '',
|
||||
`Timestamp` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`Host` char(60) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Db` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`User` char(16) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Routine_name` char(64) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Routine_type` enum('FUNCTION','PROCEDURE') COLLATE utf8_bin NOT NULL,
|
||||
`Grantor` char(77) COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`Proc_priv` set('Execute','Alter Routine','Grant') CHARACTER SET utf8 NOT NULL DEFAULT '',
|
||||
`Timestamp` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
PRIMARY KEY (`Host`,`Db`,`User`,`Routine_name`,`Routine_type`),
|
||||
KEY `Grantor` (`Grantor`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin COMMENT='Procedure privileges'
|
||||
show create table proc;
|
||||
Table Create Table
|
||||
proc CREATE TABLE `proc` (
|
||||
`db` char(64) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`name` char(64) NOT NULL default '',
|
||||
`db` char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`name` char(64) NOT NULL DEFAULT '',
|
||||
`type` enum('FUNCTION','PROCEDURE') NOT NULL,
|
||||
`specific_name` char(64) NOT NULL default '',
|
||||
`language` enum('SQL') NOT NULL default 'SQL',
|
||||
`sql_data_access` enum('CONTAINS_SQL','NO_SQL','READS_SQL_DATA','MODIFIES_SQL_DATA') NOT NULL default 'CONTAINS_SQL',
|
||||
`is_deterministic` enum('YES','NO') NOT NULL default 'NO',
|
||||
`security_type` enum('INVOKER','DEFINER') NOT NULL default 'DEFINER',
|
||||
`specific_name` char(64) NOT NULL DEFAULT '',
|
||||
`language` enum('SQL') NOT NULL DEFAULT 'SQL',
|
||||
`sql_data_access` enum('CONTAINS_SQL','NO_SQL','READS_SQL_DATA','MODIFIES_SQL_DATA') NOT NULL DEFAULT 'CONTAINS_SQL',
|
||||
`is_deterministic` enum('YES','NO') NOT NULL DEFAULT 'NO',
|
||||
`security_type` enum('INVOKER','DEFINER') NOT NULL DEFAULT 'DEFINER',
|
||||
`param_list` blob NOT NULL,
|
||||
`returns` char(64) NOT NULL default '',
|
||||
`returns` char(64) NOT NULL DEFAULT '',
|
||||
`body` longblob NOT NULL,
|
||||
`definer` char(77) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`created` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`modified` timestamp NOT NULL default '0000-00-00 00:00:00',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE') NOT NULL default '',
|
||||
`comment` char(64) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`definer` char(77) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`created` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`modified` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE') NOT NULL DEFAULT '',
|
||||
`comment` char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`db`,`name`,`type`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='Stored Procedures'
|
||||
show create table event;
|
||||
Table Create Table
|
||||
event CREATE TABLE `event` (
|
||||
`db` char(64) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`name` char(64) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`db` char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`name` char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`body` longblob NOT NULL,
|
||||
`definer` char(77) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`execute_at` datetime default NULL,
|
||||
`interval_value` int(11) default NULL,
|
||||
`interval_field` enum('YEAR','QUARTER','MONTH','DAY','HOUR','MINUTE','WEEK','SECOND','MICROSECOND','YEAR_MONTH','DAY_HOUR','DAY_MINUTE','DAY_SECOND','HOUR_MINUTE','HOUR_SECOND','MINUTE_SECOND','DAY_MICROSECOND','HOUR_MICROSECOND','MINUTE_MICROSECOND','SECOND_MICROSECOND') default NULL,
|
||||
`created` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`modified` timestamp NOT NULL default '0000-00-00 00:00:00',
|
||||
`last_executed` datetime default NULL,
|
||||
`starts` datetime default NULL,
|
||||
`ends` datetime default NULL,
|
||||
`status` enum('ENABLED','DISABLED') NOT NULL default 'ENABLED',
|
||||
`on_completion` enum('DROP','PRESERVE') NOT NULL default 'DROP',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE') NOT NULL default '',
|
||||
`comment` char(64) character set utf8 collate utf8_bin NOT NULL default '',
|
||||
`definer` char(77) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
`execute_at` datetime DEFAULT NULL,
|
||||
`interval_value` int(11) DEFAULT NULL,
|
||||
`interval_field` enum('YEAR','QUARTER','MONTH','DAY','HOUR','MINUTE','WEEK','SECOND','MICROSECOND','YEAR_MONTH','DAY_HOUR','DAY_MINUTE','DAY_SECOND','HOUR_MINUTE','HOUR_SECOND','MINUTE_SECOND','DAY_MICROSECOND','HOUR_MICROSECOND','MINUTE_MICROSECOND','SECOND_MICROSECOND') DEFAULT NULL,
|
||||
`created` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`modified` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00',
|
||||
`last_executed` datetime DEFAULT NULL,
|
||||
`starts` datetime DEFAULT NULL,
|
||||
`ends` datetime DEFAULT NULL,
|
||||
`status` enum('ENABLED','DISABLED') NOT NULL DEFAULT 'ENABLED',
|
||||
`on_completion` enum('DROP','PRESERVE') NOT NULL DEFAULT 'DROP',
|
||||
`sql_mode` set('REAL_AS_FLOAT','PIPES_AS_CONCAT','ANSI_QUOTES','IGNORE_SPACE','NOT_USED','ONLY_FULL_GROUP_BY','NO_UNSIGNED_SUBTRACTION','NO_DIR_IN_CREATE','POSTGRESQL','ORACLE','MSSQL','DB2','MAXDB','NO_KEY_OPTIONS','NO_TABLE_OPTIONS','NO_FIELD_OPTIONS','MYSQL323','MYSQL40','ANSI','NO_AUTO_VALUE_ON_ZERO','NO_BACKSLASH_ESCAPES','STRICT_TRANS_TABLES','STRICT_ALL_TABLES','NO_ZERO_IN_DATE','NO_ZERO_DATE','INVALID_DATES','ERROR_FOR_DIVISION_BY_ZERO','TRADITIONAL','NO_AUTO_CREATE_USER','HIGH_NOT_PRECEDENCE') NOT NULL DEFAULT '',
|
||||
`comment` char(64) CHARACTER SET utf8 COLLATE utf8_bin NOT NULL DEFAULT '',
|
||||
PRIMARY KEY (`definer`,`db`,`name`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=utf8 COMMENT='Events'
|
||||
show create table general_log;
|
||||
Table Create Table
|
||||
general_log CREATE TABLE `general_log` (
|
||||
`event_time` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`event_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`user_host` mediumtext,
|
||||
`thread_id` int(11) default NULL,
|
||||
`server_id` int(11) default NULL,
|
||||
`command_type` varchar(64) default NULL,
|
||||
`thread_id` int(11) DEFAULT NULL,
|
||||
`server_id` int(11) DEFAULT NULL,
|
||||
`command_type` varchar(64) DEFAULT NULL,
|
||||
`argument` mediumtext
|
||||
) ENGINE=CSV DEFAULT CHARSET=utf8 COMMENT='General log'
|
||||
show create table slow_log;
|
||||
Table Create Table
|
||||
slow_log CREATE TABLE `slow_log` (
|
||||
`start_time` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`start_time` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`user_host` mediumtext NOT NULL,
|
||||
`query_time` time NOT NULL,
|
||||
`lock_time` time NOT NULL,
|
||||
`rows_sent` int(11) NOT NULL,
|
||||
`rows_examined` int(11) NOT NULL,
|
||||
`db` varchar(512) default NULL,
|
||||
`last_insert_id` int(11) default NULL,
|
||||
`insert_id` int(11) default NULL,
|
||||
`server_id` int(11) default NULL,
|
||||
`db` varchar(512) DEFAULT NULL,
|
||||
`last_insert_id` int(11) DEFAULT NULL,
|
||||
`insert_id` int(11) DEFAULT NULL,
|
||||
`server_id` int(11) DEFAULT NULL,
|
||||
`sql_text` mediumtext NOT NULL
|
||||
) ENGINE=CSV DEFAULT CHARSET=utf8 COMMENT='Slow log'
|
||||
show tables;
|
||||
|
|
|
@ -108,7 +108,7 @@ This is temp. table
|
|||
show create table v1;
|
||||
Table Create Table
|
||||
v1 CREATE TEMPORARY TABLE `v1` (
|
||||
`A` varchar(19) NOT NULL default ''
|
||||
`A` varchar(19) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show create view v1;
|
||||
View Create View
|
||||
|
|
|
@ -630,7 +630,7 @@ set sql_mode=default;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` date default NULL
|
||||
`a` date DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show triggers;
|
||||
Trigger Event Table Statement Timing Created sql_mode Definer
|
||||
|
|
|
@ -21,8 +21,8 @@ create table t1 (s1 varbinary(20), s2 varbinary(20));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`s1` varbinary(20) default NULL,
|
||||
`s2` varbinary(20) default NULL
|
||||
`s1` varbinary(20) DEFAULT NULL,
|
||||
`s2` varbinary(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values (0x41,0x4100),(0x41,0x4120),(0x4100,0x4120);
|
||||
select hex(s1), hex(s2) from t1;
|
||||
|
|
|
@ -41,7 +41,7 @@ create table t1 (a bit(0));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bit(1) default NULL
|
||||
`a` bit(1) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (a bit(64));
|
||||
|
@ -494,7 +494,7 @@ a+0
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`a` bit(7) default NULL
|
||||
`a` bit(7) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1, t2;
|
||||
create table t1 (id1 int(11), b1 bit(1));
|
||||
|
|
|
@ -41,7 +41,7 @@ create table t1 (a bit(0)) engine=innodb;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bit(1) default NULL
|
||||
`a` bit(1) DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (a bit(64)) engine=innodb;
|
||||
|
@ -384,21 +384,21 @@ create table t1 (a bit, b bit(10)) engine=innodb;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bit(1) default NULL,
|
||||
`b` bit(10) default NULL
|
||||
`a` bit(1) DEFAULT NULL,
|
||||
`b` bit(10) DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
alter table t1 engine=heap;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bit(1) default NULL,
|
||||
`b` bit(10) default NULL
|
||||
`a` bit(1) DEFAULT NULL,
|
||||
`b` bit(10) DEFAULT NULL
|
||||
) ENGINE=MEMORY DEFAULT CHARSET=latin1
|
||||
alter table t1 engine=innodb;
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` bit(1) default NULL,
|
||||
`b` bit(10) default NULL
|
||||
`a` bit(1) DEFAULT NULL,
|
||||
`b` bit(10) DEFAULT NULL
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
|
|
@ -29,7 +29,7 @@ t3 CREATE TABLE `t3` (
|
|||
show create TABLE t4;
|
||||
Table Create Table
|
||||
t4 CREATE TABLE `t4` (
|
||||
`c` mediumtext character set utf8 NOT NULL
|
||||
`c` mediumtext CHARACTER SET utf8 NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1,t2,t3,t4;
|
||||
CREATE TABLE t1 (a char(257) default "hello");
|
||||
|
@ -709,11 +709,11 @@ alter table t1 add key (a,b,d,e);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) NOT NULL default '0',
|
||||
`b` int(11) NOT NULL default '0',
|
||||
`a` int(11) NOT NULL DEFAULT '0',
|
||||
`b` int(11) NOT NULL DEFAULT '0',
|
||||
`c` tinyblob NOT NULL,
|
||||
`d` int(11) NOT NULL default '0',
|
||||
`e` int(11) default NULL,
|
||||
`d` int(11) NOT NULL DEFAULT '0',
|
||||
`e` int(11) DEFAULT NULL,
|
||||
PRIMARY KEY (`a`,`b`,`c`(255),`d`),
|
||||
KEY `a` (`a`,`b`,`d`,`e`)
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
|
|
|
@ -709,14 +709,14 @@ create table t1 (d decimal(5));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`d` decimal(5,0) default NULL
|
||||
`d` decimal(5,0) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (d decimal);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`d` decimal(10,0) default NULL
|
||||
`d` decimal(10,0) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (d decimal(66,0));
|
||||
|
|
|
@ -1633,7 +1633,7 @@ create table t1 (a enum (' ','a','b ') not null default 'b ');
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` enum('','a','b') NOT NULL default 'b'
|
||||
`a` enum('','a','b') NOT NULL DEFAULT 'b'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (a enum ('0','1'));
|
||||
|
@ -1658,7 +1658,7 @@ a enum('
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` enum('ä','1','2') NOT NULL default 'ä'
|
||||
`a` enum('ä','1','2') NOT NULL DEFAULT 'ä'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
set names latin1;
|
||||
|
@ -1669,7 +1669,7 @@ b ENUM('value','
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` int(11) default '1',
|
||||
`a` int(11) DEFAULT '1',
|
||||
`b` enum('value','öäü_value','ĘĂŐ') NOT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show columns from t1;
|
||||
|
@ -1699,7 +1699,7 @@ a ENUM('
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` enum('ä','ö','ü') character set utf8 default 'ü'
|
||||
`a` enum('ä','ö','ü') CHARACTER SET utf8 DEFAULT 'ü'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('ä'), ('ö'), ('ü');
|
||||
select a from t1 order by a;
|
||||
|
@ -1717,7 +1717,7 @@ set names latin1;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` enum('ä','ö','ü') default 'ü'
|
||||
`a` enum('ä','ö','ü') DEFAULT 'ü'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select a from t1 order by a;
|
||||
a
|
||||
|
|
|
@ -91,10 +91,10 @@ col1 col2 col3 col4
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`col1` double default NULL,
|
||||
`col2` double(53,5) default NULL,
|
||||
`col3` double default NULL,
|
||||
`col4` double default NULL
|
||||
`col1` double DEFAULT NULL,
|
||||
`col2` double(53,5) DEFAULT NULL,
|
||||
`col3` double DEFAULT NULL,
|
||||
`col4` double DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1,t2;
|
||||
create table t1 (a float);
|
||||
|
@ -237,7 +237,7 @@ d
|
|||
show create table t3;
|
||||
Table Create Table
|
||||
t3 CREATE TABLE `t3` (
|
||||
`d` double(22,9) default NULL
|
||||
`d` double(22,9) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1, t2, t3;
|
||||
create table t1 select 105213674794682365.00 + 0.0 x;
|
||||
|
|
|
@ -3,48 +3,48 @@ create table t1 (c nchar(10));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` char(10) character set utf8 default NULL
|
||||
`c` char(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (c national char(10));
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` char(10) character set utf8 default NULL
|
||||
`c` char(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (c national varchar(10));
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` varchar(10) character set utf8 default NULL
|
||||
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (c nvarchar(10));
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` varchar(10) character set utf8 default NULL
|
||||
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (c nchar varchar(10));
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` varchar(10) character set utf8 default NULL
|
||||
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (c national character varying(10));
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` varchar(10) character set utf8 default NULL
|
||||
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (c nchar varying(10));
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c` varchar(10) character set utf8 default NULL
|
||||
`c` varchar(10) CHARACTER SET utf8 DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
|
|
|
@ -52,13 +52,13 @@ if(1, 1.1, 1.2) if(0, 1.1, 1.2) if(0.1, 1.1, 1.2) if(0, 1, 1.1) if(0, NULL, 1.2)
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`if(1, 1.1, 1.2)` decimal(2,1) NOT NULL default '0.0',
|
||||
`if(0, 1.1, 1.2)` decimal(2,1) NOT NULL default '0.0',
|
||||
`if(0.1, 1.1, 1.2)` decimal(2,1) NOT NULL default '0.0',
|
||||
`if(0, 1, 1.1)` decimal(2,1) NOT NULL default '0.0',
|
||||
`if(0, NULL, 1.2)` decimal(2,1) default NULL,
|
||||
`if(1, 0.22e1, 1.1)` double NOT NULL default '0',
|
||||
`if(1E0, 1.1, 1.2)` decimal(2,1) NOT NULL default '0.0'
|
||||
`if(1, 1.1, 1.2)` decimal(2,1) NOT NULL DEFAULT '0.0',
|
||||
`if(0, 1.1, 1.2)` decimal(2,1) NOT NULL DEFAULT '0.0',
|
||||
`if(0.1, 1.1, 1.2)` decimal(2,1) NOT NULL DEFAULT '0.0',
|
||||
`if(0, 1, 1.1)` decimal(2,1) NOT NULL DEFAULT '0.0',
|
||||
`if(0, NULL, 1.2)` decimal(2,1) DEFAULT NULL,
|
||||
`if(1, 0.22e1, 1.1)` double NOT NULL DEFAULT '0',
|
||||
`if(1E0, 1.1, 1.2)` decimal(2,1) NOT NULL DEFAULT '0.0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 select nullif(1.1, 1.1), nullif(1.1, 1.2), nullif(1.1, 0.11e1), nullif(1.0, 1), nullif(1, 1.0), nullif(1, 1.1);
|
||||
|
@ -68,12 +68,12 @@ NULL 1.1 NULL NULL NULL 1
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`nullif(1.1, 1.1)` decimal(2,1) unsigned default NULL,
|
||||
`nullif(1.1, 1.2)` decimal(2,1) unsigned default NULL,
|
||||
`nullif(1.1, 0.11e1)` decimal(2,1) unsigned default NULL,
|
||||
`nullif(1.0, 1)` decimal(2,1) unsigned default NULL,
|
||||
`nullif(1, 1.0)` int(1) default NULL,
|
||||
`nullif(1, 1.1)` int(1) default NULL
|
||||
`nullif(1.1, 1.1)` decimal(2,1) unsigned DEFAULT NULL,
|
||||
`nullif(1.1, 1.2)` decimal(2,1) unsigned DEFAULT NULL,
|
||||
`nullif(1.1, 0.11e1)` decimal(2,1) unsigned DEFAULT NULL,
|
||||
`nullif(1.0, 1)` decimal(2,1) unsigned DEFAULT NULL,
|
||||
`nullif(1, 1.0)` int(1) DEFAULT NULL,
|
||||
`nullif(1, 1.1)` int(1) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (a decimal(4,2));
|
||||
|
@ -174,10 +174,10 @@ create table t1 select round(15.4,-1), truncate(-5678.123451,-3), abs(-1.1), -(-
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`round(15.4,-1)` decimal(3,0) unsigned NOT NULL default '0',
|
||||
`truncate(-5678.123451,-3)` decimal(4,0) NOT NULL default '0',
|
||||
`abs(-1.1)` decimal(2,1) NOT NULL default '0.0',
|
||||
`-(-1.1)` decimal(2,1) NOT NULL default '0.0'
|
||||
`round(15.4,-1)` decimal(3,0) unsigned NOT NULL DEFAULT '0',
|
||||
`truncate(-5678.123451,-3)` decimal(4,0) NOT NULL DEFAULT '0',
|
||||
`abs(-1.1)` decimal(2,1) NOT NULL DEFAULT '0.0',
|
||||
`-(-1.1)` decimal(2,1) NOT NULL DEFAULT '0.0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
set session sql_mode='traditional';
|
||||
|
@ -771,7 +771,7 @@ create table t1 as select 0.5;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`0.5` decimal(2,1) unsigned NOT NULL default '0.0'
|
||||
`0.5` decimal(2,1) unsigned NOT NULL DEFAULT '0.0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
select round(1.5),round(2.5);
|
||||
|
@ -930,14 +930,14 @@ create table t1 (sl decimal(5, 5));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`sl` decimal(5,5) default NULL
|
||||
`sl` decimal(5,5) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (sl decimal(65, 30));
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`sl` decimal(65,30) default NULL
|
||||
`sl` decimal(65,30) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (
|
||||
|
@ -969,8 +969,8 @@ f1 decimal (0,0) zerofill not null default 0);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f0` decimal(30,30) unsigned zerofill NOT NULL default '0.000000000000000000000000000000',
|
||||
`f1` decimal(10,0) unsigned zerofill NOT NULL default '0000000000'
|
||||
`f0` decimal(30,30) unsigned zerofill NOT NULL DEFAULT '0.000000000000000000000000000000',
|
||||
`f1` decimal(10,0) unsigned zerofill NOT NULL DEFAULT '0000000000'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
drop procedure if exists wg2;
|
||||
|
@ -1019,10 +1019,10 @@ my_decimal DECIMAL(65,30)
|
|||
SHOW CREATE TABLE t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`my_float` float default NULL,
|
||||
`my_double` double default NULL,
|
||||
`my_varchar` varchar(50) default NULL,
|
||||
`my_decimal` decimal(65,30) default NULL
|
||||
`my_float` float DEFAULT NULL,
|
||||
`my_double` double DEFAULT NULL,
|
||||
`my_varchar` varchar(50) DEFAULT NULL,
|
||||
`my_decimal` decimal(65,30) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
INSERT INTO t1 SET my_float = 1.175494345e-32,
|
||||
my_double = 1.175494345e-32,
|
||||
|
|
|
@ -10,7 +10,7 @@ create table t1 (a set (' ','a','b ') not null default 'b ');
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` set('','a','b') NOT NULL default 'b'
|
||||
`a` set('','a','b') NOT NULL DEFAULT 'b'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
CREATE TABLE t1 ( user varchar(64) NOT NULL default '', path varchar(255) NOT NULL default '', privilege set('select','RESERVED30','RESERVED29','RESERVED28','RESERVED27','RESERVED26', 'RESERVED25','RESERVED24','data.delete','RESERVED22','RESERVED21', 'RESERVED20','data.insert.none','data.insert.approve', 'data.insert.delete','data.insert.move','data.insert.propose', 'data.insert.reject','RESERVED13','RESERVED12','RESERVED11','RESERVED10', 'RESERVED09','data.update','RESERVED07','RESERVED06','RESERVED05', 'RESERVED04','metadata.delete','metadata.put','RESERVED01','RESERVED00') NOT NULL default '', KEY user (user) ) ENGINE=MyISAM CHARSET=utf8;
|
||||
|
@ -20,7 +20,7 @@ create table t1 (s set ('a','A') character set latin1 collate latin1_bin);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`s` set('a','A') character set latin1 collate latin1_bin default NULL
|
||||
`s` set('a','A') CHARACTER SET latin1 COLLATE latin1_bin DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('a'),('a,A'),('A,a'),('A');
|
||||
select s from t1 order by s;
|
||||
|
|
|
@ -194,9 +194,9 @@ t1 t2 t3
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`t1` timestamp NOT NULL default '2003-01-01 00:00:00',
|
||||
`t2` datetime default NULL,
|
||||
`t3` timestamp NOT NULL default '0000-00-00 00:00:00'
|
||||
`t1` timestamp NOT NULL DEFAULT '2003-01-01 00:00:00',
|
||||
`t2` datetime DEFAULT NULL,
|
||||
`t3` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show columns from t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -218,9 +218,9 @@ t1 t2 t3
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`t1` timestamp NOT NULL default CURRENT_TIMESTAMP,
|
||||
`t2` datetime default NULL,
|
||||
`t3` timestamp NOT NULL default '0000-00-00 00:00:00'
|
||||
`t1` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
`t2` datetime DEFAULT NULL,
|
||||
`t3` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show columns from t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -245,8 +245,8 @@ t1 t2
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`t1` timestamp NOT NULL default '2003-01-01 00:00:00' on update CURRENT_TIMESTAMP,
|
||||
`t2` datetime default NULL
|
||||
`t1` timestamp NOT NULL DEFAULT '2003-01-01 00:00:00' ON UPDATE CURRENT_TIMESTAMP,
|
||||
`t2` datetime DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show columns from t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -270,8 +270,8 @@ t1 t2
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`t1` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`t2` datetime default NULL
|
||||
`t1` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`t2` datetime DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show columns from t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -295,9 +295,9 @@ t1 t2 t3
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`t1` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`t2` datetime default NULL,
|
||||
`t3` timestamp NOT NULL default '0000-00-00 00:00:00'
|
||||
`t1` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`t2` datetime DEFAULT NULL,
|
||||
`t3` timestamp NOT NULL DEFAULT '0000-00-00 00:00:00'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show columns from t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -322,8 +322,8 @@ t1 t2
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`t1` timestamp NOT NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`t2` datetime default NULL
|
||||
`t1` timestamp NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`t2` datetime DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show columns from t1;
|
||||
Field Type Null Key Default Extra
|
||||
|
@ -377,8 +377,8 @@ create table t1 (a timestamp null, b timestamp null);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` timestamp NULL default NULL,
|
||||
`b` timestamp NULL default NULL
|
||||
`a` timestamp NULL DEFAULT NULL,
|
||||
`b` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values (NULL, NULL);
|
||||
SET TIMESTAMP=1000000017;
|
||||
|
@ -392,8 +392,8 @@ create table t1 (a timestamp null default current_timestamp on update current_ti
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` timestamp NULL default CURRENT_TIMESTAMP on update CURRENT_TIMESTAMP,
|
||||
`b` timestamp NULL default NULL
|
||||
`a` timestamp NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP,
|
||||
`b` timestamp NULL DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values (NULL, NULL);
|
||||
SET TIMESTAMP=1000000018;
|
||||
|
@ -407,8 +407,8 @@ create table t1 (a timestamp null default null, b timestamp null default '2003-0
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` timestamp NULL default NULL,
|
||||
`b` timestamp NULL default '2003-01-01 00:00:00'
|
||||
`a` timestamp NULL DEFAULT NULL,
|
||||
`b` timestamp NULL DEFAULT '2003-01-01 00:00:00'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values (NULL, NULL);
|
||||
insert into t1 values (DEFAULT, DEFAULT);
|
||||
|
@ -439,8 +439,8 @@ create table t1 (a timestamp, b timestamp(19));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE "t1" (
|
||||
"a" datetime default NULL,
|
||||
"b" datetime default NULL
|
||||
"a" datetime DEFAULT NULL,
|
||||
"b" datetime DEFAULT NULL
|
||||
)
|
||||
set sql_mode='';
|
||||
drop table t1;
|
||||
|
|
|
@ -4,17 +4,17 @@ truncate table vchar;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`v` varchar(30) default NULL,
|
||||
`c` char(3) default NULL,
|
||||
`e` enum('abc','def','ghi') default NULL,
|
||||
`v` varchar(30) DEFAULT NULL,
|
||||
`c` char(3) DEFAULT NULL,
|
||||
`e` enum('abc','def','ghi') DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
show create table vchar;
|
||||
Table Create Table
|
||||
vchar CREATE TABLE `vchar` (
|
||||
`v` varchar(30) default NULL,
|
||||
`c` char(3) default NULL,
|
||||
`e` enum('abc','def','ghi') default NULL,
|
||||
`v` varchar(30) DEFAULT NULL,
|
||||
`c` char(3) DEFAULT NULL,
|
||||
`e` enum('abc','def','ghi') DEFAULT NULL,
|
||||
`t` text
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('abc', 'de', 'ghi', 'jkl');
|
||||
|
@ -37,11 +37,11 @@ alter table vchar add i int;
|
|||
show create table vchar;
|
||||
Table Create Table
|
||||
vchar CREATE TABLE `vchar` (
|
||||
`v` varchar(30) default NULL,
|
||||
`c` char(3) default NULL,
|
||||
`e` enum('abc','def','ghi') default NULL,
|
||||
`v` varchar(30) DEFAULT NULL,
|
||||
`c` char(3) DEFAULT NULL,
|
||||
`e` enum('abc','def','ghi') DEFAULT NULL,
|
||||
`t` text,
|
||||
`i` int(11) default NULL
|
||||
`i` int(11) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select length(v),length(c),length(e),length(t) from vchar;
|
||||
length(v) length(c) length(e) length(t)
|
||||
|
@ -397,14 +397,14 @@ create index index1 on t1(f1(10));
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` varchar(65500) default NULL,
|
||||
`f1` varchar(65500) DEFAULT NULL,
|
||||
KEY `index1` (`f1`(10))
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 modify f1 varchar(255);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f1` varchar(255) default NULL,
|
||||
`f1` varchar(255) DEFAULT NULL,
|
||||
KEY `index1` (`f1`(10))
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
alter table t1 modify f1 tinytext;
|
||||
|
|
|
@ -543,7 +543,7 @@ aa
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(2) NOT NULL default ''
|
||||
`a` varchar(2) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT 12 as a UNION select "aa" as a;
|
||||
|
@ -554,7 +554,7 @@ aa
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varbinary(20) NOT NULL default ''
|
||||
`a` varbinary(20) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT 12 as a UNION select 12.2 as a;
|
||||
|
@ -565,7 +565,7 @@ a
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` decimal(3,1) NOT NULL default '0.0'
|
||||
`a` decimal(3,1) NOT NULL DEFAULT '0.0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t2 (it1 tinyint, it2 tinyint not null, i int not null, ib bigint, f float, d double, y year, da date, dt datetime, sc char(10), sv varchar(10), b blob, tx text);
|
||||
|
@ -578,7 +578,7 @@ NULL
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`it2` tinyint(4) default NULL
|
||||
`it2` tinyint(4) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT it2 from t2 UNION select i from t2;
|
||||
|
@ -589,7 +589,7 @@ it2
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`it2` int(11) NOT NULL default '0'
|
||||
`it2` int(11) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT i from t2 UNION select f from t2;
|
||||
|
@ -600,7 +600,7 @@ i
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`i` double default NULL
|
||||
`i` double DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT f from t2 UNION select d from t2;
|
||||
|
@ -611,7 +611,7 @@ f
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f` double default NULL
|
||||
`f` double DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT ib from t2 UNION select f from t2;
|
||||
|
@ -622,7 +622,7 @@ ib
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`ib` double default NULL
|
||||
`ib` double DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT ib from t2 UNION select d from t2;
|
||||
|
@ -633,7 +633,7 @@ ib
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`ib` double default NULL
|
||||
`ib` double DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT f from t2 UNION select y from t2;
|
||||
|
@ -644,7 +644,7 @@ f
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f` float default NULL
|
||||
`f` float DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT f from t2 UNION select da from t2;
|
||||
|
@ -655,7 +655,7 @@ f
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`f` varbinary(24) default NULL
|
||||
`f` varbinary(24) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT y from t2 UNION select da from t2;
|
||||
|
@ -666,7 +666,7 @@ y
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`y` varbinary(10) default NULL
|
||||
`y` varbinary(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT y from t2 UNION select dt from t2;
|
||||
|
@ -677,7 +677,7 @@ y
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`y` varbinary(19) default NULL
|
||||
`y` varbinary(19) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT da from t2 UNION select dt from t2;
|
||||
|
@ -688,7 +688,7 @@ da
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`da` datetime default NULL
|
||||
`da` datetime DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT dt from t2 UNION select sc from t2;
|
||||
|
@ -699,7 +699,7 @@ testc
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`dt` varbinary(19) default NULL
|
||||
`dt` varbinary(19) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT dt from t2 UNION select sv from t2;
|
||||
|
@ -710,7 +710,7 @@ testv
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`dt` varbinary(19) default NULL
|
||||
`dt` varbinary(19) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT sc from t2 UNION select sv from t2;
|
||||
|
@ -721,7 +721,7 @@ testv
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`sc` varchar(10) default NULL
|
||||
`sc` varchar(10) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 SELECT dt from t2 UNION select b from t2;
|
||||
|
@ -788,7 +788,7 @@ select * from t1;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`1` bigint(20) NOT NULL default '0'
|
||||
`1` bigint(20) NOT NULL DEFAULT '0'
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 select _latin1"test" union select _latin2"testt" ;
|
||||
|
@ -797,7 +797,7 @@ create table t1 select _latin2"test" union select _latin2"testt" ;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`test` varchar(5) character set latin2 NOT NULL default ''
|
||||
`test` varchar(5) CHARACTER SET latin2 NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 (s char(200));
|
||||
|
@ -1041,7 +1041,7 @@ create table t1 as
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`test` varchar(4) NOT NULL default ''
|
||||
`test` varchar(4) NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select count(*) from t1;
|
||||
count(*)
|
||||
|
@ -1054,7 +1054,7 @@ create table t1 as
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`_latin1'test' collate latin1_bin` varchar(4) character set latin1 collate latin1_bin NOT NULL default ''
|
||||
`_latin1'test' collate latin1_bin` varchar(4) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select count(*) from t1;
|
||||
count(*)
|
||||
|
@ -1067,7 +1067,7 @@ create table t1 as
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`test` varchar(4) character set latin1 collate latin1_bin NOT NULL default ''
|
||||
`test` varchar(4) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select count(*) from t1;
|
||||
count(*)
|
||||
|
@ -1080,7 +1080,7 @@ create table t1 as
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`test` varchar(4) character set latin1 collate latin1_bin NOT NULL default ''
|
||||
`test` varchar(4) CHARACTER SET latin1 COLLATE latin1_bin NOT NULL DEFAULT ''
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select count(*) from t1;
|
||||
count(*)
|
||||
|
@ -1099,7 +1099,7 @@ create table t1 as
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a collate latin1_german1_ci` varchar(1) character set latin1 collate latin1_german1_ci default NULL
|
||||
`a collate latin1_german1_ci` varchar(1) CHARACTER SET latin1 COLLATE latin1_german1_ci DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 as
|
||||
|
@ -1108,7 +1108,7 @@ create table t1 as
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(1) character set latin1 collate latin1_german1_ci default NULL
|
||||
`a` varchar(1) CHARACTER SET latin1 COLLATE latin1_german1_ci DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
create table t1 as
|
||||
|
@ -1118,7 +1118,7 @@ create table t1 as
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` varchar(1) character set latin1 collate latin1_german1_ci default NULL
|
||||
`a` varchar(1) CHARACTER SET latin1 COLLATE latin1_german1_ci DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
drop table t2;
|
||||
|
@ -1193,9 +1193,9 @@ c ENUM("one", "two")
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`a` enum('ä','ö','ü') character set utf8 NOT NULL default 'ü',
|
||||
`b` enum('one','two') character set utf8 default NULL,
|
||||
`c` enum('one','two') default NULL
|
||||
`a` enum('ä','ö','ü') CHARACTER SET utf8 NOT NULL DEFAULT 'ü',
|
||||
`b` enum('one','two') CHARACTER SET utf8 DEFAULT NULL,
|
||||
`c` enum('one','two') DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
insert into t1 values ('ä', 'one', 'one'), ('ö', 'two', 'one'), ('ü', NULL, NULL);
|
||||
create table t2 select NULL union select a from t1;
|
||||
|
@ -1251,7 +1251,7 @@ create table t2 select * from t1 union select 'abcdefghijkl';
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`a` varchar(12) default NULL
|
||||
`a` varchar(12) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
select row_format from information_schema.TABLES where table_schema="test" and table_name="t2";
|
||||
row_format
|
||||
|
@ -1260,7 +1260,7 @@ alter table t2 ROW_FORMAT=fixed;
|
|||
show create table t2;
|
||||
Table Create Table
|
||||
t2 CREATE TABLE `t2` (
|
||||
`a` varchar(12) default NULL
|
||||
`a` varchar(12) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ROW_FORMAT=FIXED
|
||||
drop table t1,t2;
|
||||
CREATE TABLE t1 (a mediumtext);
|
||||
|
|
|
@ -231,7 +231,7 @@ create table t1 select @first_var;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`@first_var` bigint(20) default NULL
|
||||
`@first_var` bigint(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
set @first_var= NULL;
|
||||
|
@ -239,7 +239,7 @@ create table t1 select @first_var;
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`@first_var` bigint(20) default NULL
|
||||
`@first_var` bigint(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
set @first_var= concat(NULL);
|
||||
|
|
|
@ -495,11 +495,11 @@ c5 bigint);
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` tinyint(4) default NULL,
|
||||
`c2` smallint(6) default NULL,
|
||||
`c3` mediumint(9) default NULL,
|
||||
`c4` int(11) default NULL,
|
||||
`c5` bigint(20) default NULL
|
||||
`c1` tinyint(4) DEFAULT NULL,
|
||||
`c2` smallint(6) DEFAULT NULL,
|
||||
`c3` mediumint(9) DEFAULT NULL,
|
||||
`c4` int(11) DEFAULT NULL,
|
||||
`c5` bigint(20) DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
set @arg00= 8, @arg01= 8.8, @arg02= 'a string', @arg03= 0.2e0;
|
||||
|
@ -507,10 +507,10 @@ create table t1 as select @arg00 as c1, @arg01 as c2, @arg02 as c3, @arg03 as c4
|
|||
show create table t1;
|
||||
Table Create Table
|
||||
t1 CREATE TABLE `t1` (
|
||||
`c1` bigint(20) default NULL,
|
||||
`c2` decimal(65,30) default NULL,
|
||||
`c1` bigint(20) DEFAULT NULL,
|
||||
`c2` decimal(65,30) DEFAULT NULL,
|
||||
`c3` longtext,
|
||||
`c4` double default NULL
|
||||
`c4` double DEFAULT NULL
|
||||
) ENGINE=MyISAM DEFAULT CHARSET=latin1
|
||||
drop table t1;
|
||||
SET GLOBAL MYISAM_DATA_POINTER_SIZE= 7;
|
||||
|
|
|
@ -1,8 +1,3 @@
|
|||
# Requires row logging because warnings produced when creating
|
||||
# the tables in "gis_generic" with no PK and BLOB's differ
|
||||
|
||||
--source include/have_binlog_format_row.inc
|
||||
|
||||
--source include/have_ndb.inc
|
||||
SET storage_engine=ndbcluster;
|
||||
--source include/gis_generic.inc
|
||||
|
|
|
@ -249,7 +249,7 @@ copy_dir_dirs() {
|
|||
# Input directories to be copied
|
||||
#
|
||||
|
||||
for i in client dbug extra storage/heap include storage/archive storage/example \
|
||||
for i in client dbug extra storage/heap include storage/archive storage/csv \
|
||||
include/mysql libmysql libmysqld storage/myisam storage/example \
|
||||
storage/myisammrg mysys regex sql strings sql-common sql/examples \
|
||||
tools vio zlib
|
||||
|
|
|
@ -966,7 +966,7 @@ store_create_info(THD *thd, TABLE_LIST *table_list, String *packet,
|
|||
{
|
||||
if (field->charset() != share->table_charset)
|
||||
{
|
||||
packet->append(STRING_WITH_LEN(" character set "));
|
||||
packet->append(STRING_WITH_LEN(" CHARACTER SET "));
|
||||
packet->append(field->charset()->csname);
|
||||
}
|
||||
/*
|
||||
|
@ -975,7 +975,7 @@ store_create_info(THD *thd, TABLE_LIST *table_list, String *packet,
|
|||
*/
|
||||
if (!(field->charset()->state & MY_CS_PRIMARY))
|
||||
{
|
||||
packet->append(STRING_WITH_LEN(" collate "));
|
||||
packet->append(STRING_WITH_LEN(" COLLATE "));
|
||||
packet->append(field->charset()->name);
|
||||
}
|
||||
}
|
||||
|
@ -1006,7 +1006,7 @@ store_create_info(THD *thd, TABLE_LIST *table_list, String *packet,
|
|||
|
||||
if (has_default)
|
||||
{
|
||||
packet->append(STRING_WITH_LEN(" default "));
|
||||
packet->append(STRING_WITH_LEN(" DEFAULT "));
|
||||
if (has_now_default)
|
||||
packet->append(STRING_WITH_LEN("CURRENT_TIMESTAMP"));
|
||||
else if (!field->is_null())
|
||||
|
@ -1034,11 +1034,11 @@ store_create_info(THD *thd, TABLE_LIST *table_list, String *packet,
|
|||
if (!(thd->variables.sql_mode & MODE_NO_FIELD_OPTIONS) &&
|
||||
table->timestamp_field == field &&
|
||||
field->unireg_check != Field::TIMESTAMP_DN_FIELD)
|
||||
packet->append(STRING_WITH_LEN(" on update CURRENT_TIMESTAMP"));
|
||||
packet->append(STRING_WITH_LEN(" ON UPDATE CURRENT_TIMESTAMP"));
|
||||
|
||||
if (field->unireg_check == Field::NEXT_NUMBER &&
|
||||
!(thd->variables.sql_mode & MODE_NO_FIELD_OPTIONS))
|
||||
packet->append(STRING_WITH_LEN(" auto_increment"));
|
||||
packet->append(STRING_WITH_LEN(" AUTO_INCREMENT"));
|
||||
|
||||
if (field->comment.length)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue