summaryrefslogtreecommitdiff
path: root/mysql-test/main/long_unique_bugs.result
diff options
context:
space:
mode:
authorSachin <sachin.setiya@mariadb.com>2019-03-28 11:33:14 +0530
committerSachin <sachin.setiya@mariadb.com>2019-04-03 12:53:58 +0530
commitba7d33a898d383f19f18733e6c25b029cdc304f3 (patch)
tree41efc174c4f1aab85355f7e88799c101157ca118 /mysql-test/main/long_unique_bugs.result
parentafca4a3a3443e5cabb19034ece00697d3cbdd3b8 (diff)
downloadmariadb-git-ba7d33a898d383f19f18733e6c25b029cdc304f3.tar.gz
MDEV-18820 Assertion `lock_table_has(trx, index->table, LOCK_IX)' failed in lock_rec_insert_check_and_lock upon INSERT into table with blob key
Don't Ignore Any error during index lookup, And throw duplicate key error only if error is HA_ERR_FOUND_DUPP_KEY
Diffstat (limited to 'mysql-test/main/long_unique_bugs.result')
-rw-r--r--mysql-test/main/long_unique_bugs.result26
1 files changed, 26 insertions, 0 deletions
diff --git a/mysql-test/main/long_unique_bugs.result b/mysql-test/main/long_unique_bugs.result
index 87a57fb4614..33496c4e20d 100644
--- a/mysql-test/main/long_unique_bugs.result
+++ b/mysql-test/main/long_unique_bugs.result
@@ -239,3 +239,29 @@ CREATE TABLE t1 (a INT, UNIQUE USING HASH (a)) PARTITION BY HASH (a) PARTITIONS
INSERT INTO t1 VALUES (2);
REPLACE INTO t1 VALUES (2);
DROP TABLE t1;
+set innodb_lock_wait_timeout= 10;
+CREATE TABLE t1 (
+id int primary key,
+f INT unique
+) ENGINE=InnoDB;
+CREATE TABLE t2 (
+id int primary key,
+a blob unique
+) ENGINE=InnoDB;
+START TRANSACTION;
+connect con1,localhost,root,,test;
+connection con1;
+set innodb_lock_wait_timeout= 10;
+START TRANSACTION;
+INSERT INTO t1 VALUES (1,1)/*1*/;
+connection default;
+INSERT INTO t2 VALUES (2, 1)/*2*/ ;
+connection con1;
+INSERT INTO t2 VALUES (3, 1)/*3*/;
+connection default;
+INSERT IGNORE INTO t1 VALUES (4, 1)/*4*/;
+connection con1;
+ERROR 40001: Deadlock found when trying to get lock; try restarting transaction
+disconnect con1;
+connection default;
+DROP TABLE t1, t2;