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

Score big with last-minute savings on the final tickets to FabCon Vienna. Secure your discount

Reply
manoj_0911
Post Patron
Post Patron

DATE from SQL Server (in PST) treated as UTC when imported into Power BI and published to the

DATE from SQL Server (in PST) treated as UTC when imported into Power BI and published to the service?

 

Hi experts,

I have a question about time zone handling in Power BI.

In my SQL Server source, I have a column called TXN_DATE from the DATE_TIME_V view. This column is already in Pacific Time (PST/PDT) as confirmed by our database administrator.

When I import this data into Power BI Desktop and build my report, it appears to interpret the datetime as UTC (even though it's already PST in the source). Then, when I publish the report to Power BI Service, will it continue to treat the data as UTC? Or will the original PST time be preserved?

I'm especially concerned about:

  • Whether Power BI assumes UTC if no timezone is specified.

  • How this affects incremental refresh, filtering, and scheduled refresh.

  • If I need to manually convert the datetime to PST in Power Query using DateTimeZone.SwitchZone.

What is the best practice to make sure my Power BI report correctly reflects the original PST time from the SQL Server?

Thanks in advance for your help!

1 ACCEPTED SOLUTION
v-agajavelly
Community Support
Community Support

Hi @manoj_0911  ,


Thanks for the clarification. Just to summarize for others who might have a similar scenario.

  • Power BI does treat datetime as UTC internally if no timezone info is explicitly attached.
  • Since the TXN_DATE from SQL Server is already in Pacific Time (PST/PDT), Power BI may misinterpret it as UTC unless handled properly.
  • To preserve the original PST timezone, it’s a best practice to use this step in Power Query.

 Add this in M language.

DateTimeZone.SwitchZone([TXN_DATE], -8) or use -7 during daylight saving time, or make it dynamic.
  • This adjustment is especially important if you're using incremental refresh, time-based filtering, or scheduled refresh in Power BI Service, which all assume UTC by default.

By applying DateTimeZone.SwitchZone, you’re explicitly telling Power BI what the timezone is which avoids unexpected shifts and ensures consistent behavior both in Desktop and Service environments.

If this response helps, consider marking it as “Accept as solution” and giving a “kudos” to assist other community members.

Regards,
Akhil.

View solution in original post

6 REPLIES 6
burakkaragoz
Community Champion
Community Champion

Hi @manoj_0911 ,

 

You need to convert your datetime to datetimezone first, then use SwitchZone. Try this in Power Query:

DateTimeZone.SwitchZone(
    DateTimeZone.From([TXN_DATE]), 
    -8
)

For PST with basic DST handling:

DateTimeZone.SwitchZone(
    DateTimeZone.From([TXN_DATE]), 
    if Date.Month([TXN_DATE]) >= 3 and Date.Month([TXN_DATE]) <= 10 then -7 else -8
)

Why this matters:

  • Power BI Service always uses UTC for scheduled refresh
  • Incremental refresh compares dates in UTC
  • Without proper timezone handling, your time-based filters will be off

The key thing I missed in my research - you can't use SwitchZone directly on datetime fields from SQL. You have to convert to datetimezone first using DateTimeZone.From().

This should keep your times consistent between Desktop and Service.


If my response resolved your query, kindly mark it as the Accepted Solution to assist others. Additionally, I would be grateful for a 'Kudos' if you found my response helpful.

This response was assisted by AI for translation and formatting purposes.

v-agajavelly
Community Support
Community Support

Hey @manoj_0911 ,

Just checking in one last time haven’t seen you back in a while. As per the Microsoft Fabric Community Forum guidelines, we’ll go ahead and close this thread for now. If your issue has already been resolved, that’s great to hear.

But if you still need help down the line whether it’s with incremental refresh, time zone handling, or anything else feel free to create a new post anytime. The community is always here to support you.

Regards,
Akhil.

v-agajavelly
Community Support
Community Support

Hi @manoj_0911 ,

Just looping back one more time were you able to test the DateTimeZone.SwitchZone fix in your Power BI Service setup? If it resolved the issue or if you’ve tried a different approach, it would be great to hear what worked for youit could really help others facing a similar problem. And of course, if you’re still troubleshooting or need help with incremental refresh or time zone logic, happy to jump in and assist further. Looking forward to your update.

Regards,
Akhil.

v-agajavelly
Community Support
Community Support

Hi @manoj_0911 ,

Glad the explanation helped. Just checking back did applying the DateTimeZone. SwitchZone fix the issue for you in Power BI Service? Also, if you're using dynamic daylight saving adjustments or setting this up with scheduled/incremental refresh, happy to help if you run into anything specific. Would it hear if this worked out feel free to update.

Regards,
Akhil.

v-agajavelly
Community Support
Community Support

Hi @manoj_0911  ,


Thanks for the clarification. Just to summarize for others who might have a similar scenario.

  • Power BI does treat datetime as UTC internally if no timezone info is explicitly attached.
  • Since the TXN_DATE from SQL Server is already in Pacific Time (PST/PDT), Power BI may misinterpret it as UTC unless handled properly.
  • To preserve the original PST timezone, it’s a best practice to use this step in Power Query.

 Add this in M language.

DateTimeZone.SwitchZone([TXN_DATE], -8) or use -7 during daylight saving time, or make it dynamic.
  • This adjustment is especially important if you're using incremental refresh, time-based filtering, or scheduled refresh in Power BI Service, which all assume UTC by default.

By applying DateTimeZone.SwitchZone, you’re explicitly telling Power BI what the timezone is which avoids unexpected shifts and ensures consistent behavior both in Desktop and Service environments.

If this response helps, consider marking it as “Accept as solution” and giving a “kudos” to assist other community members.

Regards,
Akhil.

Akash_Varuna
Super User
Super User

Hi @manoj_0911 Power BI treats datetime values as UTC if no timezone is specified, potentially misinterpreting your PST data. Use DateTimeZone.SwitchZone in Power Query to convert the PST datetime explicitly to UTC. This ensures consistency during incremental and scheduled refreshes. Standardizing datetime handling in Power Query helps maintain accurate timezone representation.

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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