[MDEV-8952] Optimizer chooses wrong index for ORDER BY Created: 2015-10-16  Updated: 2023-12-05

Status: Stalled
Project: MariaDB Server
Component/s: Optimizer
Affects Version/s: 5.5, 10.0, 10.1
Fix Version/s: 10.4

Type: Bug Priority: Major
Reporter: Oleksandr Byelkin Assignee: Sergei Petrunia
Resolution: Unresolved Votes: 0
Labels: None

Attachments: File test4.test    
Sprint: 10.1.9-1, 10.1.9-2, 10.1.9-3

 Description   

It thinks that composite index is not good for ordering (WHY???) and so chooses primary one (removing ORDER BY leads to correct index chosen forcing correct index leads to filesort).

Related to https://bugs.launchpad.net/percona-server/+bug/1501457



 Comments   
Comment by Oleksandr Byelkin [ 2015-10-16 ]

10.0 and 5.5 are not checked.

Comment by Oleksandr Byelkin [ 2015-11-04 ]

I was not able to find something valuable, I hope at least test case will help you

Comment by Julien Fritsch [ 2023-12-05 ]

Automated message:
----------------------------
Since this issue has not been updated since 6 weeks, it's time to move it back to Stalled.

Generated at Thu Feb 08 07:31:01 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.