# No clear solution - Converting date range to list of dates

**URL:** <https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363>\
**Category:** Plugins\
**Created:** [August 29, 2023, 2:22pm UTC](https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363 "2023-08-29T14:22:23Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![james34](https://avatars.discourse-cdn.com/v4/letter/j/3ec8ea/32.png) [@james34](https://forum.bubble.io/u/james34)\
**Post date:** [August 29, 2023, 2:22pm UTC](https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363/1 "2023-08-29T14:22:23Z")

</div>

Hi all, need some help here.

I just need to convert a date range (user input), into a list of dates so that I can run that list of dates through an API workflow.

I’ve found no solution to this forums or plugins. The plug-ins recommended just don’t seem to have clear documentation, or have so much functionality that it would take days to watch each hour-length youtube video!

I’d appreciate help on this - It’s a 2 minute task that’s taking me hours now.

---

<div class="post-metadata">

**Author:** ![georgecollier](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/georgecollier/32/182327_2.png) [@georgecollier](https://forum.bubble.io/u/georgecollier)\
**Post date:** [August 29, 2023, 2:44pm UTC](https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363/2 "2023-08-29T14:44:39Z")

</div>

> **[Bubble - Visual Programming](https://nquforumdemo.bubbleapps.io/version-test/datetimegeneration?debug_mode=true)**
>
> Build stuff without code and launch a startup without a tech-cofounder! Bubble is a visual programing language. Instead of typing code, use a visual editor to build applications.

![CleanShot 2023-08-29 at 16.44.17@2x](https://us1.discourse-cdn.com/bubble/original/3X/0/2/0278fc191157aaaa8b20fa542fb85cbcc73c086b.png)

Editor: [nquforumdemo | Bubble Editor](https://bubble.io/page?type=page&name=datetimegeneration&id=nquforumdemo&tab=tabs-1)

---

<div class="post-metadata">

**Author:** ![firstfifteensoftware](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/firstfifteensoftware/32/152406_2.png) [@firstfifteensoftware](https://forum.bubble.io/u/firstfifteensoftware)\
**Post date:** [August 29, 2023, 3:33pm UTC](https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363/3 "2023-08-29T15:33:21Z")

</div>

I just built this ugly but functional page:

 ![Screenshot 2023-08-29 at 11.26.42 AM](https://us1.discourse-cdn.com/bubble/original/3X/e/2/e23109f123cf4a8e220ef9b870cb64c1549cb7ec.png)

I also built a dummy table to store the dates I created.

The user will select the start and stop date. The RG at the bottom will display the dates created.  
The “populate” button does this:

 ![Screenshot 2023-08-29 at 11.27.50 AM](https://us1.discourse-cdn.com/bubble/original/3X/2/b/2bcd3a8e5ad1a0eaba2ab8ef8f7f2d55555d1068.png)

This is what the API looks like:

 ![Screenshot 2023-08-29 at 11.29.00 AM](https://us1.discourse-cdn.com/bubble/original/3X/0/7/07e340dfdce6e3ee1d849fc37ce05a0a27c7da6f.png)

This is what Step 1 does:

 ![Screenshot 2023-08-29 at 11.29.35 AM](https://us1.discourse-cdn.com/bubble/original/3X/7/9/79838f24205e09b1d3e7e9c11125758e586537a8.png)

This is what step 2 does:

 ![Screenshot 2023-08-29 at 11.30.11 AM](https://us1.discourse-cdn.com/bubble/original/3X/a/1/a11618f0770432ac3dbc2e9188c48dcbc1299562.png)

I run this with the dates 8/15 and 8/25 and I get these rows:

 ![Screenshot 2023-08-29 at 11.32.31 AM](https://us1.discourse-cdn.com/bubble/original/3X/e/c/ec681602a417758e225dc92a2daa47126c0480aa.png)

Hope this helps to at least get the dates generated.

---

<div class="post-metadata">

**Author:** ![firstfifteensoftware](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/firstfifteensoftware/32/152406_2.png) [@firstfifteensoftware](https://forum.bubble.io/u/firstfifteensoftware)\
**Post date:** [August 29, 2023, 3:38pm UTC](https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363/4 "2023-08-29T15:38:26Z")

</div>

Oops.

Forgot to show this. This is what the API call looks like:

 ![Screenshot 2023-08-29 at 11.37.31 AM](https://us1.discourse-cdn.com/bubble/original/3X/f/0/f0df2109a581258c68baf3626f8e4b57d43d307b.png)

---

<div class="post-metadata">

**Author:** ![georgecollier](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/georgecollier/32/182327_2.png) [@georgecollier](https://forum.bubble.io/u/georgecollier)\
**Post date:** [August 29, 2023, 4:05pm UTC](https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363/5 "2023-08-29T16:05:11Z")

</div>

I think this is unnecessarily WU intensive and slow - custom event solution is much faster if you need to generate a list of dates in front end to pass to backend, which I think is what OP is trying to do. It might be appropriate in the backend though if required.

---

<div class="post-metadata">

**Author:** ![james34](https://avatars.discourse-cdn.com/v4/letter/j/3ec8ea/32.png) [@james34](https://forum.bubble.io/u/james34)\
**Post date:** [August 29, 2023, 6:52pm UTC](https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363/7 "2023-08-29T18:52:55Z")

</div>

Hi there!

This definitely seems like the solution. I set up my workflow in the same way as yours but it seems to just loop creating the same date?

Step 1:

 ![image](https://us1.discourse-cdn.com/bubble/original/3X/a/9/a910af0a14164975ada53385278593bab36d35bd.png)

Last step (sends back to step 1 to create next date)  
 ![image](https://us1.discourse-cdn.com/bubble/original/3X/9/2/92ee70ff1802bd882d076e61077d9369fab80b34.png)

workflow:

 ![image](https://us1.discourse-cdn.com/bubble/original/3X/f/a/fad44246b542d768cec093956a2f077708274f0b.png)

output (now stopped as it just seems to keep looping the same info)

 ![image](https://us1.discourse-cdn.com/bubble/original/3X/c/2/c228c057edd544dfc1e9e6f037e9c9548131ec55.png)

The date item no. should increase, but it loops on that same number ?

---

<div class="post-metadata">

**Author:** ![firstfifteensoftware](https://sea1.discourse-cdn.com/bubble/user_avatar/forum.bubble.io/firstfifteensoftware/32/152406_2.png) [@firstfifteensoftware](https://forum.bubble.io/u/firstfifteensoftware)\
**Post date:** [August 29, 2023, 8:36pm UTC](https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363/9 "2023-08-29T20:36:10Z")

</div>

The schedule snapshot you show has the API event create\_event\_dates\_copy.

But your screenshot of the API you are using recursively looks like it’s called create\_event\_dates\_LIST.

Are you calling the right API event? Or am I reading something wrong?

---

<div class="post-metadata">

**Author:** ![james34](https://avatars.discourse-cdn.com/v4/letter/j/3ec8ea/32.png) [@james34](https://forum.bubble.io/u/james34)\
**Post date:** [August 31, 2023, 12:32pm UTC](https://forum.bubble.io/t/no-clear-solution-converting-date-range-to-list-of-dates/280363/10 "2023-08-31T12:32:16Z")

</div>

Hey!

Sometimes Bubble uses the name in the header (it has ‘copy’ in it but it’s cut off), and sometimes Bubble uses the API worflow name ( the first item not in the header).

So it wasn’t that, that’s just naming issues, but I’ll double check!

HOWEVER!

I managed to get this working using some of your methodology so THANK YOU. the crux of it was that I didn’t know there was a simple adding (days) function to just write your own list using some logic. Big thanks on that!
