Issues with Using the OR Operator in Filter Query
TLDR Mehdi inquired about using OR in a filter query and was told by Kishore Nallan that only AND is supported. Ricardo suggested the use of multisearch and dedup, while Mehdi decided to modify the document's fields.
1
1
Jul 07, 2021 (31 months ago)
Mehdi
09:08 AMIs there a way to pass an or expression to the filter_by argument? Using "||" or "|" returns an Error 400 Could not parse the filter query
Kishore Nallan
09:09 AM1
Mehdi
09:10 AMKishore Nallan
09:11 AM&&
so you can do ANDing of conditions on two different fields, but can't do OR.Kishore Nallan
09:12 AMstore_id: [100, 200, 300]
Ricardo
09:13 AMMehdi
09:37 AMKishore Nallan
09:38 AM1
Typesense
Indexed 3015 threads (79% resolved)
Similar Threads
Query on Typesense Support for Grouped Filter_by Functionality
Claudiu asked if typesense supports grouped filter_by. Kishore Nallan responded that it doesn't currently, but it's in their future plan. Jason suggested a temporary workaround.
Multiple Filters and JSON Requests in Typesense
Manish asked about multiple filter_by arguments, JSON input, and using multisearch. Jason offered typesense documentation links, examples, and how to use JSON formatted requests with multisearch. Ed shared a similar use case.
Performance Characteristics of Filtering Search Results
Oskar queries the performance difference in filtering search results. Jason clarifies how filters work and provides performance improvement suggestions like increasing vCPUs and sharding the collection. Kishore Nallan explains filter IDs and document ID matching. The thread concludes with discussions on performance tradeoffs in filter implementation.
Queries on String Sorting, Filter_by Operators and Typesense updates
Ishan asked about OR operators in TypeSense's filter_by fields and string sorting. Kishore Nallan clarified these functionalities. A workaround was proposed for cross-field ORs by Jason. This is on TypeSense's mid-term roadmap.
Typesense Cloud Filter Expression Issue
Samuel experienced a "Filter expression is not valid" error on a previously working query. Kishore Nallan assisted in troubleshooting and discovered it was a Scoped Search token formatting issue on Samuel's end.