Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
djnqlear
Partner - Contributor III
Partner - Contributor III

Aggregate Employee in Org Chart Qlik Sense

djnqlear_0-1615582719414.png

How can i aggregate employees in org  chart, the employee is located at child node.

ParentChildStringPosCount(Employee)
011J001EJ002011J001EJ003011J00003003.011J000DP001.011J000DP002.011J001EJ002.011J001EJ0034
Labels (1)
12 Replies
altunel0777
Contributor
Contributor

++up 

IuliaM
Contributor III
Contributor III

Hello Everyone,

has someone found a solution for this request, I am trying to do the same thing.

thanks!

Iulia

jackm75
Creator
Creator

I was looking for the same answer when I came across this post. It's old, but thought I would share my solution using the HierarchyBelongsTo function.

I created an Org Chart in Qlik Cloud and wanted to show on the card the number of Total Reports under each person. In the load script, I have my employees table which includes the EmployeeID and ManagerID. 

I then used that resident table to create a table that provides the TotalReports value:

OrgData:
HierarchyBelongsTo(EmployeeID ,ManagerID,[Full Name],MgrID,MgrName,Depth)
LOAD EmployeeID ,ManagerID, [Full Name]
Resident AllEmployeesData
WHERE Status='Active';

OrgCount:
LOAD MgrID as EmployeeID
,Count(EmployeeID )-1 as TotalReports
Resident OrgData
Group By MgrID;

Drop Table OrgData;

Then in the Org Chart Measures value, I simply used TotalReports.

 

Hope this helps!