Hello,
I have a task to find the first 100 strings in a set of strings, and the strings should be lexicographically sorted, the number of such elements can be very large.
At the same time in the filter parameters may be a prefix or for example I need to find strings containing a substring.
For this task I decided to use a sorted set.
I would like to know if ZSCAN guarantees that the traversal of sorted set will be in lexicographical order? Or is it better to use ZRANGE and check the prefix and substring in lua?
Hi @ion,
We have just added substring to RediSearch master branch and we expect it to be released in the next minor version.
Your command would look something like FT.SEARCH idx *foo* sortby text_field1 LIMIT 0 100
.
If you use docker, please make sure to grab the edge image (docker pull redislabs/redisearch:latest).
Hey, I have created Treds exactly for this purpose.
Its really fast. Do check it out.