Building Adalo database for Hashtags

Hi all, I’m having trouble creating/updating hashtags on my users’ posts. Here’s how my database looks:

Collections: Users, Posts, Companies, Hashtags

Users <–> Posts is many to 1. Users can have many Posts, a Post belongs to 1 User.
Posts <–> Companies is 1 to many. A Post belongs to 1 Company, a Company can have many Posts.
Posts <–> Hashtags is many to many.
Companies <–> Hashtags is many to many.

I need to:

  1. Create New Hashtags if they don’t already exist. (I’m Creating New Hashtag as an second action from the Create New Post form)
  2. Count the number of Total Posts with a specific Hashtag. (Across all Companies)
  3. Count the number of Company-Specific Posts with a specific Hashtag.

Currently, on the screen with my list of Hashtags, I’m seeing repeats, and my counts are off. And, the Create New Hashtag action isn’t working. Wondering, should I create a custom form instead of using the Create New Post form? I’ve also tried the blank screen trick which Creates/Updates Hashtags.

thanks in advance for your help Adalo-ers!
-tushar

Hi @tdhi!

Your database structure sounds correct. Could you share a screen recording of how the repeats are being created as well as the counts being off?

@Ben thanks! Will do…trying to figure it out on my own first :slight_smile:

@tdhi hi! Are your hashtags searchable? I mean can a User click on one of them (if they are all mentioned in one field) and see the posts belonging to that particular hashtag the way it works in instagram? I would like to implement the same feature as instagram has in my app but am not sure if it is possible to do in Adalo… thanks!