diff options
author | unknown <gluh@mysql.com/eagle.(none)> | 2007-11-28 15:37:00 +0400 |
---|---|---|
committer | unknown <gluh@mysql.com/eagle.(none)> | 2007-11-28 15:37:00 +0400 |
commit | b9d8e34925d1be4b6c1c8950217d41456a02c542 (patch) | |
tree | 45cb00d042a13f59effcab0620b2ea37d959f203 /mysql-test/r/create.result | |
parent | 9d503cea20bc5f2e1569f16b0114d34dfd875d66 (diff) | |
download | mariadb-git-b9d8e34925d1be4b6c1c8950217d41456a02c542.tar.gz |
Bug#25629 CREATE TABLE LIKE does not work with INFORMATION_SCHEMA
added new func mysql_create_like_schema_frm() which creates frm file based on I_S table
mysql-test/r/create.result:
test result
mysql-test/t/create.test:
test case
sql/sql_table.cc:
added new func mysql_create_like_schema_frm() which creates frm file based on I_S table
Diffstat (limited to 'mysql-test/r/create.result')
-rw-r--r-- | mysql-test/r/create.result | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/mysql-test/r/create.result b/mysql-test/r/create.result index ca3b344af53..9e7fef5e3f1 100644 --- a/mysql-test/r/create.result +++ b/mysql-test/r/create.result @@ -1705,4 +1705,42 @@ create table t1 as select 1; create table t2 as select f1() from t1; drop table t1,t2; drop function f1; +create table t1 like information_schema.processlist; +show create table t1; +Table Create Table +t1 CREATE TABLE `t1` ( + `ID` bigint(4) NOT NULL DEFAULT '0', + `USER` varchar(16) NOT NULL DEFAULT '', + `HOST` varchar(64) NOT NULL DEFAULT '', + `DB` varchar(64) DEFAULT NULL, + `COMMAND` varchar(16) NOT NULL DEFAULT '', + `TIME` bigint(7) NOT NULL DEFAULT '0', + `STATE` varchar(64) DEFAULT NULL, + `INFO` longtext +) ENGINE=MyISAM DEFAULT CHARSET=utf8 +drop table t1; +create temporary table t1 like information_schema.processlist; +show create table t1; +Table Create Table +t1 CREATE TEMPORARY TABLE `t1` ( + `ID` bigint(4) NOT NULL DEFAULT '0', + `USER` varchar(16) NOT NULL DEFAULT '', + `HOST` varchar(64) NOT NULL DEFAULT '', + `DB` varchar(64) DEFAULT NULL, + `COMMAND` varchar(16) NOT NULL DEFAULT '', + `TIME` bigint(7) NOT NULL DEFAULT '0', + `STATE` varchar(64) DEFAULT NULL, + `INFO` longtext +) ENGINE=MyISAM DEFAULT CHARSET=utf8 +drop table t1; +create table t1 like information_schema.character_sets; +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' +) ENGINE=MEMORY DEFAULT CHARSET=utf8 +drop table t1; End of 5.1 tests |