Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
pranali_gawde
Partner - Contributor III
Partner - Contributor III

Percentage split in pivot

Hi sir,

I am trying to calculate percentage in pivot but after adding month as column that percentage divide into two months.if i selected only one month then it is cming correct.can u plz help me to resolve this issue.

Below is the snapshot and expression for the same.

This is one month:

one month.png

Two Month

two month.png

Expression:

Sum(Aggr(sum(DISTINCT{<Flag={'SJ'},fMonth=,[SEGMENT_CODE]={'1','6'}>}TEU),ECARRIER_NAME,Fcldata))

/Sum(total Aggr(sum(DISTINCT  {<Flag={'SJ'},fMonth=,[SEGMENT_CODE]={'1','6'},ECARRIER_NAME={'*'}>}  TEU), Fcldata))

2 Replies
rubenmarin

Hi Pranali, TOTAL is used to ignore dimensions (month dimension is also ignored), if you want to keep some dimensions you can add the fields between <>:

Sum(Aggr(sum(DISTINCT{<Flag={'SJ'},fMonth=,[SEGMENT_CODE]={'1','6'}>}TEU),ECARRIER_NAME,Fcldata))

/Sum(total <Month> Aggr(sum(DISTINCT  {<Flag={'SJ'},fMonth=,[SEGMENT_CODE]={'1','6'},ECARRIER_NAME={'*'}>}  TEU), Fcldata))

pranali_gawde
Partner - Contributor III
Partner - Contributor III
Author

Grate,It's working fine.

Thank you so much sir.