Field work_end filled 3h earlier than my time zone

renatasanto
Tera Contributor

Hi everyone,

 

I'm creating a rule to automatically populate the work_end field of the sc_task table, but the time zone is 3 hours early. The time zone is correct in the instance settings, and I'm adding the addSeconds function to the script to try to fix it, but it still isn't working.
Does anyone know how I can fix this?

1 REPLY 1

renatasanto
Tera Contributor

Fortunately, I have found the problem. 

 

There was another BR overriding my rule. Here are two tips for everyone:
1. Use the Script Debugger to check if another rule in the table is overriding yours.
2. Use GlideDateTime() in your script, and if the time is incorrect due the time zone, use the addSeconds() function.

 

I hope this helps.
If this answer was helpful, please flag it below.