function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
emacadieemacadie 

SOQL Dates and TimeZones

What timezone is used for the SOQL dates? Is it UTC? And if I am going to put a date in a query, what timezone should I convert  the dates in my query to?

 

SuperfellSuperfell

SOQL always uses iso8601 formatted dates, e.g. 2011-05-16T11:11:00Z, which include TZ information, it is not assumed. (responses from the server are always in UTC, as indicated by the trailing Z, but in the requests we will honor the TZ info you put).