Current date/time unexpected result!

Hi there! :slight_smile:

First time I seem to encounter a timezone issue and can’t manage to figure it out

I have a simple API workflow in my backend which creates a new account in my user database. Upon creating the new thing, I save the Current date/time in a field “Updated Date”.

I am expecting the default bubble Created Date to be the same as my custom date field Updated Date, but it is not the case…

Updated Date Field
image

Bubble’s default Created date
image

Thanks for the help!

Where are you seeing that?

Thats a screenshot from a random user account database

the fun part when using backend WF with date…
What are your setting in frond end when sending it to backend and what is your setting when receiving the date in your backend WF? Both can have settings for timezone/date stuff.

Nothing special so far, the front-end is simply calling my backend api workflow.

The backend workflow triggers a Create a thing (via the data api). When creating a thing, I save the Current date/time in a “Updated Date” database field.

My goal is to have this updated date field equal to the Created date when adding a new entry in the database, so its not empty.

No. I mean, did you check the box for timezone settings backend WF?
screenshot-bubble.io-2023.12.19-21_48_54

1 Like

Oh sorry yes! Its set to default like the screenshot you sent

So you may change that for your timezone

1 Like

Hmm I tried that but it didn’t changed anything… I think it’s because I am using the Data API to create the new database entry. I’m not sure if there’s a way to select the timezone for the Data API?

I found a “fix” in the meantime which is to use the expression Current Date/Time + 5 hours

hi @raphaelbergeron12 :wave: have you enabled the timezone override controls for your app in the Settings tab? (screengrab below to help you find it)

Yes I have!

Do you get a different response from your API workflow if you turn that setting off?

This topic was automatically closed after 70 days. New replies are no longer allowed.