Hello,
please i need help in a formula that might be complicated somehow,
in recap, this sheet have Username, Interval, Chat start time An Chat end time,
i need to export the available time that the agent haven't any chatting time, therefore the agent may have 2 or 3 chat at once,
i have used the below formula to get results, but face a miscalculation,
=IFERROR(IF(COUNTIFS($A$2:$A$6913,A32,$E$2:$E$6913,"<="&D32,$F$2:$F$6913,">="&D32+15/1440),0,15/1440-(MIN(SUMPRODUCT(MAX(($A$2:$A$6913=A32)*($D$2:$D$6913=D32)*($F$2:$F$6913))),D32+15/1440)-MAX(D32,SUMPRODUCT(MIN(100*($A$2:$A$6913<>A32)+100*($D$2:$D$6913<>D32)+($E$2:$E$6913)))))),"")
as shown at interval "11:30:00", the first chat was at "11:32:00", the available time must be 2 minute as per the rest of interval is occupied,
another example: at interval "12:15:00", i have 1 minute as an available time while there is a chat that started from 12:00:00 till 12:26:00,
note: some chats have a long duration, and cross more than one interval need to be considered in the formula,
is that solvable?
we can use Formula or VBA
Gratefully,
please i need help in a formula that might be complicated somehow,
in recap, this sheet have Username, Interval, Chat start time An Chat end time,
i need to export the available time that the agent haven't any chatting time, therefore the agent may have 2 or 3 chat at once,
i have used the below formula to get results, but face a miscalculation,
=IFERROR(IF(COUNTIFS($A$2:$A$6913,A32,$E$2:$E$6913,"<="&D32,$F$2:$F$6913,">="&D32+15/1440),0,15/1440-(MIN(SUMPRODUCT(MAX(($A$2:$A$6913=A32)*($D$2:$D$6913=D32)*($F$2:$F$6913))),D32+15/1440)-MAX(D32,SUMPRODUCT(MIN(100*($A$2:$A$6913<>A32)+100*($D$2:$D$6913<>D32)+($E$2:$E$6913)))))),"")
as shown at interval "11:30:00", the first chat was at "11:32:00", the available time must be 2 minute as per the rest of interval is occupied,
another example: at interval "12:15:00", i have 1 minute as an available time while there is a chat that started from 12:00:00 till 12:26:00,
note: some chats have a long duration, and cross more than one interval need to be considered in the formula,
is that solvable?
we can use Formula or VBA
Gratefully,