cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
AW31 Frequent Visitor
Frequent Visitor

Convert Date Column from UTC to Central Time

I am trying to add a date column in Power Query that takes the current date column coming in from DirectQuery (comes in on UTC time) and changes it to Central Time (-5 hours from UTC). I searched similar thread but did not produce the result I was looking for. I either need to convert the Post Time column to a new time zone in a new column, or produce a column with a time that is 5 hours behind the Post Time column. And it has to be produced from a DirectQuery, as I've tried other methods that have produced a number but requires my data to be imported. Thanks!




 Post Time.PNG

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Community Support Team
Community Support Team

Re: Convert Date Column from UTC to Central Time

hi, @AW31 

For your case, I would suggest you create a new calculated column in power bi by DAX as below:

Central Time = 'Table'[Post Time]- TIME(5,0,0)
Regards,
Lin
Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
Highlighted
Community Support Team
Community Support Team

Re: Convert Date Column from UTC to Central Time

hi, @AW31 

For your case, I would suggest you create a new calculated column in power bi by DAX as below:

Central Time = 'Table'[Post Time]- TIME(5,0,0)
Regards,
Lin
Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

AW31 Frequent Visitor
Frequent Visitor

Re: Convert Date Column from UTC to Central Time

This worked 🙂 Thank you!

AW31 Frequent Visitor
Frequent Visitor

Re: Convert Date Column from UTC to Central Time

I can do this in Power BI as a field, but can it be done in Power Query? Basically I'd like to have it as a column there so that it can be used as a slicer with less loading time. As only a created column in the fields section, it is taking longer to populate every row of data because of the calcuation.

Helpful resources

Announcements
Ask Amir Anything

Exclusive LIVE Community Event No. 2 – Ask Amir Anything

Next in our Triple A series: Ask Amir Netz questions about the latest updates, features and future.

October 2019 Community Highlights

October 2019 Community Highlights

October was a busy month in the community. Read the recap article to learn about some of the events and content.

New Solution Badges

New Solution Badges

Two waves of brand new solution badges are coming! Read the article for more information on our new community badges.

Analytics in Azure virtual event

Analytics in Azure virtual event

Experience a limitless analytics service built to ingest, prep, manage, and serve data for immediate use in Power BI.

Users Online
Currently online: 285 members 3,005 guests
Please welcome our newest community members: