Skip to content

Commit 2904c02

Browse files
authored
ddl: Update integration test of expr index (#10178)
ref #9891, ref pingcap/tidb#61133 ddl: Fix integration test of expr index TiDB disable the invalid expression index `((null))` from being created by pingcap/tidb#61135. Update the integration test cases Signed-off-by: JaySon-Huang <[email protected]>
1 parent 282c94b commit 2904c02

File tree

1 file changed

+6
-11
lines changed

1 file changed

+6
-11
lines changed

tests/fullstack-test2/ddl/expression_index.test

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
mysql> drop table if exists test.t;
1616

1717
# test for null expression express tiflash#9891
18-
mysql> CREATE TABLE test.t (id int, KEY idx_name ((null)));
18+
mysql> CREATE TABLE test.t (id int);
1919
mysql> alter table test.t set tiflash replica 1;
2020
mysql> insert test.t values(0),(1);
2121

@@ -33,15 +33,10 @@ mysql> set session tidb_isolation_read_engines='tiflash'; select * from test.t o
3333
+----+
3434

3535
mysql> CREATE INDEX idx_n ON test.t ((null));
36-
mysql> alter table test.t add column c1 int;
37-
mysql> set session tidb_isolation_read_engines='tiflash'; select id,c1 from test.t order by id;
38-
+------+------+
39-
| id | c1 |
40-
+------+------+
41-
| 0 | NULL |
42-
| 1 | NULL |
43-
| 2 | NULL |
44-
| 3 | NULL |
45-
+------+------+
36+
ERROR 3761 (HY000) at line 1: The used storage engine cannot index the expression 'null'
37+
38+
mysql> drop table if exists test.t;
4639

40+
mysql> CREATE TABLE test.t (id int, KEY idx_name ((null)));
41+
ERROR 3761 (HY000) at line 1: The used storage engine cannot index the expression 'null'
4742
mysql> drop table if exists test.t;

0 commit comments

Comments
 (0)