Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
All,
I have a set of reports that i configured to read data from a given application database. I love using the DirectQuery mode for these reports, as I query from a DR instance which is fresh enough to be useful, but doesn't negatively impact performance of the production database.
That said, I am getting data back with several columns containing time data. These would be start times for various steps, and they are stored in their own columns.
I am trying to find a method to calculate the difference in two time column values for each row. Simplified, any given row will have a schedueld time, an actual start time, and a completed time. I am looking to measure the time difference between at least two of them to then visualize the elapsed time that was calculated, per row.
I found a couple of options - quick measures, but couldn't get it to properly measure the time difference instead of automatically reverting to counts. Maybe i am doing it wrong?
I found an option to create a custom column and appropriately create a formula. in that case, it worked, but forced the storage mode to import, instead of directquery. I'd really like to avoid that option - but that is why I am reaching out here, to see if i can find an alternative that gets me the data I want, without having to change out of DirectQuery.
Thoughts?
You could consider this DAX function and use it in a measure.
Syntax:
DATEDIFF(<start_date>, <end_date>, <interval>)
It returns the count of interval boundaries crossed between two dates.
Best Regards
Maggie
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
110 | |
94 | |
80 | |
67 | |
59 |
User | Count |
---|---|
150 | |
119 | |
104 | |
87 | |
67 |