If you use backend workflows, it can be very confusing with dates if you schedule a workflow inside backend workflows itself. As you know, Bubble server is UTC. The new timezone will be in UTC and not in your time zone. It changes everything.
Here is an example UTC (Bubble) versus NewYork timezone, value: 02-03-2020 00:00
If you run the schedule by the backend (Bubble server UTC time), the final time will be 10 and not 15, even if you expect 15.
hour change to 15, result: 02-03-2020 10:00
If you run the scheduler from your browser, time result is 15.
hour change to 15, result 02-03-2020 15:00
The tips is… to have the same value with Bubble server or your browser is simply using “add hour” instead of “change hour”. I hope this will save people hours of debugging.
9 Likes
Hi @JohnMark would you know if this is the same behaviour still? I have a workflow that is scheduled at 10PM our time. The workflow schedules itself everyday for the next day 10PM and it seems to be working fine.
But I am not sure if that is just happening by chance or maybe it was because the first instance was initiated by me manually.
I am now setting up another workflow where I am doing a date comparison by “current time: change hours to 0” etc. and wanted to be doubly sure as to whether it will go to UTC time or my time.
Is there an official documentation on this?
Got an answer to my question. Posting it here for others’ benefits.
From Introduction - Bubble Docs
2 Likes
Hey @JohnMark : One question here that I can’t get to know from documentation. I have a few webhooks that run when an external party calls them. Now in that workflow I would like to make some searches with dates in it and would like to get the current time in a certain timezone. How to achieve that? In backend workflow when I do “current time: rounded to date”, I do not get any timezone option, so basically it will run as per UTC which I do not want.
You can define the time zone for each a backend workflow on the workflow itself:
and then use the Current Workflow’s Time Zone wherever you need to.
2 Likes
Thanks @adamhholmes .
I do not see this option. Maybe it is in new version of Bubble which I do not have (just saw this post: [New feature] Advanced options, including advanced timezone controls )
For this I need to upgrade to ver 22
I haven’t upgraded to ver 21 itself as that was breaking my page with some invisible element’s not loading was causing some functionality not working (even though it was just a data source usage). Looks like I need to first debug that, create page to reproduce the issue, raise bug for that, wait for it to be fixed, and then migrate to version 22 to use this feature that you have mentioned.
Hmmm I wonder if there is an alternative out there.
1 Like
Hi. How about database trigger event’s current date/time, is it in UTC +0 or user timezone?
You can select from:
Timezone where the change was triggered
Static choice
Dynamic choice
2 Likes
Thank you @adamhholmes , really helpful advice. Cheers.
1 Like