@@ -1898,3 +1898,58 @@ DROP TABLE ti3;
18981898CREATE TABLE tm1(i INT DEFAULT 1) engine=MyISAM;
18991899ALTER TABLE tm1 ADD INDEX ii1(i), ALTER COLUMN i DROP DEFAULT;
19001900DROP TABLE tm1;
1901+ #
1902+ # Bug#11815557 60269: MYSQL SHOULD REJECT ATTEMPTS TO CREATE SYSTEM
1903+ # TABLES IN INCORRECT ENGINE
1904+ #
1905+ # Note: This test assumes that only MyISAM supports system tables.
1906+ # If other engines are made to support system tables,
1907+ # then this test needs to be updated
1908+ #
1909+ use mysql;
1910+ ALTER TABLE db ENGINE=innodb;
1911+ ERROR HY000: Storage engine 'InnoDB' does not support system tables. [mysql.db]
1912+ ALTER TABLE user ENGINE=memory;
1913+ ERROR HY000: Storage engine 'MEMORY' does not support system tables. [mysql.user]
1914+ ALTER TABLE proc ENGINE=heap;
1915+ ERROR HY000: Storage engine 'MEMORY' does not support system tables. [mysql.proc]
1916+ ALTER TABLE func ENGINE=csv;
1917+ ERROR HY000: Storage engine 'CSV' does not support system tables. [mysql.func]
1918+ ALTER TABLE event ENGINE=merge;
1919+ ERROR HY000: Storage engine 'MRG_MYISAM' does not support system tables. [mysql.event]
1920+ ALTER TABLE servers ENGINE=innodb;
1921+ ERROR HY000: Storage engine 'InnoDB' does not support system tables. [mysql.servers]
1922+ ALTER TABLE procs_priv ENGINE=memory;
1923+ ERROR HY000: Storage engine 'MEMORY' does not support system tables. [mysql.procs_priv]
1924+ ALTER TABLE tables_priv ENGINE=heap;
1925+ ERROR HY000: Storage engine 'MEMORY' does not support system tables. [mysql.tables_priv]
1926+ ALTER TABLE columns_priv ENGINE=csv;
1927+ ERROR HY000: Storage engine 'CSV' does not support system tables. [mysql.columns_priv]
1928+ ALTER TABLE time_zone ENGINE=merge;
1929+ ERROR HY000: Storage engine 'MRG_MYISAM' does not support system tables. [mysql.time_zone]
1930+ ALTER TABLE help_topic ENGINE=innodb;
1931+ ERROR HY000: Storage engine 'InnoDB' does not support system tables. [mysql.help_topic]
1932+ CREATE TABLE db (dummy int) ENGINE=innodb;
1933+ ERROR HY000: Storage engine 'InnoDB' does not support system tables. [mysql.db]
1934+ CREATE TABLE user (dummy int) ENGINE=memory;
1935+ ERROR HY000: Storage engine 'MEMORY' does not support system tables. [mysql.user]
1936+ CREATE TABLE proc (dummy int) ENGINE=heap;
1937+ ERROR HY000: Storage engine 'MEMORY' does not support system tables. [mysql.proc]
1938+ CREATE TABLE func (dummy int) ENGINE=csv;
1939+ ERROR HY000: Storage engine 'CSV' does not support system tables. [mysql.func]
1940+ CREATE TABLE event (dummy int) ENGINE=merge;
1941+ ERROR HY000: Storage engine 'MRG_MYISAM' does not support system tables. [mysql.event]
1942+ CREATE TABLE servers (dummy int) ENGINE=innodb;
1943+ ERROR HY000: Storage engine 'InnoDB' does not support system tables. [mysql.servers]
1944+ CREATE TABLE procs_priv (dummy int) ENGINE=memory;
1945+ ERROR HY000: Storage engine 'MEMORY' does not support system tables. [mysql.procs_priv]
1946+ CREATE TABLE tables_priv (dummy int) ENGINE=heap;
1947+ ERROR HY000: Storage engine 'MEMORY' does not support system tables. [mysql.tables_priv]
1948+ CREATE TABLE columns_priv (dummy int) ENGINE=csv;
1949+ ERROR HY000: Storage engine 'CSV' does not support system tables. [mysql.columns_priv]
1950+ CREATE TABLE time_zone (dummy int) ENGINE=merge;
1951+ ERROR HY000: Storage engine 'MRG_MYISAM' does not support system tables. [mysql.time_zone]
1952+ CREATE TABLE help_topic (dummy int) ENGINE=innodb;
1953+ ERROR HY000: Storage engine 'InnoDB' does not support system tables. [mysql.help_topic]
1954+ use test;
1955+ # End of Bug#11815557
0 commit comments