mirror of
https://github.com/MariaDB/server.git
synced 2025-12-24 11:21:21 +03:00
branches/zip: ha_innobase:add_index(): Report HA_ERR_TABLE_EXIST when the
temporary table cannot be created or renamed. innodb-index.test,result: Add test cases where a temporary table already exists.
This commit is contained in:
@@ -46,6 +46,13 @@ t1 CREATE TABLE `t1` (
|
||||
KEY `d2` (`d`),
|
||||
KEY `b` (`b`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=latin1
|
||||
CREATE TABLE `t1#1`(a INT PRIMARY KEY) ENGINE=InnoDB;
|
||||
alter table t1 add unique index (c), add index (d);
|
||||
ERROR HY000: Table 'test/t1@00231' already exists
|
||||
rename table `t1#1` to `t1#2`;
|
||||
alter table t1 add unique index (c), add index (d);
|
||||
ERROR HY000: Table 'test/t1@00232' already exists
|
||||
drop table `t1#2`;
|
||||
alter table t1 add unique index (c), add index (d);
|
||||
show create table t1;
|
||||
Table Create Table
|
||||
|
||||
Reference in New Issue
Block a user