[MDEV-16921] Filtered shows 0 with derived tables/views when optimizer_use_condition_selectivity is set to 3 Created: 2018-08-08 Updated: 2018-09-19 Resolved: 2018-09-19 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Optimizer |
| Affects Version/s: | 10.1, 10.2, 10.3, 10.4 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | Varun Gupta (Inactive) | Assignee: | Varun Gupta (Inactive) |
| Resolution: | Duplicate | Votes: | 0 |
| Labels: | None | ||
| Issue Links: |
|
||||||||
| Description |
|
DATASET
Filtered for table t2 shows 0 which is incorrect as we have 1 row that will satisfy the WHERE clause |
| Comments |
| Comment by Varun Gupta (Inactive) [ 2018-08-10 ] | ||||||||||||||||||||||||||||||||||||||||||
|
When I run ANALYZE on table t2 on the above query and run the same query, filtered is set correctly
| ||||||||||||||||||||||||||||||||||||||||||
| Comment by Varun Gupta (Inactive) [ 2018-08-10 ] | ||||||||||||||||||||||||||||||||||||||||||
|
So in our current approach of EITS ,we try to use the statistics of columns of a table even if we have not calculated them. So we have 2 case which are a bit problematic when we change the defaults to use EITS
| ||||||||||||||||||||||||||||||||||||||||||
| Comment by Varun Gupta (Inactive) [ 2018-08-14 ] | ||||||||||||||||||||||||||||||||||||||||||
|
Patch | ||||||||||||||||||||||||||||||||||||||||||
| Comment by Varun Gupta (Inactive) [ 2018-08-23 ] | ||||||||||||||||||||||||||||||||||||||||||
|
Duplicate of |