summaryrefslogtreecommitdiff
path: root/mysql-test/t/ndb_rename.test
blob: 99c344bc29ee7ea375bf8acc7b15730137b44e3c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
-- source include/have_ndb.inc
-- source include/not_embedded.inc

--disable_warnings
DROP TABLE IF EXISTS t1,t2;
drop database if exists mysqltest;
--enable_warnings

#
# Table rename tests
#

#
# Create a normal table with primary key
#
CREATE TABLE t1 (
  pk1 INT NOT NULL PRIMARY KEY,
  attr1 INT NOT NULL,
  attr2 INT,
  attr3 VARCHAR(10),
  INDEX i1(attr1)
) ENGINE=ndbcluster;

alter table t1 rename t2;

create database ndbtest;
alter table t2 rename ndbtest.t2;

drop table ndbtest.t2;
drop database ndbtest;

# End of 4.1 tests