Forum Discussion
Using Measures for Future Dates in a table
Hi Anonymous ,
I created some data:
You might consider creating a 24-hour interval date table that has no join relationship with the main table, and using measure to display the value
Here are the steps you can follow:
1. Create calculated table.
Date = GENERATESERIES (DATE (2024, 01, 01), NOW(), 0.041666667)
2. Create measure.
availability =
var _select=
SELECTEDVALUE('Date'[Value])
var _DATEDIFF=
DATEDIFF(
_select,MAX('Table'[End Time]),HOUR)
return
IF(
MAX('Table'[End Time])<=_select && MAX('Table'[total working hours]) <= MAX('Table'[assigned time]),MAX('Table'[assigned time]) - MAX('Table'[total working hours]),BLANK())availability hours =
SUMX(
ALLSELECTED('Table'),[availability])
3. Result:
If my explanations don't meet your expected results or don't understand your question, can you share sample data and sample output in table format? Or a sample pbix after removing sensitive data. We can better understand the problem and help you.
Best Regards,
Liu Yang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly
- Anonymous2 years agoNot applicable
I don't think this is quite what I'm after. I'll share some sample data and try and describe what I'm looking for a bit better. I'll share once I've created some sample data.
Many thanks
Sarah