[MDEV-19919] Assertion `!prebuilt->index->is_primary()' failed in row_search_idx_cond_check Created: 2019-07-01 Updated: 2020-01-15 Resolved: 2019-11-26 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Optimizer |
| Affects Version/s: | 10.4 |
| Fix Version/s: | 10.4.11 |
| Type: | Bug | Priority: | Critical |
| Reporter: | Elena Stepanova | Assignee: | Igor Babaev |
| Resolution: | Fixed | Votes: | 2 |
| Labels: | affects-tests | ||
| Issue Links: |
|
||||||||||||||||||||||||||||||||||||||||
| Description |
|
Not reproducible with the provided test case on 10.3. |
| Comments |
| Comment by Marko Mäkelä [ 2019-09-12 ] | ||||||||||||||||||||||||||||||||||||||||||||||
|
The assertion was added by igor in As far as I understand, | ||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Alice Sherepa [ 2019-09-19 ] | ||||||||||||||||||||||||||||||||||||||||||||||
|
igor, could you please check if the following patch fixes the problem from
| ||||||||||||||||||||||||||||||||||||||||||||||
| Comment by richardeaxon [ 2019-10-22 ] | ||||||||||||||||||||||||||||||||||||||||||||||
|
Hi folks, any idea when this will get attention? I get isolated incorrect query results on 10.4 with our application which is bad, but I am not sure what other incorrect results we have lurking due to this. | ||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Igor Babaev [ 2019-11-22 ] | ||||||||||||||||||||||||||||||||||||||||||||||
|
Elena,
I other words I've failed to reproduce the problem with your test case. | ||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Igor Babaev [ 2019-11-22 ] | ||||||||||||||||||||||||||||||||||||||||||||||
|
If I run the test case with mtr I have the reported failure.
While when running the query from the mysql client a plan with table scan is chosen:
We can see that the estimate for number of rows for these two runs are different 23 and 23. Now if I add these two rows to the table t1
I have the plan that uses rowid filter for mysql client as well though the estimate of the table rows are still different (24 - for mysql client, 25 - for mtr). Now the query fails with mysql client as well. Apparently the second table is not needed to get the failure. | ||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Igor Babaev [ 2019-11-23 ] | ||||||||||||||||||||||||||||||||||||||||||||||
|
Using the command
allows to get the same estimate for number of rows in t1 with any run of the above test case. | ||||||||||||||||||||||||||||||||||||||||||||||
| Comment by Igor Babaev [ 2019-11-26 ] | ||||||||||||||||||||||||||||||||||||||||||||||
|
A fix for this bug was pushed into 10.4 |