[MDEV-23203] SELECT FOR UPDATE with UNION should not need parenthesis Created: 2020-07-17 Updated: 2024-01-23 Resolved: 2020-10-01 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Parser |
| Affects Version/s: | 10.4, 10.5 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Critical |
| Reporter: | Maria M Pflaum | Assignee: | Oleksandr Byelkin |
| Resolution: | Won't Fix | Votes: | 0 |
| Labels: | None | ||
| Environment: |
ALL - but found on CentOS Linux release 7.4.1708 (Core) |
||
| Issue Links: |
|
||||||||
| Description |
|
In 10.3 this statement works:
But in 10.4 it gives this error:
If I use parenthesis it works:
|
| Comments |
| Comment by Oleksandr Byelkin [ 2020-10-01 ] | |||||||||||||||||||||||||||||||||||||||||
|
| |||||||||||||||||||||||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2020-10-01 ] | |||||||||||||||||||||||||||||||||||||||||
|
with limit the same so probably order_limit_lock do not work here
| |||||||||||||||||||||||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2020-10-01 ] | |||||||||||||||||||||||||||||||||||||||||
|
Problem is here, it is the only rule which uses UNION & Co , but in fact it allow only "query_simple" before UNION (via recursion)
| |||||||||||||||||||||||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2020-10-01 ] | |||||||||||||||||||||||||||||||||||||||||
|
OK current grammatic made standard compline:
i.e. now it is impossible without () | |||||||||||||||||||||||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2020-10-01 ] | |||||||||||||||||||||||||||||||||||||||||
|
Forgot to mentioned that loking options connected with LIMIT/ORDER BY (have to be after them) |