You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When using the Typesense driver, the "whereNotIn" constraints are never handled.
Within the "filters" function in TypesenseEngine.php, we can see that it handles the $builder->wheres and $builder->whereIns, but never the $builder->whereNotIns.
It should be as simple as adding a "parseWhereNotInFilter" function that does the same thing as the existing parseWhereInFilter, but changing %s:=[%s] to %s:!=[%s].... and then calling that function in the filters function.
Steps To Reproduce
This works in Typesense. (It returns matching searches where id is 10 or 11)
As Laravel is an open source project, we rely on the community to help us diagnose and fix issues as it is not possible to research and fix every issue reported to us via GitHub.
If possible, please make a pull request fixing the issue you have described, along with corresponding tests. All pull requests are promptly reviewed by the Laravel team.
@alexfierro Just checking in if that PR did indeed fix your problems with whereNotIns, as this issue is still open. If it didn't fix your problem, feel free to provide a reproducible example so I can go into further investigations regarding this
Scout Version
10.11
Scout Driver
Typesense
Laravel Version
11.29
PHP Version
8.2.23
Database Driver & Version
No response
SDK Version
No response
Meilisearch CLI Version
No response
Description
When using the Typesense driver, the "whereNotIn" constraints are never handled.
Within the "filters" function in TypesenseEngine.php, we can see that it handles the
$builder->wheres
and$builder->whereIns
, but never the$builder->whereNotIns
.It should be as simple as adding a "parseWhereNotInFilter" function that does the same thing as the existing parseWhereInFilter, but changing
%s:=[%s]
to%s:!=[%s]
.... and then calling that function in the filters function.Steps To Reproduce
This works in Typesense. (It returns matching searches where id is 10 or 11)
Content::search('foo')->whereIn('id', [10,11])->get();
This does not work as expected. (It returns all matching searches including ones where id is 10 or 11 because whereNotIn is never evaluated.)
Content::search('foo')->whereNotIn('id', [10,11])->get();
The text was updated successfully, but these errors were encountered: