[MDEV-10281] Possible regression with STRICT MODE producing warning on WHERE Clause Created: 2016-06-24 Updated: 2016-08-16 Resolved: 2016-08-16 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Optimizer |
| Affects Version/s: | 10.1.14 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Critical |
| Reporter: | VAROQUI Stephane | Assignee: | Alexander Barkov |
| Resolution: | Not a Bug | Votes: | 0 |
| Labels: | None | ||
| Description |
|
Following test case was working in 10.0 and stop executing the last query after migration to 10.1
We would like to understand if the enforcement on strict mode do propagate warnings from read queries and what is the truncation issue in this case ?, |
| Comments |
| Comment by Geoff Montee (Inactive) [ 2016-07-18 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
MariaDB 10.0 output:
MariaDB 10.1 output:
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexander Barkov [ 2016-08-01 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
A smaller script demonstrating difference between 10.0 and 10.1:
The last SELECT query returns no warnings in 10.0 and returns one warning per row (3 warnings total) in 10.1. The problems seems to be in the SQL design. Are there any reasons for "flags" to be of BINARY type, and why is CAST(flags AS BINARY) needed? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Geoff Montee (Inactive) [ 2016-08-09 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Thanks for the response, bar. It sounds like these users may have been a bit confused about how bitwise operators work in MySQL and MariaDB. I think they expected bitwise operators to work without the conversion to bigint, and they were surprised when MariaDB 10.1 started returning warnings for some of these queries, when they seemed to work fine in 10.0. I also submitted this relevant JIRA issue: MDEV-10526. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexander Barkov [ 2016-08-16 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Thanks for creating MDEV-10526! Can I close | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by VAROQUI Stephane [ 2016-08-16 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Yes the workaround was reported and accepted from reporters |