1
0
mirror of https://github.com/MariaDB/server.git synced 2025-09-02 09:41:40 +03:00

MDEV-11231 Server crashes in check_duplicate_key on CREATE TABLE ... SELECT

be consistent and don't include the table name into the error message,
no other CREATE TABLE error does it.

(the crash happened, because thd->lex->query_tables was NULL)
This commit is contained in:
Sergei Golubchik
2016-12-02 14:34:45 +01:00
parent c5ef621599
commit 7f2fd34500
36 changed files with 286 additions and 280 deletions

View File

@@ -1243,7 +1243,7 @@ alter table t1 add unique(v);
ERROR 23000: Duplicate entry '{ ' for key 'v_2'
alter table t1 add key(v);
Warnings:
Note 1831 Duplicate index 'v_2' defined on the table 'test.t1'. This is deprecated and will be disallowed in a future release.
Note 1831 Duplicate index `v_2`. This is deprecated and will be disallowed in a future release.
select concat('*',v,'*',c,'*',t,'*') as qq from t1 where v='a';
qq
*a*a*a*
@@ -2442,8 +2442,8 @@ SET myisam_repair_threads=2;
SET myisam_sort_buffer_size=4096;
CREATE TABLE t1(a CHAR(255), KEY(a), KEY(a), KEY(a));
Warnings:
Note 1831 Duplicate index 'a_2' defined on the table 'test.t1'. This is deprecated and will be disallowed in a future release.
Note 1831 Duplicate index 'a_3' defined on the table 'test.t1'. This is deprecated and will be disallowed in a future release.
Note 1831 Duplicate index `a_2`. This is deprecated and will be disallowed in a future release.
Note 1831 Duplicate index `a_3`. This is deprecated and will be disallowed in a future release.
INSERT INTO t1 VALUES (0),(1),(2),(3),(4),(5),(6),(7),(8),(9),(0),(1),(2),(3);
REPAIR TABLE t1;
Table Op Msg_type Msg_text