cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
935
Views
0
Helpful
2
Replies

In need of a UCCE 7.5 SQL Query

Mr_toad1_2
Level 1
Level 1

Would anyone happen to know of a SQL query that that can be run on the HDS what would give the avarage skillgroups assigned to an agent.  Also, another one that would give average number of agents to a supervisor? 

1 Accepted Solution

Accepted Solutions

Gergely Szabo
VIP Alumni
VIP Alumni

Hi,

try

SELECT COUNT(*)/CAST(COUNT(DISTINCT sgm.AgentSkillTargetID) AS FLOAT) FROM Skill_Group_Member sgm

and

SELECT COUNT(*)/CAST((SELECT COUNT(DISTINCT SupervisorSkillTargetID) FROM Agent_Team_Supervisor) AS FLOAT) FROM Agent_Team_Member

But please remember agents don't have to be in teams, so the above query does not count with agents who aren't assigned to a team.

G.

View solution in original post

2 Replies 2

Gergely Szabo
VIP Alumni
VIP Alumni

Hi,

try

SELECT COUNT(*)/CAST(COUNT(DISTINCT sgm.AgentSkillTargetID) AS FLOAT) FROM Skill_Group_Member sgm

and

SELECT COUNT(*)/CAST((SELECT COUNT(DISTINCT SupervisorSkillTargetID) FROM Agent_Team_Supervisor) AS FLOAT) FROM Agent_Team_Member

But please remember agents don't have to be in teams, so the above query does not count with agents who aren't assigned to a team.

G.

Thanks Gergely!

Getting Started

Find answers to your questions by entering keywords or phrases in the Search bar above. New here? Use these resources to familiarize yourself with the community: