This time we’re going bigger than ever. Fabric, Power BI, SQL, AI and more. We're covering it all. You won't want to miss it.
Learn moreLevel up your Power BI skills this month - build one visual each week and tell better stories with data! Get started
I'm sorry to bother you during the weekend. I've been trying to figure this business requirement out.
The intent is to get the Monthly Average in hours based on
1. Average age that are not Closed
2. Average age that are Closed
and use a line chart to indicate the two measures. Similar to the view below. Don't worry about the Month's Initial I can do it.
Duration (Hrs) =
VAR blankclosedates = DATE(1900,1,1)
VAR diffhrs = If('Sample Data'[ClosedDateTime] = blankclosedates, BLANK(),
DATEDIFF('Sample Data'[CreatedDateTime], 'Sample Data'[ClosedDateTime], HOUR))
RETURN diffhrs
///// Looks like simple average will not work
Average Hourly = AVERAGE('Sample Data'[Duration (Hrs)] )
I do have my date table set up inside my model.
Any ideas on how to approach this type of issue? TIA
Solved! Go to Solution.
Hi @v_mark ,
Create a month column.
Month = FORMAT('Sample Data'[Date],"MMMM")
Then create measures.
_closed = CALCULATE(AVERAGE('Sample Data'[Duration (Hrs)]),FILTER(ALLEXCEPT('Sample Data','Sample Data'[Month]),'Sample Data'[Status]="closed"))
not_closed = CALCULATE(AVERAGE('Sample Data'[Duration (Hrs)]),FILTER(ALLEXCEPT('Sample Data','Sample Data'[Month]),'Sample Data'[Status]<>"closed"))
Best Regards,
Jay
Hi @v_mark ,
Create a month column.
Month = FORMAT('Sample Data'[Date],"MMMM")
Then create measures.
_closed = CALCULATE(AVERAGE('Sample Data'[Duration (Hrs)]),FILTER(ALLEXCEPT('Sample Data','Sample Data'[Month]),'Sample Data'[Status]="closed"))
not_closed = CALCULATE(AVERAGE('Sample Data'[Duration (Hrs)]),FILTER(ALLEXCEPT('Sample Data','Sample Data'[Month]),'Sample Data'[Status]<>"closed"))
Best Regards,
Jay
Check out the April 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 |
|---|---|
| 37 | |
| 29 | |
| 29 | |
| 21 | |
| 18 |
| User | Count |
|---|---|
| 68 | |
| 39 | |
| 33 | |
| 24 | |
| 23 |