Hi there,
I’m another noob doing a test project learning how to use Bubble, and I wondered if a kind Bubbler might help me get on the right course! I’ve been reading the manual and watching videos but a little unsure which direction to go.
Here’s what I’d like the app to do: I have a database of cars where I’ve researched their gas mileage. A user can enter car manufacturer name, model name, and year for 3 different cars and the app will tell you what the gas mileage is for each car. They also enter the cost of gas in their area and the number of miles they drive per day. So once you hit submit it tells you the gas mileage for each car AND how much you’re going to pay in gas per year.
So I’ll need it to do 3 calculations: first - multiply the miles per gallon for each car by the price of gas, second - multiply that figure by the number of miles they drive per day, and third - multiply that figure by 365. Then I’d like that total yearly gas cost to pop up next to each car.
I’ve got my database set up so the user can use drop downs to select 3 cars, but now I’m trying various ways of getting it to A) look up the gas mileage, B) do the calculations, and C) display the total gas cost for each car.
What’s the best way to accomplish this?
Below is my interface so far, and how I have the data organized.
I have 3 tables set up for Manufacturer, Model, and Year. Then I have another table called “Car profile” that includes fields for Manufacturer, Model, and Year and the value for the gas mileage which I will research for each car.
The drop downs are working. So once the user enters the manufacturer, it will only show options in the drop downs that I have a record for in my Car Profiles table. But I’m unsure how to now get it so when I hit submit it it provides the new information based on the calculations. I’m exploring repeating groups and popups. How would you go about this?
Thanks for any help!
Todd