Is there a way for me to write these computed columns to another table that stores by user/date for making a chart/graph? I have several actions I could add a set column/new record to, but I am not sure how to point to a specific record and determine if it exists, and if it exists, how to update it rather than write a whole new record. In my mind, I have a method that should work using relations, but not really sure how to set that up.
Yes, one row would be best. As far as I know, I can select the proper column in the table for each graph of things I want to show (calories per day, weight per day, etc.)
Not really sure how to structure it is the thing. I know i’m going to need some relations but… I basically want the computed column of the total calories and weight for each day. Later I may add a column for the water consumption and et cetera. Start small and go big is what I always say. What do you always say?
That way, you don’t need to care about the row orders changing, or much work if you add a new row in the Actions table. Just need a new query JSON column in the destination table to query that new row’s key.
I appreciate the sleekness of this. But I don’t know j s. And so if I change anything in the future it’s sure to break. I was kind of hoping for a glide solution. Also, this particular app is a free app and i’m not sure j s is supported?
What @ThinhDinh offered up doesn’t involve any JavaScript or coding at all. Just a bit of JSON manipulation. Even if there was JavaScript involved, that wouldn’t be a problem because it’s available on all plans.
Thanks again @ThinhDinh. I was/am intimidated by this because I’ve never done it. @Darren_Murphy said it is available on the Free Plan. I will give it a whirl. That’s how you learn, right?
Yes, the Query JSON and JSON Object columns are available on all plans.
Query JSON uses JSONata. If you’re not familiar with JSON, that could be a good place to start. They have a sandbox with lots of sample data to play around with, as well as all the documentation.