mirror of
https://github.com/MariaDB/server.git
synced 2025-01-17 20:42:30 +01:00
4fed177276
into neptunus.(none):/home/msvensson/mysql/bug11316/my50-bug11316 mysql-test/mysql-test-run.pl: Auto merged mysql-test/mysql-test-run.sh: Auto merged mysql-test/r/mysqltest.result: Auto merged mysql-test/r/type_newdecimal.result: Auto merged mysql-test/t/create.test: Auto merged mysql-test/t/create_select_tmp.test: Auto merged mysql-test/t/drop.test: Auto merged mysql-test/t/flush.test: Auto merged mysql-test/t/handler.test: Auto merged mysql-test/t/innodb-deadlock.test: Auto merged mysql-test/t/innodb-lock.test: Auto merged mysql-test/t/innodb.test: Auto merged mysql-test/t/kill.test: Auto merged mysql-test/t/ndb_autodiscover2.test: Auto merged mysql-test/t/rpl000001.test: Auto merged mysql-test/t/rpl_EE_error.test: Auto merged mysql-test/t/rpl_change_master.test: Auto merged mysql-test/t/rpl_deadlock.test: Auto merged mysql-test/t/rpl_drop.test: Auto merged mysql-test/t/rpl_drop_temp.test: Auto merged mysql-test/t/rpl_error_ignored_table.test: Auto merged mysql-test/t/rpl_flush_log_loop.test: Auto merged mysql-test/t/rpl_insert_id.test: Auto merged mysql-test/t/rpl_loaddata.test: Auto merged mysql-test/t/rpl_rotate_logs.test: Auto merged mysql-test/t/rpl_sp.test: Auto merged mysql-test/t/rpl_until.test: Auto merged mysql-test/t/strict.test: Auto merged mysql-test/t/type_newdecimal.test: Auto merged client/mysqltest.c: Merge with --parsing-disabled mysql-test/t/mysqltest.test: Manual merge
83 lines
2.1 KiB
Text
83 lines
2.1 KiB
Text
# Initialise
|
|
--disable_warnings
|
|
drop table if exists t1;
|
|
drop database if exists mysqltest;
|
|
# If earlier test failed
|
|
drop database if exists client_test_db;
|
|
--enable_warnings
|
|
|
|
--error 1051
|
|
drop table t1;
|
|
create table t1(n int);
|
|
insert into t1 values(1);
|
|
create temporary table t1( n int);
|
|
insert into t1 values(2);
|
|
--error 1050
|
|
create table t1(n int);
|
|
drop table t1;
|
|
select * from t1;
|
|
|
|
# now test for a bug in drop database - it is important that the name
|
|
# of the table is the same as the name of the database - in the original
|
|
# code this triggered a bug
|
|
create database mysqltest;
|
|
drop database if exists mysqltest;
|
|
create database mysqltest;
|
|
create table mysqltest.mysqltest (n int);
|
|
insert into mysqltest.mysqltest values (4);
|
|
select * from mysqltest.mysqltest;
|
|
--enable_info
|
|
drop database if exists mysqltest;
|
|
--disable_info
|
|
create database mysqltest;
|
|
|
|
#
|
|
# drop many tables - bug#3891
|
|
# we'll do it in mysqltest db, to be able to use longer table names
|
|
# (tableN instead on tN)
|
|
#
|
|
use mysqltest;
|
|
--error 1051
|
|
drop table table1, table2, table3, table4, table5, table6,
|
|
table7, table8, table9, table10, table11, table12, table13,
|
|
table14, table15, table16, table17, table18, table19, table20,
|
|
table21, table22, table23, table24, table25, table26, table27,
|
|
table28;
|
|
|
|
--error 1051
|
|
drop table table1, table2, table3, table4, table5, table6,
|
|
table7, table8, table9, table10, table11, table12, table13,
|
|
table14, table15, table16, table17, table18, table19, table20,
|
|
table21, table22, table23, table24, table25, table26, table27,
|
|
table28, table29, table30;
|
|
|
|
use test;
|
|
drop database mysqltest;
|
|
|
|
# test drop/create database and FLUSH TABLES WITH READ LOCK
|
|
flush tables with read lock;
|
|
--error 1209,1223
|
|
create database mysqltest;
|
|
unlock tables;
|
|
create database mysqltest;
|
|
show databases;
|
|
flush tables with read lock;
|
|
--error 1208,1223
|
|
drop database mysqltest;
|
|
unlock tables;
|
|
drop database mysqltest;
|
|
show databases;
|
|
--error 1008
|
|
drop database mysqltest;
|
|
|
|
# test create table and FLUSH TABLES WITH READ LOCK
|
|
drop table t1;
|
|
flush tables with read lock;
|
|
--error 1223
|
|
create table t1(n int);
|
|
unlock tables;
|
|
create table t1(n int);
|
|
show tables;
|
|
drop table t1;
|
|
|
|
# End of 4.1 tests
|