spatie / laravel-query-builder

Easily build Eloquent queries from API requests

Home Page:https://spatie.be/docs/laravel-query-builder

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

FiltersPartial index miss

oceanapplications opened this issue · comments

FiltersPartial is using LOWER() which causes index misses. Many collations are case insensitive so LOWER() is not necessary.

The LIKE expression uses % before the search value which also cases index misses. This is necessary at times but if it could be used optionally that would be ideal.

Perhaps instead of just FiltersPartial, we add FiltersBeginsWith and FiltersEndsWith as options to place % only at the beginning or end.