Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

%Mix

Hello, i have a pivot table where i need to present %mix, but i have a dimensión Region , some like this, my problem is when i use the expression Sum(TOTAL Aggr(sum({<$(vSetYearAct),$(TipRegion)>}#Sales),CanalName)) for get sum of sales for region show sales for noth and south, not separate

 

RegionNortSouth
Canal NameSales%MixSales%Mix
Canal 1547233%871252%
Canal 2876952%647839%
Canal 3254715%214513%
Total16788100%17335103%
1 Solution

Accepted Solutions
Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

!

Hi Elina,

you simply had an extra bracket } after the TOTAL qualifier. Attached is the corrected formula.

cheers,

Oleg Troyansky

Learn advanced QlikView and Qlik Sense techniques in my book QlikView Your Business

View solution in original post

8 Replies
Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi Elina,

I don't think you really need the AGGR function for this calculation. I'd use the following:

SUM({<condition>} Sales)/sum({<condition>} Total Sales)

cheers,

Oleg Troyansky

Learn AGGR, Set Analysis, and many other advanced techniques from my book QlikView Your Business.

Not applicable
Author

I've already tried that option, but I don't have result. It could be because I have canal and region as dimension??

johnw
Champion III
Champion III

It looks like you want the %Mix within the Region? Just need to add <Region> after the total in Oleg's expression, I think.

sum({<$(vSetYearAct),$(TipRegion)>} #Sales)
/sum({<$(vSetYearAct),$(TipRegion)>} total <Region> #Sales)

Not applicable
Author

sorry, i don´t explain correctly, i have two dimensions. canal and regional, and i have two variables vSetYearAct and TipRegion, the last save if region is north or south, i tried your expression, but do not work.


(sum({<$(vSetYearAct),$(TipRegion)>}TOTAL <Regional>} #Sales)

Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi Elina,

it would be a lot easier if you could create a small example and share it. We could then review it and help you find the solution.

cheers,

Oleg Troyansky

Not applicable
Author

thannks Oleg, attach file with examples, thanks for your help

Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

!

Hi Elina,

you simply had an extra bracket } after the TOTAL qualifier. Attached is the corrected formula.

cheers,

Oleg Troyansky

Learn advanced QlikView and Qlik Sense techniques in my book QlikView Your Business

Not applicable
Author

Thanks, for your time