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

Match equals #1506

Merged
merged 3 commits into from
Sep 27, 2024
Merged

Match equals #1506

merged 3 commits into from
Sep 27, 2024

Conversation

simon-leech
Copy link
Contributor

@simon-leech simon-leech commented Sep 26, 2024

Match Using =

Description

The match filter type was incorrectly using ILIKE, which is in fact case insensitive and thus not a simple match. ILIKE should be used for the like filter. = should be used for the match filter.

ILIKE is slower as postgres indexes don't always use it, so match should use a simple = that is recognised and indexes are used for this.

I have also updated the sqlFilter tests to test each filter type and assert on the expected filter built.
image

Type of Change

Please delete options that are not relevant, and select all options that apply.

  • ✅ Documentation
  • ✅ Testing

Testing Checklist

Please delete options that are not relevant, and select all options that apply.

  • ✅ Existing Tests still pass
  • ✅ Updated Existing Tests
  • ✅ New Tests Added
  • ✅ Ran locally on my machine

Code Quality Checklist

Please delete options that are not relevant, and select all options that apply.

  • ✅ My code follows the guidelines of XYZ
  • ✅ My code has been commented
  • ✅ Documentation has been updated
  • ✅ New and existing unit tests pass locally with my changes
  • ✅ Main has been merged into this PR

@simon-leech simon-leech marked this pull request as ready for review September 26, 2024 16:46
@simon-leech simon-leech added Code Issues related to the code structure and performance. Documentation Adding or updating documentation. labels Sep 26, 2024
Copy link
Member

@dbauszus-glx dbauszus-glx left a comment

Choose a reason for hiding this comment

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

Working for me on text
image

Integer
image

and numeric fields
image

Copy link

Copy link
Contributor

@RobAndrewHurst RobAndrewHurst left a comment

Choose a reason for hiding this comment

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

Very nice! And good updates of tests in the cli.

@RobAndrewHurst RobAndrewHurst merged commit 7c22e2f into GEOLYTIX:main Sep 27, 2024
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Code Issues related to the code structure and performance. Documentation Adding or updating documentation.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants