[MDEV-30596] Assertion `pushed_rowid_filter != __null && save_pushed_rowid_filter == __null' failed in handler::disable_pushed_rowid_filter Created: 2023-02-07 Updated: 2023-02-14 Resolved: 2023-02-14 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Optimizer |
| Affects Version/s: | 10.4, 10.5, 10.6, 10.7, 10.8, 10.9, 10.10, 11.0 |
| Fix Version/s: | 10.11.2, 11.0.1, 10.4.29, 10.5.20, 10.6.13, 10.7.8, 10.8.8, 10.9.6, 10.10.4 |
| Type: | Bug | Priority: | Major |
| Reporter: | Alice Sherepa | Assignee: | Sergei Petrunia |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | rowid_filtering | ||
| Description |
|
The test case from
|
| Comments |
| Comment by Sergei Petrunia [ 2023-02-10 ] | |||||||||||||||||||||||||||||||||
|
The EXPLAIN shows
Looks like the interplay between these two features. | |||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2023-02-10 ] | |||||||||||||||||||||||||||||||||
|
Note: for non-partitioned table, the query plan is the same but there's no crash. | |||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2023-02-12 ] | |||||||||||||||||||||||||||||||||
|
ha_partition indicates that it does support Rowid Filter Pushdown:
But ha_partition does not overload rowid_filter_push(), it inherits handler::rowid_filter_push() which does nothing. | |||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2023-02-13 ] | |||||||||||||||||||||||||||||||||
|
... and yet, the SQL layer thinks that the table is using the rowid filter. subselect_single_select_engine::exec tries to disable the rowid filter :
and inside that call we hit the assert:
| |||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2023-02-13 ] | |||||||||||||||||||||||||||||||||
|
A testcase that shows this problem on the current 10.11 vanilla:
| |||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2023-02-13 ] | |||||||||||||||||||||||||||||||||
|
bb-11.0-mdev30596 | |||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2023-02-13 ] | |||||||||||||||||||||||||||||||||
|
Once this is reviewed: it probably affects the versions below 11.0 too. Need to find the least version (10.4 where rowid filter was introduced?) and push the fix where. | |||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2023-02-13 ] | |||||||||||||||||||||||||||||||||
|
10.4 doesn't crash but does show incorrect explain (shows "Using rowid filter" where it won't be used). | |||||||||||||||||||||||||||||||||
| Comment by Sergei Petrunia [ 2023-02-14 ] | |||||||||||||||||||||||||||||||||
|
Got ok to push |