Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
pirotfab
Creator
Creator

percentage in the total row of a TCD

Hello,

Do you know a formul to get the 1.8% in red?

This formul, in the column "tx E", calculate as : CR / CP

However, it does not work in the Total line..

For information, the fields CR and CP calculate expressions. Not a sum of a single field..

CP = sum(M+CMO+CN)

CR = R * CP / TOT

thanks

Fabien

1 Solution

Accepted Solutions
Anil_Babu_Samineni

May be this?

Sum(Aggr(((R*CP)/TOT) / Sum(M+CMO+CN), POSTE, ARTICLE))

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful

View solution in original post

6 Replies
Anil_Babu_Samineni

May be this?

Sum(Aggr(((R*CP)/TOT) / Sum(M+CMO+CN), POSTE, ARTICLE))

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
pirotfab
Creator
Creator
Author

With this expression, the result is 11% (10%+1%)

Anil_Babu_Samineni

Will you able to provide work file. Can you try this?

Avg(Aggr(((R*CP)/TOT) / Sum(M+CMO+CN), POSTE, ARTICLE))

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
pirotfab
Creator
Creator
Author

By exercising excel at Qlikview I think there is also an error on the CR column

Thanks

Anil_Babu_Samineni

Now, i understand - Can you tell us logic behind?

Best Anil, When applicable please mark the correct/appropriate replies as "solution" (you can mark up to 3 "solutions". Please LIKE threads if the provided solution is helpful
pirotfab
Creator
Creator
Author

by adding your expression

Sum(Aggr(((R*CP)/TOT) / Sum(M+CMO+CN), POSTE, ARTICLE))  in the CR column,

it's ok

thanks for your help