[MDEV-32275] getting error 'Illegal parameter data types row and bigint for operation '+' ' when using ITERATE in a FOR..DO Created: 2023-07-11 Updated: 2024-02-05 Resolved: 2023-10-04 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Server |
| Affects Version/s: | 10.6.12, 10.6.14 |
| Fix Version/s: | 11.1.1, 10.4.32, 10.5.23, 10.6.16, 10.10.7, 10.11.6, 11.0.4, 11.1.3, 11.2.2, 11.3.1 |
| Type: | Bug | Priority: | Critical |
| Reporter: | Luigi | Assignee: | Alexander Barkov |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | triage | ||
| Environment: |
Ubuntu 20.04.6 LTS |
||
| Issue Links: |
|
||||||||||||||||||||||||
| Description |
|
Hi,
The following procedure was created by the customer to test the ITERATE clause but it's identical to the one used in prod
|
| Comments |
| Comment by Luigi [ 2023-08-11 ] | |||||||||||||||||||||||||||||||||||||||||||
|
julien.fritsch yes I did get the same error in my test installation using the query/procedure provided by the customer. Thanks! | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2023-09-19 ] | |||||||||||||||||||||||||||||||||||||||||||
|
This doesn't seem to be related to query optimization in any way. This belongs to runtime team. | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2023-09-19 ] | |||||||||||||||||||||||||||||||||||||||||||
|
could you provide test suite with no syntax error:
| |||||||||||||||||||||||||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2023-09-19 ] | |||||||||||||||||||||||||||||||||||||||||||
|
Also as mentioned before I do not find '+' operation in the example | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2023-09-19 ] | |||||||||||||||||||||||||||||||||||||||||||
|
Thanks Elena, here is correct test suite with no syntax error:
| |||||||||||||||||||||||||||||||||||||||||||
| Comment by Oleksandr Byelkin [ 2023-09-19 ] | |||||||||||||||||||||||||||||||||||||||||||
|
it 10.4 it also produce interesting error:
| |||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexander Barkov [ 2023-09-20 ] | |||||||||||||||||||||||||||||||||||||||||||
|
There is a wrong instruction in the above output:
_unused@1 is a ROW type variable declared in the FOR header. It's wrong that it gets incremented in the inner loop. | |||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexander Barkov [ 2023-09-20 ] | |||||||||||||||||||||||||||||||||||||||||||
|
The problem seems to be in here:
It checks if we're inside a FOR loop. However, it does not check if this FOR loop in the most inner loop. |