DateTime field and Time Zone Settings in Salesforce

By | October 30, 2014

Recently, for one of our integration programs we were trying to pass data from our datetime field to the Salesforce datetime field.  We were passing Date as “2014-01-02 00 00 000” but while viewing the same record in the Salesforce User Interface it was displaying the date as “2014-01-01 8 PM”. This posed a big problem for us as the data in this field was of great significance to our integration.  This is because we had to use the dates for range selection.

Get more from Salesforce CRM Salesforce Development Services

We tried a lot of options but in vain. We then queried that object using salesforce developer console and found that the date value stored was actually correct. It was just that while displaying the information in the UI, Salesforce converts the date value to the timezone in which the user profile is configured.

So if the user profile is set to some GMT value, Salesforce automatically adjusts the time that is displayed in the datetime field for that particular timezone. In order to view the actual time that has been passed through the integration we changed the timezone of our user profile to “GMT +00:00” as shown in below screenshot.GMTIn order to do this, navigate to Setup >> Administer >> Manage Users >> Users.  Click on Edit for the required user profile. Go to Locale Settings section and select the timezone from the dropdown. Save the changes. The date field will now display the original time that was passed from the integration.

About Us
Greytrix – a globally recognized and one of the oldest Sage Development Partner and a Salesforce Product development partner offers a wide variety of integration products and services to the end users as well as to the Partners and Sage PSG across the globe. We offer Consultation, Configuration, Training and support services in out-of-the-box functionality as well as customizations to incorporate custom business rules and functionalities that require apex code incorporation into the Salesforce platform.

Greytrix has some unique solutions for Cloud CRM such as Salesforce Sage integration for Sage X3Sage 100 and Sage 300 (Sage Accpac). We also offer best-in-class Cloud CRM Salesforce customization and development services along with services such as Salesforce Data MigrationIntegrated App developmentCustom App development and Technical Support to business partners and end users.
Salesforce Cloud CRM integration offered by Greytrix works with Lightning web components and supports standard opportunity workflow. Greytrix GUMU™ integration for Sage ERP – Salesforce is a 5-star rated app listed on Salesforce AppExchange.

The GUMU™ Cloud framework by Greytrix forms the backbone of cloud integrations that are managed in real-time for processing and execution of application programs at the click of a button.

For more information on our Salesforce products and services, contact us at We will be glad to assist you.

Related Posts