Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REGEXP predicate unexpectedly results in an error "No valid regexp pattern found" #16029

Closed
mrigger opened this issue Apr 2, 2020 · 0 comments · Fixed by #16405
Closed

REGEXP predicate unexpectedly results in an error "No valid regexp pattern found" #16029

mrigger opened this issue Apr 2, 2020 · 0 comments · Fixed by #16405

Comments

@mrigger
Copy link

mrigger commented Apr 2, 2020

Consider the following test case:

CREATE TABLE t0(c0 INT);
CREATE TABLE t1(c0 INT);
INSERT INTO t0 VALUES (NULL), (1);
INSERT INTO t1 VALUES (0);
SELECT t0.c0 FROM t0 JOIN t1 ON (t0.c0 REGEXP 1) | t1.c0  WHERE BINARY STRCMP(t1.c0, t0.c0); --  No valid regexp pattern found

Unexpectedly, the SELECT results in an error ERROR 1105 (HY000): No valid regexp pattern found.

Environment:

mysql> select tidb_version();
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| tidb_version()                                                                                                                                                                                                                                                                                          |
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Release Version: v4.0.0-beta.2-167-gaa7ef9c46
Git Commit Hash: aa7ef9c46435bb20d42fa0badcf09fc16f9609a9
Git Branch: master
UTC Build Time: 2020-04-02 09:15:47
GoVersion: go1.13.4
Race Enabled: false
TiKV Min Version: v3.0.0-60965b006877ca7234adaced7890d7b029ed1306
Check Table Before Drop: false |
+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
1 row in set (0.00 sec)
@mrigger mrigger added the type/bug This issue is a bug. label Apr 2, 2020
@github-actions github-actions bot added this to Need Triage in Question and Bug Reports Apr 2, 2020
@zz-jason zz-jason added this to Issue Backlog: Need Triage in SIG Runtime Kanban via automation Apr 3, 2020
@zz-jason zz-jason moved this from Need Triage to Handled to SIGs in Question and Bug Reports Apr 3, 2020
@zz-jason zz-jason moved this from Issue Backlog: Need Triage to Backlog: Release 4.0 in SIG Runtime Kanban Apr 3, 2020
Question and Bug Reports automation moved this from Handled to SIGs to Closed(This Week) Apr 15, 2020
SIG Runtime Kanban automation moved this from Backlog: Release 4.0 to Done (This Week) Apr 15, 2020
@zz-jason zz-jason moved this from Closed(This Week) to Closed(Historical) in Question and Bug Reports Apr 20, 2020
@zz-jason zz-jason moved this from Done (This Week) to Done (Historical) in SIG Runtime Kanban Apr 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
No open projects
SIG Runtime Kanban
  
Done (Historical)
Development

Successfully merging a pull request may close this issue.

4 participants