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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
zagzebski
Creator
Creator

Function to get all of 1 dimension

I need to be able to create an expression that would give revenue by area for group 1 divided by the revenue of by area for ALL groups. I have tried different ways (using TOTAL) but can't get it to do what I am looking for...

GroupAreaRevenue
1North$
  1,000.00
1South$
  2,000.00
1East$
  3,000.00
1West$
  4,000.00

Note: I need to be able to filter on Group 1 in this example.

Thanks in advance...

1 Solution

Accepted Solutions
MarcoWedel

Hi,

one example:

QlikCommunity_Thread_137643_Pic1.JPG.jpg

QlikCommunity_Thread_137643_Pic2.JPG.jpg

QlikCommunity_Thread_137643_Pic3.JPG.jpg

QlikCommunity_Thread_137643_Pic4.JPG.jpg

QlikCommunity_Thread_137643_Pic5.JPG.jpg

QlikCommunity_Thread_137643_Pic6.JPG.jpg

//creation of sample data

tabRevenue:

LOAD Ceil(RecNo()/4) as Group,

    Pick(Mod(RecNo()-1,4)+1,'North','South','East','West') as Area,

    Money(Round(Rand()*4000,0.01)) as Revenue

AutoGenerate 16;

hope this helps also

regards

Marco

View solution in original post

4 Replies
Anonymous
Not applicable

Hi!

Take a look on the attached file. Is that what you're looking for?

I did a sum(TOTAL <Group> Revenue). This make a group by in your sum by "Group".

Regards,

Gabriel

maxgro
MVP
MVP

sum(Revenue) / sum(total <Group> Revenue)

or   sum(Revenue) / sum(total <Area> Revenue)

MarcoWedel

Hi,

one example:

QlikCommunity_Thread_137643_Pic1.JPG.jpg

QlikCommunity_Thread_137643_Pic2.JPG.jpg

QlikCommunity_Thread_137643_Pic3.JPG.jpg

QlikCommunity_Thread_137643_Pic4.JPG.jpg

QlikCommunity_Thread_137643_Pic5.JPG.jpg

QlikCommunity_Thread_137643_Pic6.JPG.jpg

//creation of sample data

tabRevenue:

LOAD Ceil(RecNo()/4) as Group,

    Pick(Mod(RecNo()-1,4)+1,'North','South','East','West') as Area,

    Money(Round(Rand()*4000,0.01)) as Revenue

AutoGenerate 16;

hope this helps also

regards

Marco

ashwanin
Specialist
Specialist

Hi,

Please go through the below qvw. It will provide you the result,which you required.