Skip to content

Error with text search on memorydb for redis

0

While running field based queried on a text type field in redis index. For eg: query => @fieldName:searchText where fieldName is the name of the text type field and searchText is the lookup text. Getting following error with this query redis.clients.jedis.exceptions.JedisDataException: ERR Parse error at 0 Unexpected @ Expected whitespaces \\n\\t

came across this stack overflow post which says that memory db for redis does not support text based search. https://stackoverflow.com/questions/77742120/redis-unable-to-parse-input-expected-whitespaces

need help to understand if the text search is actually supported, If yes, what is wrong with my query.

asked 10 months ago130 views

1 Answer
-1

Based on the information available, it appears you're encountering an error when trying to use text search syntax with Amazon MemoryDB for Redis.

The error message ERR Parse error at 0 Unexpected @ Expected whitespaces suggests that the syntax you're using (@fieldName:searchText) is not supported in your current MemoryDB configuration.

For vector search capabilities in MemoryDB with Valkey 7.3, you need to explicitly enable the vector search feature when creating your cluster. If you're trying to use commands like FT.CREATE or similar search functionality, and your cluster wasn't created with vector search enabled, you'll receive errors indicating that the command is not supported.

To use vector search in MemoryDB with Valkey, you need to:

  1. Enable the Vector Search capability specifically during cluster creation
  2. Use the appropriate parameter group - when vector search is enabled, you must use default.memorydb-valkey7.search parameter group
  3. Be aware that the number of shards will be fixed when vector search is enabled

If you're receiving the parse error with the @fieldName:searchText syntax, it's likely because this specific query format is not supported in your current MemoryDB configuration or you're trying to use search capabilities that aren't enabled on your cluster.

Check your cluster configuration to ensure vector search is enabled if you need these search capabilities.
Sources
MemoryDB Valkey Vector commands and set up | AWS re:Post

answered 10 months ago

You are not logged in. Log in to post an answer.

A good answer clearly answers the question and provides constructive feedback and encourages professional growth in the question asker.