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

Assume text index comparisons are exact #2619

Merged
merged 7 commits into from
Aug 8, 2024
Merged

Conversation

max-hoffman
Copy link
Contributor

@max-hoffman max-hoffman commented Aug 6, 2024

We currently do not eliminate filters of the form column(VARCHAR) = text literal (longtext) when pushing filters into index lookups. The safety check is necessary at least for datetimes, spatial/fulltext and partial TEXT indexes. It's not clear whether it is necessary for full varchar indexes.

dolt side seems OK: dolthub/dolt#8218

@max-hoffman max-hoffman requested a review from zachmu August 7, 2024 21:58
Copy link
Member

@zachmu zachmu left a comment

Choose a reason for hiding this comment

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

Would be nice to add some engine tests targeting this particular kind of index lookup exercising e.g. the tuple type matching logic. I don't care about plans as much, I'm more on the lookout for correctness bugs in this logic.

sql/expression/comparison.go Outdated Show resolved Hide resolved
@max-hoffman max-hoffman merged commit acbef8f into main Aug 8, 2024
7 of 8 checks passed
@max-hoffman max-hoffman deleted the max/text-comparison-exact branch August 8, 2024 15:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants