~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to mysql-test/t/renamedb.test

  • Committer: brian
  • Date: 2008-06-25 05:29:13 UTC
  • Revision ID: brian@localhost.localdomain-20080625052913-6upwo0jsrl4lnapl
clean slate

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
 
 
2
# TODO: enable these tests when RENAME DATABASE is implemented.
 
3
#
 
4
# --disable_warnings
 
5
# drop database if exists testdb1;
 
6
# --enable_warnings
 
7
 
8
# create database testdb1 default character set latin2;
 
9
# use testdb1;
 
10
# create table t1 (a int);
 
11
# insert into t1 values (1),(2),(3);
 
12
# show create database testdb1;
 
13
# show tables;
 
14
# rename database testdb1 to testdb2;
 
15
# --error 1049
 
16
# show create database testdb1;
 
17
# show create database testdb2;
 
18
# select database();
 
19
# show tables;
 
20
# select a from t1 order by a;
 
21
# drop database testdb2;
 
22
 
23
#
 
24
# Bug#19392 Rename Database: Crash if case change
 
25
#
 
26
# create database testdb1;
 
27
# --error 1007
 
28
# rename database testdb1 to testdb1;
 
29
# drop database testdb1;
 
30
 
 
31
#
 
32
# WL#4030 (Deprecate RENAME DATABASE: replace with ALTER DATABASE <name> UPGRADE)
 
33
#
 
34
 
 
35
--error ER_PARSE_ERROR
 
36
rename database testdb1 to testdb2;
 
37
 
 
38
--error ER_WRONG_USAGE
 
39
ALTER DATABASE wrong UPGRADE DATA DIRECTORY NAME;
 
40
 
 
41
--error ER_WRONG_USAGE
 
42
ALTER DATABASE `#mysql41#not-supported` UPGRADE DATA DIRECTORY NAME;
 
43
 
 
44
--error ER_WRONG_USAGE
 
45
ALTER DATABASE `#mysql51#not-yet` UPGRADE DATA DIRECTORY NAME;
 
46
 
 
47
--error ER_WRONG_USAGE
 
48
ALTER DATABASE `#mysql50#` UPGRADE DATA DIRECTORY NAME;
 
49
 
 
50
--error ER_BAD_DB_ERROR
 
51
ALTER DATABASE `#mysql50#upgrade-me` UPGRADE DATA DIRECTORY NAME;
 
52
 
 
53