I'm planning to have a User
table with UserName
as the hash key and a LastLoginDate
attribute (among others).
I would like to be able to query the table for something like: All users that have not logged in for the last month.
How would I do this with DynamoDB?
I have been looking at local secondary indices, and thought of making LastLoginDate
a secondary index. But how I understand the documentation, secondary indices only help order results for the same hash key, and in my case each user will have a unique UserName
. Does this make such a secondary index pointless?
Thanks in advance!