I have a query that I need to translate from sql to redis. here is an example of this request
id IN(1,2,4,6)
My schema look's like this:
FT.CREATE log // Index name
ON HASH // Indicates the type of data to index
PREFIX 1 "log:" // Tells the index which keys it should index
SCHEMA
id NUMERIC SORTABLE
finfo TEXT NOINDEX
https://redis.io/docs/stack/search/reference/query_syntax/
I saw a couple of examples on a site like this:
@id:(1|2|4|6)
but it doesn't work
I want to use a FILTER to send parameters to FT. module. something like that
FILTER "@id:(1|2|4|6)"
with NUMERIC fields you can try range queries, something like:
depending the format of your ID field it will be better use
TAG
insteadNUMERIC
allowing you to use prefix search like:or using OR operator "pipe" for multiple values such as:
more info at the documentation https://redis.io/docs/stack/search/reference/query_syntax/