Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[stable21] tell mysql to ignore the sort index for search queries #29552

Closed
wants to merge 2 commits into from

Conversation

backportbot-nextcloud[bot]
Copy link

backport of #29322

mysql really likes to pick an index for sorting if it can't fully satisfy the where
filter with an index, since search queries pretty much never are fully filtered by index
mysql often picks an index for sorting instead of the *much* more useful index for filtering.

To bypass this, we tell mysql explicitly not to use the mtime (the default order field) index,
so it will instead pick an index that is actually useful.

Signed-off-by: Robin Appelman <[email protected]>
Copy link
Member

@skjnldsv skjnldsv left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Waiting for #29300

@skjnldsv skjnldsv changed the title [stable21] [21] tell mysql to ignore the sort index for search queries [stable21] tell mysql to ignore the sort index for search queries Nov 4, 2021
@skjnldsv skjnldsv added 3. to review Waiting for reviews bug labels Nov 4, 2021
@blizzz
Copy link
Member

blizzz commented Nov 10, 2021

moved to 21.0.7

This was referenced Jan 7, 2022
This was referenced Jan 20, 2022
@blizzz
Copy link
Member

blizzz commented Feb 11, 2022

still waiting

@blizzz
Copy link
Member

blizzz commented Mar 21, 2022

closing. if it should get important again, please reopen.

@blizzz blizzz closed this Mar 21, 2022
@skjnldsv skjnldsv deleted the backport/29322/stable21 branch March 14, 2024 07:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3. to review Waiting for reviews bug
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants