Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am calculating a measure in the Pivot table, but the value in the total and sub total is not summing the corresponding value of the cells. The measure i am using is
Employee Contribution - COUNT(distinct Emp)/COUNT(TOTAL <Emp> distinct Project )
I want subtotal for Project and total for Domain should add the employee contribution e.g. for Project A subtotal should be 1.25 (0.25+1.00) instead of 0.50 , total for Domain D1 should be 1.50(0.25+1.00+0.25) instead 0.75, similarly for Domain B. Below is the sample data.
Thank you for your help.
Sample data:
Load * Inline [
Domain,Project,Employee
D1,A,Emp1
D1,A,Emp2
D1,B,Emp1
D2,C,Emp1
D2,D,Emp3
D2,D,Emp1
];
Hi,
You may try below expression.. Hope you get expeted result
sum(
Aggr(
Count(Distinct Employee) / Count(Total <Employee> Distinct Project),
Project,Employee,Domain
)
)
Regards,
Arunesh Kumar
Hi,
You may try below expression.. Hope you get expeted result
sum(
Aggr(
Count(Distinct Employee) / Count(Total <Employee> Distinct Project),
Project,Employee,Domain
)
)
Regards,
Arunesh Kumar
Thanks Arunesh, your solution worked perfectly fine.