Forum Discussion
Average Measure/Column Troubleshooting
Hi all,
Thanks so much for taking the time to read this. I am trying to 1) create measures or columns that show the business days and business hours between creation date/time and completion date/time (and replicate this for a few other time stamped fields and display the average time spent) and 2) I want to display the averages of these results that are filtered for different timeframes and groups (likely set up as card or KPI visuals.)
My issues -
1) I appear to be able to calculate the business days )_BizDaysToResolve_), but I can't get these to correctly show an average in any visualization or correctly calculate business hours. I have a date table that the business hour measure references.
2) On the flip side, I am able to show an average on a card for business hours (_AvgBizHoursToResolve), BUT the calculation for the measure/column in the above table doesn't look right.
Calc for business days:
Calc for business hours: (I don't think this is right):
-A
1 Reply
- amitchandakSuper User
acorr , You can use nework Days and calculate at row level like
AVERAGEX(Table, NETWORKDAYS('Export'[CreatedTime] , 'Export'[CompletionTime],1))
Or you can refer this for business Hours
https://exceleratorbi.com.au/calculating-business-hours-using-dax/
for networkdays
Calculating Business Days with and without NETWORKDAYS DAX Function | 2023 Guide: https://www.youtube.com/watch?v=Qs03ZZXXE_c