I'm new to deployd.
I have a "ratings" table which basically has an ID
and a ratingValue
(from 1 to 5)
I have a "ratingsSummaryTable" which has ID
, ratingID
(from the ratings table), and five columns n_rating1, n_rating2, n_rating3, n_rating4, n_rating5
I want to be able to update the summary table when ratings
has a new element (onPost
) by
- creating the ratingsSummaryTable row should it not exist
- incrementing the corresponding n_rating&i. (where &i is the rating).
I think this would happen in the event API but I have no clue on how to do it (or even know if it's possible to do it)...
Thanks for your help