5
votes

In In DynamoDB, string values are case sensitive. In my app, users can search the db for a profile name. However, if they searched for, say 'alan', then 'Alan' would not be returned in the search results. How can I allow users to specify case insensitive searches to retrieve good results?

FYI: I'm using DynamoDB with Node.js and Express, with AngularJS on the front-end. The script for the scan request to the db sits in an Express route js file; the code to interpret the user request and send to the server is in an AngularJS controller.

1

1 Answers

0
votes

You can hook up your DynamoDB table to AWS ElasticSearch with a Lambda function to stream updates in your table to be indexed. ElasticSearch allows full text and case-insensitive lookups so it is exactly what you are looking for. Here is an example architecture by AWS solution architects. AWS Labs also offers the DynamoDB Logstash plugin that accomplishes the same task.