Forum Academy Marketplace Showcase Pricing Features

Creating Database entries entries between a start and end date

I would really appreciate any guidance anyone could provide, on how to go about this:

I have an app where you add a start and end date. What I then need to do is create a new dataset based upon these two dates with entries created on a calculated, monthly basis between these two dates.

Is this possible to create these entries into a repeating group, and then write this to the database using a workflow?

Basically I have:
Item 1 Start 01/05/21 End 06/15/21
Item 2 Start 03/20/21 End 09/24/21

What I want to create is:
Item 1 Start 01/05/21 End 01/31/21
Item 1 Start 02/1/21 End 02/28/21
Item 1 Start 03/1/21 End 03/31/21
Item 1 Start 04/1/21 End 04/30/21
Item 1 Start 05/1/21 End 05/31/21
Item 1 Start 06/1/21 End 06/15/21
Item 2 Start 03/20/21 End 03/31/21
Item 2 Start 04/1/21 End 04/30/21
Item 2 Start 05/1/21 End 05/31/21
Item 2 Start 06/1/21 End 06/30/21
Item 2 Start 07/1/21 End 07/31/21
Item 2 Start 08/1/21 End 08/31/21
Item 2 Start 09/1/21 End 09/24/21

Many thanks!

There are several plugins that can help you with this. Have you had a look in the plugin market yet? This is pretty achievable without plugins but takes some “bubble magic”. If you’re creating a booking app, there may be other things you want to consider as well such as not permitting overlapping bookings.

Learn more

Need to have your database located in your region! Tired of struggling with Bubble or API’s? Need a little functionality that’s not available yet thru current market plugins?

Are you ready to step-it-up or speed it along? Need some custom code or a plugin built? Contact me today to learn how to book a 1-on-1 session, get your plugin built, or yet freelance building support!

Thanks Jared. Appreciate the response.

I have had a look for add-ins, couldn’t identify one that one achieve easily, could you recommend?

Not going to be a booking app so dont need to consider double booking at present :blush:

If it is possible without a plugin some guidance on this approach would be ideal!

You will likely not need to create a thing for every dat between start and end. Can you describe your use case a little further.

What you want can be done with client side recursion loops. No plugins needed.

Based on a trigger event you tell the app to create as many things as there are differences between your start and end date and to stop creating things when you’ve created that many things. You create the first thing on your start date and save your start date as a reference date. And then you add a day to that reference day every time you were in the loop so that you’re constantly saving the new start and end time