[MCOL-4740] UPDATE returns wrong "Rows matched" on multi-tables Created: 2021-06-01 Updated: 2023-12-21 Resolved: 2023-12-15 |
|
| Status: | Closed |
| Project: | MariaDB ColumnStore |
| Component/s: | MDB Plugin |
| Affects Version/s: | 5.5.2 |
| Fix Version/s: | 23.10.1 |
| Type: | Bug | Priority: | Critical |
| Reporter: | Yakov Kushnirsky | Assignee: | Roman |
| Resolution: | Fixed | Votes: | 1 |
| Labels: | triage | ||
| Environment: |
Centos 8 |
||
| Issue Links: |
|
||||||||||||||||||||||||||||
| Sprint: | 2021-14, 2021-15, 2021-16, 2023-11 | ||||||||||||||||||||||||||||
| Assigned for Review: | |
||||||||||||||||||||||||||||
| Assigned for Testing: | |
||||||||||||||||||||||||||||
| Description |
|
Multi-tables UPDATE returns "Rows matched: 0" when expected 1. The above happen only if engine=columnstore. Reproduced with Repro: drop table if exists mcs_1; 2) - repro: SELECT ROW_COUNT |
| Comments |
| Comment by David Hall (Inactive) [ 2021-11-19 ] | ||
|
For updates to a single table, we return the counts and they are displayed. This is done by setting the arguments in
But when "SET A.b = B.b", two tables are involved so a completely different code path is followed. The update is performed by the select handler. When this code path is used, the counts come from the count and updated members of class multi_update declared in sql_class.h. These are declared private and Columnstore does not have access. Simply making these available to the engine may not suffice, as the code path inside class multi_update would change. I don't know how this would affect the processing. | ||
| Comment by Hartmut Holzgraefe [ 2022-07-14 ] | ||
|
Any update on this? | ||
| Comment by alexey vorovich (Inactive) [ 2022-09-22 ] | ||
|
Please clarify in which releases it fails and it which it works | ||
| Comment by suresh ramagiri [ 2022-09-25 ] | ||
|
alexey.vorovich, As I noted, locally can repro it at MariaDB ES v10.6.10 columnstore - 6.4.3. A customer reported it on MariaDB ES 10.5/5. | ||
| Comment by Kirill Perov [ 2023-11-14 ] | ||
|
drrtuy, current develop shows: MariaDB [test1]> UPDATE mcs_1 A , mcs_2 B SET A.b = B.b WHERE A.c = B.c LIMIT 1; But mcs_1 was changed. | ||
| Comment by Kirill Perov [ 2023-12-02 ] | ||
|
fixed in latest develop (03.12.2023) testing finished ok |