Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
Surendra_thota
Helper II
Helper II

Power BI reports on CRM having datetime columns coming in UTC

There  is an Issue with Power BI connection with CRM , the datetime columns are coming in UTC .the workaround currently we implemented is  ( we are in GMT+00:00 Dublin, Edinburgh, Lisbon, London  time zone )

 

  • First created a duplicate of the completion date column
  • Then converted it to datetimezone format
  • Applied the formula in another custom column: DateTimeZone.SwitchZone([#"Completion_Date - Copy"],+1)

 In this work around we are worried about Day Light savings ? how to solve this issue  , is power BI giving permanent solution for this issue 

 

There is another workaround where can convert that column toLocal so that it will take based upon your local setting .

 

  • First created a duplicate of the completion date column to perform test
  • Then converted it to datetimezone format
  • Applied the formula in another custom column: DateTimeZone.ToLocal([#"Completion_Date - Copy"])

 

Still 2nd workaround is giving same UTC value , to how DateTimeZone.ToLocal  works , is it related to 0365 profile settings ?

2 REPLIES 2
v-ljerr-msft
Microsoft Employee
Microsoft Employee

Hi @Surendra_thota,

 

Following is an alternative way to get local time dynamically is by calling an API and use Xml.Document to parse the response(with the correct DST and time zone). Here is the article for your reference. Smiley Happy

 

Here are the steps I figured out:

 

  1. Open your PBIX file and click "Edit Queries"
  2. In the query editor, choose the query used to get the local time. under "Home", click "Advanced Editor". In the editor window, replace your query with this one:

let Source = Xml.Document(Web.Contents("http://api.timezonedb.com/v2/get-time-zone?key=LGN45QRJHMMD&format=xml&by=zone&zone=PDT")),

    Value = Source{0}[Value],

    Value1 = Value{12}[Value]

in

Value

    3.  You will need to replace the highlighted key with your own key (to get your own key, you can register a free account from timezonedb.com, and also replace the zone with your time zone, e.g. for Texas/Dallas, you can use CDT for central daylight saving time).

    4. Then update your report to use the result from this query as local time.



 

Regards

@v-ljerr-msft

 

Is power BI giving permanent solution for this . we are using these reports across our organization , is it the right solution to use 3rd party api in our reports .

 

Thanks

 

Surendra Thota

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.