Details
-
Task
-
Status: Open (View Workflow)
-
Major
-
Resolution: Unresolved
-
None
-
None
Description
In our environment we have several types of queries that use the filesort with small LIMIT optimization poorly. It causes some of our major queries to basically full scan the table instead of using a non-orderable index that is more effective. We were previously able to work around this by using "SET STATEMENT optimizer_switch='extended_keys=on FOR" but that has stopped working for us since upgrading from 10.1 to 10.2. I've tried using engine independent statistics, too but that didn't seem to help. We are currently using IGNORE INDEX in some cases but that is not ideal since the index we need to ignore is sometimes useful for filtering. Would it be possible to add an optimizer switch or some other config to control it?
Attachments
Issue Links
- relates to
-
MDEV-8306 Complete cost-based optimization for ORDER BY with LIMIT
- Stalled
-
MDEV-17761 Odd optimizer choice with ORDER BY LIMIT and condition selectivity
- Stalled