Bug #53043 | LIKE ANY produces syntax error | ||
---|---|---|---|
Submitted: | 22 Apr 2010 1:22 | Modified: | 6 May 2010 18:05 |
Reporter: | A A | Email Updates: | |
Status: | Closed | Impact on me: | |
Category: | MySQL Server: Documentation | Severity: | S3 (Non-critical) |
Version: | 5.0, 5.1 | OS: | Linux |
Assigned to: | Paul DuBois | CPU Architecture: | Any |
Tags: | ANY, like, syntax error |
[22 Apr 2010 1:22]
A A
[22 Apr 2010 7:50]
Valeriy Kravchuk
In the real grammar (sql/sql_yacc.yy in the sources) comp_op that can be used before ANY does NOT include LIKE. So, this is a documentation problem.
[6 May 2010 18:05]
Paul DuBois
Thank you for your bug report. This issue has been addressed in the documentation. The updated documentation will appear on our website shortly, and will be included in the next release of the relevant products. Added to http://dev.mysql.com/doc/refman/5.5/en/comparisons-using-subqueries.html: MySQL also allows this construct: non_subquery_operand LIKE (subquery) For ANY, LIKE is not allowed, and <=> is not, either. So I have made an addition to http://dev.mysql.com/doc/refman/5.0/en/any-in-some-subqueries.html: Where comparison_operator is one of these operators: = > < >= <= <> !=