summaryrefslogtreecommitdiff
path: root/mysql-test/t/variables.test
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test/t/variables.test')
-rw-r--r--mysql-test/t/variables.test19
1 files changed, 19 insertions, 0 deletions
diff --git a/mysql-test/t/variables.test b/mysql-test/t/variables.test
index 8c318497c22..67a05768595 100644
--- a/mysql-test/t/variables.test
+++ b/mysql-test/t/variables.test
@@ -347,3 +347,22 @@ show global variables like 'log_warnings';
set global log_warnings = @tstlw;
show global variables like 'log_warnings';
+#
+# BUG#4788 show create table provides incorrect statement
+#
+# What default width have numeric types?
+create table t1 (
+ c1 tinyint,
+ c2 smallint,
+ c3 mediumint,
+ c4 int,
+ c5 bigint);
+show create table t1;
+drop table t1;
+#
+# What types and widths have variables?
+set @arg00= 8, @arg01= 8.8, @arg02= 'a string';
+create table t1 as select @arg00 as c1, @arg01 as c2, @arg02 as c3;
+show create table t1;
+drop table t1;
+