Forum Discussion
Calculating difference between two timestamps using DAX
Hi Anonymous thanks for the response.
This is a screenshot of data for these two timestamp columns
and the DAX query I wrote is
Is there any solution to get the same result through DAX query in PowerBI?
Thank you for your help in advance!
Hi yjk3140 are you using Direct Query connection? and what is the data source? It appears that Power BI Data Model does not understand how to convert the DATEDIFF function into Direct Query that you data can understand. Based on the SQL example you provided, you may have to switch to use a UNIX timefunction like this:
Hour Difference = DIVIDE ( Unixtimestamp1 - Unixtimestamp2 , 3600 )
- yjk31403 years agoHelper I
Hi Anonymous , I'm connecting Direct Query to Databricks SQL Endpoint from PowerBI..
How can I get the Unixtimestmp using DAX? As the timestamps I have are not in the format..
really appreciate your help