summaryrefslogtreecommitdiffstats
path: root/mysql-test/suite/innodb_fts
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-18 13:22:53 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-18 13:22:53 +0000
commit347c164c35eddab388009470e6848cb361ac93f8 (patch)
tree2c0c44eac690f510bb0a35b2a13b36d606b77b6b /mysql-test/suite/innodb_fts
parentReleasing progress-linux version 1:10.11.7-4~progress7.99u1. (diff)
downloadmariadb-347c164c35eddab388009470e6848cb361ac93f8.tar.xz
mariadb-347c164c35eddab388009470e6848cb361ac93f8.zip
Merging upstream version 1:10.11.8.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'mysql-test/suite/innodb_fts')
-rw-r--r--mysql-test/suite/innodb_fts/r/create,orig.rdiff11
-rw-r--r--mysql-test/suite/innodb_fts/r/create.result2
-rw-r--r--mysql-test/suite/innodb_fts/r/foreign_key_update.result12
-rw-r--r--mysql-test/suite/innodb_fts/r/innodb-fts-ddl,vers.rdiff57
-rw-r--r--mysql-test/suite/innodb_fts/r/innodb-fts-ddl,vers_trx.rdiff57
-rw-r--r--mysql-test/suite/innodb_fts/r/innodb-fts-fic,vers.rdiff10
-rw-r--r--mysql-test/suite/innodb_fts/r/innodb-fts-fic,vers_trx.rdiff10
-rw-r--r--mysql-test/suite/innodb_fts/r/misc_debug,vers.rdiff66
-rw-r--r--mysql-test/suite/innodb_fts/r/misc_debug,vers_trx.rdiff66
-rw-r--r--mysql-test/suite/innodb_fts/r/sync_ddl,vers.rdiff12
-rw-r--r--mysql-test/suite/innodb_fts/r/sync_ddl,vers_trx.rdiff12
-rw-r--r--mysql-test/suite/innodb_fts/r/sync_ddl.result5
-rw-r--r--mysql-test/suite/innodb_fts/t/create.test6
-rw-r--r--mysql-test/suite/innodb_fts/t/foreign_key_update.test13
-rw-r--r--mysql-test/suite/innodb_fts/t/innodb-fts-ddl.test33
-rw-r--r--mysql-test/suite/innodb_fts/t/innodb-fts-fic.test5
-rw-r--r--mysql-test/suite/innodb_fts/t/misc_debug.test16
-rw-r--r--mysql-test/suite/innodb_fts/t/sync.test2
-rw-r--r--mysql-test/suite/innodb_fts/t/sync_ddl.test5
19 files changed, 392 insertions, 8 deletions
diff --git a/mysql-test/suite/innodb_fts/r/create,orig.rdiff b/mysql-test/suite/innodb_fts/r/create,orig.rdiff
new file mode 100644
index 00000000..e7191646
--- /dev/null
+++ b/mysql-test/suite/innodb_fts/r/create,orig.rdiff
@@ -0,0 +1,11 @@
+--- create.result
++++ create.reject
+@@ -207,7 +207,7 @@
+ UNIQUE KEY `FTS_DOC_ID_INDEX` (`FTS_DOC_ID` DESC)
+ ) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
+ ALTER TABLE t1 ADD FULLTEXT INDEX(b), ALGORITHM=INPLACE;
+-ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
++ERROR HY000: Index 'FTS_DOC_ID_INDEX' is of wrong type for an InnoDB FULLTEXT index
+ ALTER TABLE t1 ADD FULLTEXT INDEX(b), ALGORITHM=COPY;
+ ERROR HY000: Index 'FTS_DOC_ID_INDEX' is of wrong type for an InnoDB FULLTEXT index
+ DROP TABLE t1;
diff --git a/mysql-test/suite/innodb_fts/r/create.result b/mysql-test/suite/innodb_fts/r/create.result
index 4334344a..04fc2019 100644
--- a/mysql-test/suite/innodb_fts/r/create.result
+++ b/mysql-test/suite/innodb_fts/r/create.result
@@ -207,7 +207,7 @@ t1 CREATE TABLE `t1` (
UNIQUE KEY `FTS_DOC_ID_INDEX` (`FTS_DOC_ID` DESC)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 COLLATE=latin1_swedish_ci
ALTER TABLE t1 ADD FULLTEXT INDEX(b), ALGORITHM=INPLACE;
-ERROR HY000: Index 'FTS_DOC_ID_INDEX' is of wrong type for an InnoDB FULLTEXT index
+ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
ALTER TABLE t1 ADD FULLTEXT INDEX(b), ALGORITHM=COPY;
ERROR HY000: Index 'FTS_DOC_ID_INDEX' is of wrong type for an InnoDB FULLTEXT index
DROP TABLE t1;
diff --git a/mysql-test/suite/innodb_fts/r/foreign_key_update.result b/mysql-test/suite/innodb_fts/r/foreign_key_update.result
index f2d47da7..87c21c0b 100644
--- a/mysql-test/suite/innodb_fts/r/foreign_key_update.result
+++ b/mysql-test/suite/innodb_fts/r/foreign_key_update.result
@@ -32,3 +32,15 @@ database
database
DROP TABLE t1_fk;
DROP TABLE t1;
+#
+# MDEV-32346 Assertion failure sym_node->table != NULL
+# in pars_retrieve_table_def on UPDATE
+#
+CREATE TABLE t1 (a INT PRIMARY KEY) ENGINE=InnoDB;
+CREATE TABLE t2 (a INT, b TEXT, FOREIGN KEY(a) REFERENCES t1(a),
+FULLTEXT (b))ENGINE=InnoDB;
+INSERT INTO t1 SET a=1;
+ALTER TABLE t2 DISCARD TABLESPACE;
+UPDATE t1 SET a=2;
+ERROR 23000: Cannot delete or update a parent row: a foreign key constraint fails (`test`.`t2`, CONSTRAINT `t2_ibfk_1` FOREIGN KEY (`a`) REFERENCES `t1` (`a`))
+DROP TABLE t2,t1;
diff --git a/mysql-test/suite/innodb_fts/r/innodb-fts-ddl,vers.rdiff b/mysql-test/suite/innodb_fts/r/innodb-fts-ddl,vers.rdiff
new file mode 100644
index 00000000..d46275ff
--- /dev/null
+++ b/mysql-test/suite/innodb_fts/r/innodb-fts-ddl,vers.rdiff
@@ -0,0 +1,57 @@
+--- innodb-fts-ddl.result
++++ innodb-fts-ddl.reject
+@@ -11,8 +11,10 @@
+ ('MySQL vs. YourSQL','In the following database comparison ...'),
+ ('MySQL Security','When configured properly, MySQL ...');
+ ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
+-ERROR 0A000: ALGORITHM=NOCOPY is not supported for this operation. Try ALGORITHM=INPLACE
+-ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=INPLACE;
++ERROR 0A000: ALGORITHM=NOCOPY is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
++ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body);
++affected rows: 6
++info: Records: 6 Duplicates: 0 Warnings: 0
+ SELECT * FROM fts_test WHERE MATCH (title, body)
+ AGAINST ('Tutorial' IN NATURAL LANGUAGE MODE);
+ id title body
+@@ -26,7 +28,9 @@
+ ('1001 MySQL Tricks','1. Never run mysqld as root. 2. ...'),
+ ('MySQL vs. YourSQL','In the following database comparison ...'),
+ ('MySQL Security','When configured properly, MySQL ...');
+-ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
++ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body);
++affected rows: 12
++info: Records: 12 Duplicates: 0 Warnings: 0
+ SELECT * FROM fts_test WHERE MATCH (title, body)
+ AGAINST ('Tutorial' IN NATURAL LANGUAGE MODE);
+ id title body
+@@ -76,8 +80,10 @@
+ ('MySQL vs. YourSQL','In the following database comparison ...'),
+ ('MySQL Security','When configured properly, MySQL ...');
+ CREATE FULLTEXT INDEX idx on fts_test (title, body) LOCK=NONE;
+-ERROR 0A000: LOCK=NONE is not supported. Reason: Fulltext index creation requires a lock. Try LOCK=SHARED
+-ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
++ERROR 0A000: LOCK=NONE is not supported. Reason: Not implemented for system-versioned operations. Try LOCK=SHARED
++ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body);
++affected rows: 6
++info: Records: 6 Duplicates: 0 Warnings: 0
+ ALTER TABLE fts_test ROW_FORMAT=REDUNDANT, LOCK=NONE;
+ ERROR 0A000: LOCK=NONE is not supported. Reason: Fulltext index creation requires a lock. Try LOCK=SHARED
+ ALTER TABLE fts_test ROW_FORMAT=REDUNDANT;
+@@ -162,7 +168,7 @@
+ (20, 'MySQL Security','When configured properly, MySQL ...');
+ ALTER TABLE articles ADD FULLTEXT INDEX idx (title),
+ ADD FULLTEXT INDEX idx3 (title), ALGORITHM=INPLACE;
+-ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: InnoDB presently supports one FULLTEXT index creation at a time. Try ALGORITHM=COPY
++ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
+ ALTER TABLE articles ADD FULLTEXT INDEX idx (title),
+ ADD FULLTEXT INDEX idx3 (title);
+ affected rows: 6
+@@ -274,7 +280,7 @@
+ call mtr.add_suppression("InnoDB: Failed to create");
+ CREATE TABLE t1(a TEXT, FTS_DOC_ID BIGINT UNSIGNED NOT NULL UNIQUE) ENGINE=InnoDB;
+ ALTER TABLE t1 ADD FULLTEXT(a), ALGORITHM=INPLACE;
+-ERROR HY000: Got error 11 "Resource temporarily unavailable" from storage engine InnoDB
++ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
+ DROP TABLE t1;
+ CREATE TABLE t1 (a VARCHAR(3)) ENGINE=InnoDB;
+ ALTER TABLE t1 ADD FULLTEXT KEY(a), ADD COLUMN b VARCHAR(3), ADD FULLTEXT KEY(b);
diff --git a/mysql-test/suite/innodb_fts/r/innodb-fts-ddl,vers_trx.rdiff b/mysql-test/suite/innodb_fts/r/innodb-fts-ddl,vers_trx.rdiff
new file mode 100644
index 00000000..d46275ff
--- /dev/null
+++ b/mysql-test/suite/innodb_fts/r/innodb-fts-ddl,vers_trx.rdiff
@@ -0,0 +1,57 @@
+--- innodb-fts-ddl.result
++++ innodb-fts-ddl.reject
+@@ -11,8 +11,10 @@
+ ('MySQL vs. YourSQL','In the following database comparison ...'),
+ ('MySQL Security','When configured properly, MySQL ...');
+ ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
+-ERROR 0A000: ALGORITHM=NOCOPY is not supported for this operation. Try ALGORITHM=INPLACE
+-ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=INPLACE;
++ERROR 0A000: ALGORITHM=NOCOPY is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
++ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body);
++affected rows: 6
++info: Records: 6 Duplicates: 0 Warnings: 0
+ SELECT * FROM fts_test WHERE MATCH (title, body)
+ AGAINST ('Tutorial' IN NATURAL LANGUAGE MODE);
+ id title body
+@@ -26,7 +28,9 @@
+ ('1001 MySQL Tricks','1. Never run mysqld as root. 2. ...'),
+ ('MySQL vs. YourSQL','In the following database comparison ...'),
+ ('MySQL Security','When configured properly, MySQL ...');
+-ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
++ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body);
++affected rows: 12
++info: Records: 12 Duplicates: 0 Warnings: 0
+ SELECT * FROM fts_test WHERE MATCH (title, body)
+ AGAINST ('Tutorial' IN NATURAL LANGUAGE MODE);
+ id title body
+@@ -76,8 +80,10 @@
+ ('MySQL vs. YourSQL','In the following database comparison ...'),
+ ('MySQL Security','When configured properly, MySQL ...');
+ CREATE FULLTEXT INDEX idx on fts_test (title, body) LOCK=NONE;
+-ERROR 0A000: LOCK=NONE is not supported. Reason: Fulltext index creation requires a lock. Try LOCK=SHARED
+-ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
++ERROR 0A000: LOCK=NONE is not supported. Reason: Not implemented for system-versioned operations. Try LOCK=SHARED
++ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body);
++affected rows: 6
++info: Records: 6 Duplicates: 0 Warnings: 0
+ ALTER TABLE fts_test ROW_FORMAT=REDUNDANT, LOCK=NONE;
+ ERROR 0A000: LOCK=NONE is not supported. Reason: Fulltext index creation requires a lock. Try LOCK=SHARED
+ ALTER TABLE fts_test ROW_FORMAT=REDUNDANT;
+@@ -162,7 +168,7 @@
+ (20, 'MySQL Security','When configured properly, MySQL ...');
+ ALTER TABLE articles ADD FULLTEXT INDEX idx (title),
+ ADD FULLTEXT INDEX idx3 (title), ALGORITHM=INPLACE;
+-ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: InnoDB presently supports one FULLTEXT index creation at a time. Try ALGORITHM=COPY
++ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
+ ALTER TABLE articles ADD FULLTEXT INDEX idx (title),
+ ADD FULLTEXT INDEX idx3 (title);
+ affected rows: 6
+@@ -274,7 +280,7 @@
+ call mtr.add_suppression("InnoDB: Failed to create");
+ CREATE TABLE t1(a TEXT, FTS_DOC_ID BIGINT UNSIGNED NOT NULL UNIQUE) ENGINE=InnoDB;
+ ALTER TABLE t1 ADD FULLTEXT(a), ALGORITHM=INPLACE;
+-ERROR HY000: Got error 11 "Resource temporarily unavailable" from storage engine InnoDB
++ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
+ DROP TABLE t1;
+ CREATE TABLE t1 (a VARCHAR(3)) ENGINE=InnoDB;
+ ALTER TABLE t1 ADD FULLTEXT KEY(a), ADD COLUMN b VARCHAR(3), ADD FULLTEXT KEY(b);
diff --git a/mysql-test/suite/innodb_fts/r/innodb-fts-fic,vers.rdiff b/mysql-test/suite/innodb_fts/r/innodb-fts-fic,vers.rdiff
new file mode 100644
index 00000000..f9ba2177
--- /dev/null
+++ b/mysql-test/suite/innodb_fts/r/innodb-fts-fic,vers.rdiff
@@ -0,0 +1,10 @@
+--- innodb-fts-fic.result
++++ innodb-fts-fic.reject
+@@ -172,7 +172,6 @@
+ (1, 'MySQL Tutorial','DBMS stands for DataBase ...'),
+ (2, 'How To Use MySQL Well','After you went through a ...');
+ CREATE FULLTEXT INDEX idx ON wp(title, text);
+-ERROR HY000: Column 'FTS_DOC_ID' is of wrong type for an InnoDB FULLTEXT index
+ DROP TABLE wp;
+ CREATE TABLE wp(
+ FTS_DOC_ID bigint unsigned PRIMARY KEY,
diff --git a/mysql-test/suite/innodb_fts/r/innodb-fts-fic,vers_trx.rdiff b/mysql-test/suite/innodb_fts/r/innodb-fts-fic,vers_trx.rdiff
new file mode 100644
index 00000000..f9ba2177
--- /dev/null
+++ b/mysql-test/suite/innodb_fts/r/innodb-fts-fic,vers_trx.rdiff
@@ -0,0 +1,10 @@
+--- innodb-fts-fic.result
++++ innodb-fts-fic.reject
+@@ -172,7 +172,6 @@
+ (1, 'MySQL Tutorial','DBMS stands for DataBase ...'),
+ (2, 'How To Use MySQL Well','After you went through a ...');
+ CREATE FULLTEXT INDEX idx ON wp(title, text);
+-ERROR HY000: Column 'FTS_DOC_ID' is of wrong type for an InnoDB FULLTEXT index
+ DROP TABLE wp;
+ CREATE TABLE wp(
+ FTS_DOC_ID bigint unsigned PRIMARY KEY,
diff --git a/mysql-test/suite/innodb_fts/r/misc_debug,vers.rdiff b/mysql-test/suite/innodb_fts/r/misc_debug,vers.rdiff
new file mode 100644
index 00000000..69294a5a
--- /dev/null
+++ b/mysql-test/suite/innodb_fts/r/misc_debug,vers.rdiff
@@ -0,0 +1,66 @@
+--- misc_debug.result
++++ misc_debug.reject
+@@ -7,14 +7,14 @@
+ SET @saved_debug_dbug = @@SESSION.debug_dbug;
+ SET SESSION debug_dbug="+d,ib_dict_create_index_tree_fail";
+ CREATE FULLTEXT INDEX idx ON articles(body);
+-ERROR HY000: Out of memory.
++ERROR HY000: Can't create table `test`.`articles` (errno: 128 "Out of memory in engine")
+ SET SESSION debug_dbug=@saved_debug_dbug;
+ ALTER TABLE articles STATS_PERSISTENT=DEFAULT;
+ DROP TABLE articles;
+ CREATE TABLE t (a INT, b TEXT) engine=innodb;
+ SET debug_dbug='+d,alter_table_rollback_new_index';
+-ALTER TABLE t ADD FULLTEXT INDEX (b(64));
+-ERROR HY000: Unknown error
++ALTER TABLE t ADD FULLTEXT INDEX (b(64)), ALGORITHM=INPLACE;
++ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
+ SET SESSION debug_dbug=@saved_debug_dbug;
+ DROP TABLE t;
+ CREATE TABLE t1 (pk INT, a VARCHAR(8), PRIMARY KEY(pk),
+@@ -28,32 +28,6 @@
+ DROP TABLE t2, t1;
+ SET SESSION debug_dbug=@saved_debug_dbug;
+ #
+-# MDEV-25200 Index count mismatch due to aborted FULLTEXT INDEX
+-#
+-CREATE TABLE t1(a INT, b TEXT, c TEXT, FULLTEXT INDEX(b)) ENGINE=InnoDB;
+-INSERT INTO t1 VALUES(1, "test", "test_1");
+-connect con1,localhost,root,,test;
+-SET DEBUG_DBUG="+d,innodb_OOM_inplace_alter";
+-SET DEBUG_SYNC='innodb_commit_inplace_alter_table_enter SIGNAL s2 WAIT_FOR g2';
+-ALTER TABLE t1 ADD FULLTEXT(c);
+-connection default;
+-SET DEBUG_SYNC='now WAIT_FOR s2';
+-START TRANSACTION;
+-SELECT * FROM t1;
+-a b c
+-1 test test_1
+-SET DEBUG_SYNC='now SIGNAL g2';
+-connection con1;
+-ERROR HY000: Out of memory.
+-disconnect con1;
+-connection default;
+-SET DEBUG_SYNC=RESET;
+-ALTER TABLE t1 ADD bl INT AS (LENGTH(b)) VIRTUAL;
+-CHECK TABLE t1;
+-Table Op Msg_type Msg_text
+-test.t1 check status OK
+-DROP TABLE t1;
+-#
+ # MDEV-25663 Double free of transaction during TRUNCATE
+ #
+ call mtr.add_suppression("InnoDB: \\(Too many concurrent transactions\\)");
+@@ -65,12 +39,3 @@
+ SET debug_dbug=@saved_debug_dbug;
+ DROP TABLE t1;
+ # End of 10.3 tests
+-CREATE TABLE t1(f1 INT NOT NULL, f2 CHAR(100))ENGINE=InnoDB;
+-SET DEBUG_DBUG="+d,stats_lock_fail";
+-ALTER TABLE t1 ADD FULLTEXT(f2);
+-ERROR HY000: Lock wait timeout exceeded; try restarting transaction
+-SET debug_dbug=@saved_debug_dbug;
+-ALTER TABLE t1 DISCARD TABLESPACE;
+-ALTER TABLE t1 ADD FULLTEXT(f2);
+-ERROR HY000: Tablespace has been discarded for table `t1`
+-DROP TABLE t1;
diff --git a/mysql-test/suite/innodb_fts/r/misc_debug,vers_trx.rdiff b/mysql-test/suite/innodb_fts/r/misc_debug,vers_trx.rdiff
new file mode 100644
index 00000000..69294a5a
--- /dev/null
+++ b/mysql-test/suite/innodb_fts/r/misc_debug,vers_trx.rdiff
@@ -0,0 +1,66 @@
+--- misc_debug.result
++++ misc_debug.reject
+@@ -7,14 +7,14 @@
+ SET @saved_debug_dbug = @@SESSION.debug_dbug;
+ SET SESSION debug_dbug="+d,ib_dict_create_index_tree_fail";
+ CREATE FULLTEXT INDEX idx ON articles(body);
+-ERROR HY000: Out of memory.
++ERROR HY000: Can't create table `test`.`articles` (errno: 128 "Out of memory in engine")
+ SET SESSION debug_dbug=@saved_debug_dbug;
+ ALTER TABLE articles STATS_PERSISTENT=DEFAULT;
+ DROP TABLE articles;
+ CREATE TABLE t (a INT, b TEXT) engine=innodb;
+ SET debug_dbug='+d,alter_table_rollback_new_index';
+-ALTER TABLE t ADD FULLTEXT INDEX (b(64));
+-ERROR HY000: Unknown error
++ALTER TABLE t ADD FULLTEXT INDEX (b(64)), ALGORITHM=INPLACE;
++ERROR 0A000: ALGORITHM=INPLACE is not supported. Reason: Not implemented for system-versioned operations. Try ALGORITHM=COPY
+ SET SESSION debug_dbug=@saved_debug_dbug;
+ DROP TABLE t;
+ CREATE TABLE t1 (pk INT, a VARCHAR(8), PRIMARY KEY(pk),
+@@ -28,32 +28,6 @@
+ DROP TABLE t2, t1;
+ SET SESSION debug_dbug=@saved_debug_dbug;
+ #
+-# MDEV-25200 Index count mismatch due to aborted FULLTEXT INDEX
+-#
+-CREATE TABLE t1(a INT, b TEXT, c TEXT, FULLTEXT INDEX(b)) ENGINE=InnoDB;
+-INSERT INTO t1 VALUES(1, "test", "test_1");
+-connect con1,localhost,root,,test;
+-SET DEBUG_DBUG="+d,innodb_OOM_inplace_alter";
+-SET DEBUG_SYNC='innodb_commit_inplace_alter_table_enter SIGNAL s2 WAIT_FOR g2';
+-ALTER TABLE t1 ADD FULLTEXT(c);
+-connection default;
+-SET DEBUG_SYNC='now WAIT_FOR s2';
+-START TRANSACTION;
+-SELECT * FROM t1;
+-a b c
+-1 test test_1
+-SET DEBUG_SYNC='now SIGNAL g2';
+-connection con1;
+-ERROR HY000: Out of memory.
+-disconnect con1;
+-connection default;
+-SET DEBUG_SYNC=RESET;
+-ALTER TABLE t1 ADD bl INT AS (LENGTH(b)) VIRTUAL;
+-CHECK TABLE t1;
+-Table Op Msg_type Msg_text
+-test.t1 check status OK
+-DROP TABLE t1;
+-#
+ # MDEV-25663 Double free of transaction during TRUNCATE
+ #
+ call mtr.add_suppression("InnoDB: \\(Too many concurrent transactions\\)");
+@@ -65,12 +39,3 @@
+ SET debug_dbug=@saved_debug_dbug;
+ DROP TABLE t1;
+ # End of 10.3 tests
+-CREATE TABLE t1(f1 INT NOT NULL, f2 CHAR(100))ENGINE=InnoDB;
+-SET DEBUG_DBUG="+d,stats_lock_fail";
+-ALTER TABLE t1 ADD FULLTEXT(f2);
+-ERROR HY000: Lock wait timeout exceeded; try restarting transaction
+-SET debug_dbug=@saved_debug_dbug;
+-ALTER TABLE t1 DISCARD TABLESPACE;
+-ALTER TABLE t1 ADD FULLTEXT(f2);
+-ERROR HY000: Tablespace has been discarded for table `t1`
+-DROP TABLE t1;
diff --git a/mysql-test/suite/innodb_fts/r/sync_ddl,vers.rdiff b/mysql-test/suite/innodb_fts/r/sync_ddl,vers.rdiff
new file mode 100644
index 00000000..7834e04c
--- /dev/null
+++ b/mysql-test/suite/innodb_fts/r/sync_ddl,vers.rdiff
@@ -0,0 +1,12 @@
+--- sync_ddl.result
++++ sync_ddl.reject
+@@ -100,7 +100,7 @@
+ ADD COLUMN id2 INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
+ DROP INDEX idx1,
+ ADD FULLTEXT INDEX idx2(value);
+-affected rows: 0
+-info: Records: 0 Duplicates: 0 Warnings: 0
++affected rows: 2
++info: Records: 2 Duplicates: 0 Warnings: 0
+ DROP TABLE t1;
+ SET GLOBAL debug_dbug = @save_debug;
diff --git a/mysql-test/suite/innodb_fts/r/sync_ddl,vers_trx.rdiff b/mysql-test/suite/innodb_fts/r/sync_ddl,vers_trx.rdiff
new file mode 100644
index 00000000..7834e04c
--- /dev/null
+++ b/mysql-test/suite/innodb_fts/r/sync_ddl,vers_trx.rdiff
@@ -0,0 +1,12 @@
+--- sync_ddl.result
++++ sync_ddl.reject
+@@ -100,7 +100,7 @@
+ ADD COLUMN id2 INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
+ DROP INDEX idx1,
+ ADD FULLTEXT INDEX idx2(value);
+-affected rows: 0
+-info: Records: 0 Duplicates: 0 Warnings: 0
++affected rows: 2
++info: Records: 2 Duplicates: 0 Warnings: 0
+ DROP TABLE t1;
+ SET GLOBAL debug_dbug = @save_debug;
diff --git a/mysql-test/suite/innodb_fts/r/sync_ddl.result b/mysql-test/suite/innodb_fts/r/sync_ddl.result
index 441954dc..5ebe1575 100644
--- a/mysql-test/suite/innodb_fts/r/sync_ddl.result
+++ b/mysql-test/suite/innodb_fts/r/sync_ddl.result
@@ -99,7 +99,8 @@ ALTER TABLE t1
DROP COLUMN id1,
ADD COLUMN id2 INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
DROP INDEX idx1,
-ADD FULLTEXT INDEX idx2(value),
-ALGORITHM=INPLACE;
+ADD FULLTEXT INDEX idx2(value);
+affected rows: 0
+info: Records: 0 Duplicates: 0 Warnings: 0
DROP TABLE t1;
SET GLOBAL debug_dbug = @save_debug;
diff --git a/mysql-test/suite/innodb_fts/t/create.test b/mysql-test/suite/innodb_fts/t/create.test
index e6a7e993..9d88c1ed 100644
--- a/mysql-test/suite/innodb_fts/t/create.test
+++ b/mysql-test/suite/innodb_fts/t/create.test
@@ -131,8 +131,14 @@ ENGINE=InnoDB;
CREATE TABLE t1(a INT PRIMARY KEY, b TEXT, FTS_DOC_ID BIGINT UNSIGNED NOT NULL,
UNIQUE KEY FTS_DOC_ID_INDEX(FTS_DOC_ID DESC)) ENGINE=InnoDB;
SHOW CREATE TABLE t1;
+if ($MTR_COMBINATION_ORIG) {
--error ER_INNODB_FT_WRONG_DOCID_INDEX
ALTER TABLE t1 ADD FULLTEXT INDEX(b), ALGORITHM=INPLACE;
+}
+if (!$MTR_COMBINATION_ORIG) {
+--error ER_ALTER_OPERATION_NOT_SUPPORTED_REASON
+ALTER TABLE t1 ADD FULLTEXT INDEX(b), ALGORITHM=INPLACE;
+}
--error ER_INNODB_FT_WRONG_DOCID_INDEX
ALTER TABLE t1 ADD FULLTEXT INDEX(b), ALGORITHM=COPY;
DROP TABLE t1;
diff --git a/mysql-test/suite/innodb_fts/t/foreign_key_update.test b/mysql-test/suite/innodb_fts/t/foreign_key_update.test
index 1f74e640..8a64ac33 100644
--- a/mysql-test/suite/innodb_fts/t/foreign_key_update.test
+++ b/mysql-test/suite/innodb_fts/t/foreign_key_update.test
@@ -32,3 +32,16 @@ SELECT * FROM t1_fk WHERE MATCH(a) AGAINST('database');
DROP TABLE t1_fk;
DROP TABLE t1;
+
+--echo #
+--echo # MDEV-32346 Assertion failure sym_node->table != NULL
+--echo # in pars_retrieve_table_def on UPDATE
+--echo #
+CREATE TABLE t1 (a INT PRIMARY KEY) ENGINE=InnoDB;
+CREATE TABLE t2 (a INT, b TEXT, FOREIGN KEY(a) REFERENCES t1(a),
+ FULLTEXT (b))ENGINE=InnoDB;
+INSERT INTO t1 SET a=1;
+ALTER TABLE t2 DISCARD TABLESPACE;
+--error ER_ROW_IS_REFERENCED_2
+UPDATE t1 SET a=2;
+DROP TABLE t2,t1;
diff --git a/mysql-test/suite/innodb_fts/t/innodb-fts-ddl.test b/mysql-test/suite/innodb_fts/t/innodb-fts-ddl.test
index cef8df2d..11d2d493 100644
--- a/mysql-test/suite/innodb_fts/t/innodb-fts-ddl.test
+++ b/mysql-test/suite/innodb_fts/t/innodb-fts-ddl.test
@@ -20,11 +20,20 @@ INSERT INTO fts_test (title,body) VALUES
('MySQL Security','When configured properly, MySQL ...');
# Table does rebuild when fts index builds for the first time
+# Create the FTS index
+
+if ($MTR_COMBINATION_ORIG) {
--error ER_ALTER_OPERATION_NOT_SUPPORTED
ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
-
-# Create the FTS index
ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=INPLACE;
+}
+if (!$MTR_COMBINATION_ORIG) {
+--error ER_ALTER_OPERATION_NOT_SUPPORTED_REASON
+ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
+--enable_info
+ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body);
+--disable_info
+}
# Select word "tutorial" in the table
SELECT * FROM fts_test WHERE MATCH (title, body)
@@ -43,7 +52,14 @@ INSERT INTO fts_test (title,body) VALUES
('MySQL Security','When configured properly, MySQL ...');
# FTS_DOC_ID hidden column and FTS_DOC_ID index exist
+if ($MTR_COMBINATION_ORIG) {
ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
+}
+if (!$MTR_COMBINATION_ORIG) {
+--enable_info
+ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body);
+--disable_info
+}
# Select word "tutorial" in the table
SELECT * FROM fts_test WHERE MATCH (title, body)
@@ -112,7 +128,14 @@ INSERT INTO fts_test (title,body) VALUES
# column already exists. This has not been implemented yet.
--error ER_ALTER_OPERATION_NOT_SUPPORTED_REASON
CREATE FULLTEXT INDEX idx on fts_test (title, body) LOCK=NONE;
+if ($MTR_COMBINATION_ORIG) {
ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body), ALGORITHM=NOCOPY;
+}
+if (!$MTR_COMBINATION_ORIG) {
+--enable_info
+ALTER TABLE fts_test ADD FULLTEXT `idx` (title, body);
+--disable_info
+}
--error ER_ALTER_OPERATION_NOT_SUPPORTED_REASON
ALTER TABLE fts_test ROW_FORMAT=REDUNDANT, LOCK=NONE;
@@ -349,8 +372,14 @@ let $fts_aux_file= `select concat('FTS_',right(concat(repeat('0',16), lower(hex(
write_file $MYSQLD_DATADIR/test/$fts_aux_file;
EOF
--replace_regex /".*" from/"Resource temporarily unavailable" from/
+if ($MTR_COMBINATION_ORIG) {
--error ER_GET_ERRNO
ALTER TABLE t1 ADD FULLTEXT(a), ALGORITHM=INPLACE;
+}
+if (!$MTR_COMBINATION_ORIG) {
+--error ER_ALTER_OPERATION_NOT_SUPPORTED_REASON
+ALTER TABLE t1 ADD FULLTEXT(a), ALGORITHM=INPLACE;
+}
DROP TABLE t1;
remove_file $MYSQLD_DATADIR/test/$fts_aux_file;
diff --git a/mysql-test/suite/innodb_fts/t/innodb-fts-fic.test b/mysql-test/suite/innodb_fts/t/innodb-fts-fic.test
index 2d94c213..05855106 100644
--- a/mysql-test/suite/innodb_fts/t/innodb-fts-fic.test
+++ b/mysql-test/suite/innodb_fts/t/innodb-fts-fic.test
@@ -211,8 +211,13 @@ INSERT INTO wp (FTS_DOC_ID, title, text) VALUES
(1, 'MySQL Tutorial','DBMS stands for DataBase ...'),
(2, 'How To Use MySQL Well','After you went through a ...');
+if ($MTR_COMBINATION_ORIG) {
--error ER_INNODB_FT_WRONG_DOCID_COLUMN
CREATE FULLTEXT INDEX idx ON wp(title, text);
+}
+if (!$MTR_COMBINATION_ORIG) {
+CREATE FULLTEXT INDEX idx ON wp(title, text);
+}
DROP TABLE wp;
CREATE TABLE wp(
diff --git a/mysql-test/suite/innodb_fts/t/misc_debug.test b/mysql-test/suite/innodb_fts/t/misc_debug.test
index 08581768..8e4ec5d9 100644
--- a/mysql-test/suite/innodb_fts/t/misc_debug.test
+++ b/mysql-test/suite/innodb_fts/t/misc_debug.test
@@ -23,8 +23,14 @@ CREATE TABLE articles (
# The newly create dict_index_t should be removed from fts cache
SET @saved_debug_dbug = @@SESSION.debug_dbug;
SET SESSION debug_dbug="+d,ib_dict_create_index_tree_fail";
+if ($MTR_COMBINATION_ORIG) {
--error ER_OUT_OF_RESOURCES
CREATE FULLTEXT INDEX idx ON articles(body);
+}
+if (!$MTR_COMBINATION_ORIG) {
+--error ER_CANT_CREATE_TABLE
+CREATE FULLTEXT INDEX idx ON articles(body);
+}
SET SESSION debug_dbug=@saved_debug_dbug;
# This simply go through ha_innobase::commit_inplace_alter_table
@@ -37,8 +43,14 @@ DROP TABLE articles;
CREATE TABLE t (a INT, b TEXT) engine=innodb;
SET debug_dbug='+d,alter_table_rollback_new_index';
+if ($MTR_COMBINATION_ORIG) {
-- error ER_UNKNOWN_ERROR
ALTER TABLE t ADD FULLTEXT INDEX (b(64));
+}
+if (!$MTR_COMBINATION_ORIG) {
+-- error ER_ALTER_OPERATION_NOT_SUPPORTED_REASON
+ALTER TABLE t ADD FULLTEXT INDEX (b(64)), ALGORITHM=INPLACE;
+}
SET SESSION debug_dbug=@saved_debug_dbug;
DROP TABLE t;
@@ -57,6 +69,7 @@ ALTER TABLE t1 FORCE;
DROP TABLE t2, t1;
SET SESSION debug_dbug=@saved_debug_dbug;
+if ($MTR_COMBINATION_ORIG) {
--echo #
--echo # MDEV-25200 Index count mismatch due to aborted FULLTEXT INDEX
--echo #
@@ -82,6 +95,7 @@ ALTER TABLE t1 ADD bl INT AS (LENGTH(b)) VIRTUAL;
CHECK TABLE t1;
DROP TABLE t1;
--source include/wait_until_count_sessions.inc
+}
--echo #
--echo # MDEV-25663 Double free of transaction during TRUNCATE
@@ -104,6 +118,7 @@ SET debug_dbug=@saved_debug_dbug;
DROP TABLE t1;
--echo # End of 10.3 tests
+if ($MTR_COMBINATION_ORIG) {
# Fulltext fails in commit phase
CREATE TABLE t1(f1 INT NOT NULL, f2 CHAR(100))ENGINE=InnoDB;
@@ -115,3 +130,4 @@ ALTER TABLE t1 DISCARD TABLESPACE;
--error ER_TABLESPACE_DISCARDED
ALTER TABLE t1 ADD FULLTEXT(f2);
DROP TABLE t1;
+}
diff --git a/mysql-test/suite/innodb_fts/t/sync.test b/mysql-test/suite/innodb_fts/t/sync.test
index 168309a5..56b9052a 100644
--- a/mysql-test/suite/innodb_fts/t/sync.test
+++ b/mysql-test/suite/innodb_fts/t/sync.test
@@ -115,7 +115,7 @@ CREATE TABLE t1 (
INSERT INTO t1(title) VALUES('database');
---exec echo "restart" > $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
+--write_line restart $MYSQLTEST_VARDIR/tmp/mysqld.1.expect
SET debug_dbug = '+d,fts_instrument_sync_debug,fts_write_node_crash';
diff --git a/mysql-test/suite/innodb_fts/t/sync_ddl.test b/mysql-test/suite/innodb_fts/t/sync_ddl.test
index 6a16ecec..9a0451e9 100644
--- a/mysql-test/suite/innodb_fts/t/sync_ddl.test
+++ b/mysql-test/suite/innodb_fts/t/sync_ddl.test
@@ -182,12 +182,13 @@ INSERT INTO t1 (value) VALUES
('collation of latin1_bin to make it case sensitive')
;
+--enable_info
ALTER TABLE t1
DROP COLUMN id1,
ADD COLUMN id2 INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
DROP INDEX idx1,
- ADD FULLTEXT INDEX idx2(value),
- ALGORITHM=INPLACE;
+ ADD FULLTEXT INDEX idx2(value);
+--disable_info
DROP TABLE t1;