Forum Discussion
Measure: Day Average with specific requirements
- 1 year ago
Hi Valentin09 ,
Thank you for reaching out to the Microsoft Fabric Community. I tested the solution using a sample dataset that matches your scenario. The DAX formula you were provided works correctly.
DayAverage_Duration = CALCULATE( AVERAGE(stats_df[total_distance]), FILTER( stats_df, stats_df[activity_participation] = "Full" && NOT stats_df[activity_tag] IN { "Training_Aktivierung", "Lizenz" } ) )Using the sample data
John Doe → 3100
Alex Miller → 3000
The result is (3100 + 3000) /2= 3050, which I verified in Power BI.
FYI:
Thank you for your response govind_021 & mdaatifraza5556 .
If my response resolved your query, kindly mark it as the Accepted Solution to assist others. Additionally, I would be grateful for a 'Kudos' if you found my response helpful.
Hi Valentin09 ,
Thank you for reaching out to the Microsoft Fabric Community. I tested the solution using a sample dataset that matches your scenario. The DAX formula you were provided works correctly.
DayAverage_Duration =
CALCULATE(
AVERAGE(stats_df[total_distance]),
FILTER(
stats_df,
stats_df[activity_participation] = "Full"
&& NOT stats_df[activity_tag] IN { "Training_Aktivierung", "Lizenz" }
)
)
Using the sample data
John Doe → 3100
Alex Miller → 3000
The result is (3100 + 3000) /2= 3050, which I verified in Power BI.
FYI:
Thank you for your response govind_021 & mdaatifraza5556 .
If my response resolved your query, kindly mark it as the Accepted Solution to assist others. Additionally, I would be grateful for a 'Kudos' if you found my response helpful.