diff --git a/mysql-test/r/schema.result b/mysql-test/r/schema.result new file mode 100644 index 00000000000..d7bd6fef655 --- /dev/null +++ b/mysql-test/r/schema.result @@ -0,0 +1,10 @@ +create schema foo; +show create schema foo; +Database Create Database +foo CREATE DATABASE `foo` /*!40100 DEFAULT CHARACTER SET latin1 */ +show schemas; +Database +foo +mysql +test +drop schema foo; diff --git a/mysql-test/t/schema.test b/mysql-test/t/schema.test new file mode 100644 index 00000000000..d9bd607b2db --- /dev/null +++ b/mysql-test/t/schema.test @@ -0,0 +1,8 @@ +# +# Just a couple of tests to make sure that schema works. +# + +create schema foo; +show create schema foo; +show schemas; +drop schema foo; diff --git a/sql/lex.h b/sql/lex.h index 023c4752720..920325024f9 100644 --- a/sql/lex.h +++ b/sql/lex.h @@ -397,6 +397,8 @@ static SYMBOL symbols[] = { { "ROW_FORMAT", SYM(ROW_FORMAT_SYM)}, { "RTREE", SYM(RTREE_SYM)}, { "SAVEPOINT", SYM(SAVEPOINT_SYM)}, + { "SCHEMA", SYM(DATABASE)}, + { "SCHEMAS", SYM(DATABASES)}, { "SECOND", SYM(SECOND_SYM)}, { "SECOND_MICROSECOND", SYM(SECOND_MICROSECOND_SYM)}, { "SECURITY", SYM(SECURITY_SYM)},