[MDEV-31616] Problems with a stored function EMPTY() on upgrade to 10.6 Created: 2023-07-04 Updated: 2024-01-24 Resolved: 2024-01-24 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | JSON, Stored routines |
| Affects Version/s: | 10.6, 10.7, 10.8, 10.9, 10.10, 10.11, 11.0, 11.1, 11.2 |
| Fix Version/s: | 10.6.17, 10.11.7, 11.0.5, 11.1.4, 11.2.3 |
| Type: | Bug | Priority: | Blocker |
| Reporter: | Alexander Barkov | Assignee: | Alexey Botchkov |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | regression-10.6 | ||
| Issue Links: |
|
||||||||
| Description |
|
This script:
used to work without any unexpected side effects prior to 10.6:
Starting from 10.6, behavior changed: The CREATE statement now raises a warnings:
The warning is not correct. 'empty' is not a native function! It's only a new 10.6 non-reserved keyword. There should not be any warnings. The SELECT statement now raises a syntax error:
This is wrong. No errors expected. These behavior changes raise problems on upgrade. The problem was caused by Other keywords added in
|
| Comments |
| Comment by Alexey Botchkov [ 2023-12-18 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
proposed fix | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexey Botchkov [ 2024-01-22 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
https://github.com/MariaDB/server/commit/4ec01ec186aa93d4e7259bb4e8fc660a47b9d900 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexander Barkov [ 2024-01-23 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Hi holyfoot, These tests fail for me in your branch: ./mtr \ Can you please check? | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexander Barkov [ 2024-01-23 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Hello holyfoot, The patch looks very good for me. I'd like only to ask to rename grammar rules as follows, please:
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexander Barkov [ 2024-01-23 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Also, the rule keyword_funcname does not seem to be needed. Please just include its parts into ident_cli_funcname directly. Collecting all together, I suggest this incremental patch:
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexander Barkov [ 2024-01-23 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Can you please also add stored function MTR tests with the following tokens added in
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexey Botchkov [ 2024-01-23 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Please see the updated patch. | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alexander Barkov [ 2024-01-24 ] | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Hello holyfoot, This patch: Ok to push after fixing two small issues:
|