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

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
yuvaraj86
Frequent Visitor

Convert the dax function now() to local time with DAX

Power BI stores dates and times as a number representing the number of days since 1900-Jan-0 , plus the fractional portion of a 24 hour day: ddddd.tttttt . The values to the left of the decimal place is the number of days and the value to the right of the decimal place is the decimal representation of the 24 hr clock. 

 

So for eg if you want to subtract 4 hrs from the Now() or UTCNOW() function , 4/24 = 0.16667 , so your DAX would be 

now() -  .16667

similarly if you would like to subtract 5 hrs it be 5/24 = 0.20833

now() -  0.20833

 

Hope this helps someone 

1 REPLY 1
harshnathani
Community Champion
Community Champion

Hi @yuvaraj86 ,

 

Thanks , it is really helpful.

 

Also , a link of how it can be done in Power Query

 

https://community.powerbi.com/t5/Desktop/Convert-utc-to-local-time-zone-using-Power-Query/m-p/555571

 

Regards,

Harsh Nathani

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Solution Authors