Dynamodb how to store hashtags

Viewed 282

I'm struggling on this problem. I'm building a typical social network where posts can have one or more hashtags. (eg. I post a picture of my dog with #dog #puppy #animals)

I need then to query:

  • hashtags list ordered by creation date
  • hashtags list that begins_with a word
  • posts list relative to one hashtag

I tried to include hashtag in post table with a StringSet but then I cannot query hashtags that begin with a word. I tried to make a new table "hashtags" but then I cannot get hashtags ordered by creation date.

Any ideas? thank you

0 Answers
Related