The stock "Agent Historical All Fields" report gives the LoggedOnTime*Number of skill groups, e.g. 14:16:45*8 = 114:14:00
I want to see LoggedOnTime for a number of SG´s that I´ve filtered out at the parameters.
The reason why is that we´re reporting some Skill Groups separately but some Advisors are doing all skill groups at the same time. In order to separate them in some way (and I´m calculating some figures based on LoggedOnTime) I need to do it this way.
I tried it like this but it doesnt seem like the COUNT(ISNULL(SkillGroupSkillTargetID,0)) is counting it the right way for some reason.
WHERE SkillTargetID IN (:AgentSkillTargetID)
and SkillGroupSkillTargetID IN (:SkillGroup)
and DateTime >= :startDate
and DateTime <= :endDate
GROUP BY DateTime, SkillTargetID
(This is a part of a large and complex query, this is why I´m using Anonymous Block instead of DB Query)