2001-03-27 19:23:04 +02:00
|
|
|
drop table if exists t1;
|
|
|
|
--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;
|
2001-06-22 00:48:18 +02:00
|
|
|
|
2001-12-22 14:13:31 +01:00
|
|
|
# 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
|
|
|
|
drop database if exists mysqltest;
|
|
|
|
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;
|
|
|
|
drop database if exists mysqltest;
|
|
|
|
create database mysqltest;
|
|
|
|
drop database mysqltest;
|
2001-06-22 00:48:18 +02:00
|
|
|
|
|
|
|
# test drop/create database and FLUSH TABLES WITH READ LOCK
|
2001-06-21 23:59:51 +02:00
|
|
|
flush tables with read lock;
|
2001-11-04 14:43:41 +01:00
|
|
|
--error 1209,1223;
|
2001-12-22 14:13:31 +01:00
|
|
|
create database mysqltest;
|
2001-06-21 23:59:51 +02:00
|
|
|
unlock tables;
|
2001-12-22 14:13:31 +01:00
|
|
|
create database mysqltest;
|
2001-06-21 23:59:51 +02:00
|
|
|
show databases;
|
|
|
|
flush tables with read lock;
|
2001-11-04 14:43:41 +01:00
|
|
|
--error 1208,1223;
|
2001-12-22 14:13:31 +01:00
|
|
|
drop database mysqltest;
|
2001-06-21 23:59:51 +02:00
|
|
|
unlock tables;
|
2001-12-22 14:13:31 +01:00
|
|
|
drop database mysqltest;
|
2001-06-21 23:59:51 +02:00
|
|
|
show databases;
|
2001-09-03 04:16:15 +02:00
|
|
|
--error 1008
|
2001-12-22 14:13:31 +01:00
|
|
|
drop database mysqltest;
|