This is best Fabric, Power BI, SQL and AI community event. How do we know? The last event sold out! Save €200 with code FABCMTY200.
Register nowA new Data Days event is coming soon! This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. Don't miss out.
I've been doing a lot of searching and I can't find any solutions that are working for me...
Two simplify my situation I have two tables, a FACT table and a date table, with the inactive relatioships shown below:
FACT Table
1. Case Number
2. Case Opened Date (Inactive Relationship 1)
3. Case Closed Date (Inactive Relationship 2)
Date Table
1. Date (Inactive Relationship 1/2)
I need to calculate the difference between the Case Opened Date and the Date to arrive at a Case Age. It would be easy enough if the Date was always today's date, but I want the user to be able to filter the report on a given date and see what the age of that case would have been on that date.
Solved! Go to Solution.
Hi @zkeller ,
You might consider using Date Table as a slicer, and using the datediff() function to return the interval between two dates, e.g. year, month, day, etc.
DATEDIFF function (DAX) - DAX | Microsoft Learn
Create measure:
Day_Measure =
var _select=SELECTEDVALUE('Date Table'[Date])
return
DATEDIFF(
MAX('FACT Table'[Case Opened Date]),_select,DAY)Year_Measure =
var _select=SELECTEDVALUE('Date Table'[Date])
return
DATEDIFF(
MAX('FACT Table'[Case Opened Date]),_select,YEAR)
If the above doesn't meet your expectations, 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.
Hi @zkeller ,
You might consider using Date Table as a slicer, and using the datediff() function to return the interval between two dates, e.g. year, month, day, etc.
DATEDIFF function (DAX) - DAX | Microsoft Learn
Create measure:
Day_Measure =
var _select=SELECTEDVALUE('Date Table'[Date])
return
DATEDIFF(
MAX('FACT Table'[Case Opened Date]),_select,DAY)Year_Measure =
var _select=SELECTEDVALUE('Date Table'[Date])
return
DATEDIFF(
MAX('FACT Table'[Case Opened Date]),_select,YEAR)
If the above doesn't meet your expectations, 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.
Check out the May 2026 Power BI update to learn about new features.
Sign up to receive a private message when registration opens and key events begin.
If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.
| User | Count |
|---|---|
| 29 | |
| 25 | |
| 24 | |
| 21 | |
| 14 |
| User | Count |
|---|---|
| 61 | |
| 48 | |
| 26 | |
| 21 | |
| 20 |