[MDEV-30590] The bitwise calculation with a negative number in the WHERE statement causes the incorrect result. Created: 2023-02-07 Updated: 2023-03-19 Resolved: 2023-03-19 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Data types |
| Affects Version/s: | 10.5.16 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | Zeng | Assignee: | Sergei Golubchik |
| Resolution: | Cannot Reproduce | Votes: | 0 |
| Labels: | None | ||
| Description |
|
After IS NULL calculation is performed on columns of the VARCHAR type in the WHERE statement, we perform a bitwise calculation with a negative number. Then, we compare the result with the column of the VARCHAR type. The final query result is incorrect. For example, in the following execution,
we miss three items (''), (1865621236), ('qB') when performing SELECT c0 FROM t1 WHERE (((c0 IS NULL) | -1519378307) > c0); . The result is incorrect. |
| Comments |
| Comment by Sergei Golubchik [ 2023-03-19 ] | |||||||||
|
I cannot repeat this result on 10.5 latest:
|