Forum Academy Marketplace Showcase Pricing Features

How to structure this data?

Hi Bubble Forum!

This is my first post, and also my first no-code app I’ll be building using Bubble. By trade, I’m a Designer, but I have a lot of front-end code experience over the years. I’ve also been using Webflow for the past 5 years too.

I’m excited to build my first app and enjoying getting stuck into learning Bubble. I’ve been watching a lot of videos on YouTube and reading the Bubble docs for the past few weeks but as I’m not that experienced in structuring databases and how to present that data to users I’m a little stuck for ideas.

I’m building a Fitness Tracking app for a friend, whereby users can track sets + reps in predetermined workouts. Workouts will likely have 4-6 exercises each, there will be around 12 workouts in total and which workout is presented to the user will be based on questions at signup e.g. their gender, weight and fitness goals.

So my question is, how could I structure the Workout data to present to the user depending on which options they have selected at sign up. I’m thinking that I would have Workouts as a data type, and then show each workout to that user with conditions if they had selected.

So for example: Show [This workout] if the user selected Gender: Male, Goal: Lose Fat, Weight: 80-100kg.

I’m unsure if this is the right approach this being the first time I’ve properly worked with a database architecture so any input or advice would be greatly appreciated :blush:

Many thanks

If workouts are going to be fairly static eg it’s always based on gender, goal and weight rather than a more in depth calculation then I’d probably have a “Workout” data type. Also do you want the user to be able to define their own Goals or will be a static list? If it’s a static list of options then have a _Goal option set, otherwise create it as a new Goal data type. I’d then have Lower Weight and Upper Weight Number fields (I prefer to avoid Numeric Range fields).

Gender _Gender (Option Set)
Goal _Goal (Option Set eg Gain Muscle, Lost Fat etc)
LowerWeight Number
UpperWeight Number

It’d be very easy to query (Do a Search for) to determine the workout by setting constaints based on the user’s input.

I’d then have a Workout field on the person’s record so you’ll know the workout they’ve been assigned.

I hope this helps.

1 Like

Thanks for the reply @gazinhio

This will be quite straightforward static list, around 3-5 set answers e.g. Gain Mass, Fat Loss, Maintain Weight. I had already created each goal as an option set so looks as though I was heading in the right direction.

Excellent – many thanks for the insight! :blush: