If you’re getting an error that reads “LIMIT is only supported in combination with either BYSCORE or BYLEX” it’s probably because you’re trying to use the LIMIT
clause without using the BYSCORE
or BYLEX
arguments.
This can happen when using the VRANGE
command without either of the BYSCORE
or BYLEX
arguments.
To fix this issue, use either the BYSCORE
or BYLEX
argument when using the command. This obviously means that we need to adjust our query so that it’s querying by score or lexicographically.