Forum Academy Marketplace Showcase Pricing Features

Calculated fields in database on upload

Hi there!

I have an existing application with a database, and I’m currently exploring a migration to Bubble. I’m trying to calculate fields on upload, not a result as a workflow.

The app is similar to a social network, with recognitions (posts) and reactions (likes) each as seperate data types. Each reaction is a seperate thing, and has a Recognition ID associated with it.

My immediate use case is that I want to sort the recognitions by most liked, so would like to have the count of the likes as a field, but can’t figure out how!

Many thanks in advance…

Few ideas.

  • Probably best option (I can think of) is to update the like count on posts when a new like is given.
  • Less ideal but feasible is use a backend workflow to do the like count and update a field with counts on the posts when the page opens. You can improve the efficiency by looking at last modified dates. I do this where there is no other option due to the DB design and it works quite nicely.
1 Like

Thanks Lindsay much appreciated!

I’ll try option 1.