Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
M_B_
New Member

Average Talk Time Issue

Hi

 

I'm trying to calculate average talk time, and am having issues where the call goes into a new day:

 

M_B__0-1635339527677.png

 

My measure is:

Duration Average =

VAR total_second =
AVERAGEX(
CallSummary,
DATEDIFF(CallSummary[wsp_ucc_AcceptedTime],CallSummary[wsp_ucc_EndTime],SECOND)
)

VAR DAXDay = INT(total_second/(24*60*60))
VAR DAXHours = MOD(INT(total_second/(60*60)),24)
VAR DAXMin = MOD(INT(total_second/60),60)
VAR DAXSec = ROUND(MOD(total_second,60),0)

RETURN DAXDay &":"& DAXHours &":"& DAXMin &":"& DAXSec

 

Can anybody see what is wrong with my formula?

 

Thanks!

4 REPLIES 4
Anonymous
Not applicable

Try RETURN DAXDay&":"&TIME(DAXHours, DAXMin, DAXSecond)

 

--Nate

Unfortunately, that still returns strange results:

M_B__0-1636017636401.png

I can see the second part of the calculation has worked correctly. The top call is indeed 17 minutes long, but the first half of the calculation is still adding almost a month to the call time...

As you can see from the next result down on my screenshot, all my other calls are accurate. It's just when the date changes mid-call it can't work it out.

Anonymous
Not applicable

Hello @M_B_ 

 

Have you tried to substract call end time with call start time and represent the value as seconds?

 

 

Hi @Anonymous 

I thought that was essentially what my DATEDIFF was doing within this sum?

 

What formula would I need for a straight subtraction End Time-Accepted Time which would return a value in seconds?

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.

Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.