4 Replies Latest reply: Jul 6, 2018 3:55 AM by Olivier GAUTIER

# Compare Own Company Sales with Other Company

Hi all,

I have following data set like  Company , Product , Customer and his area  , my requirement is when user will see 2 charts

own company sale vs Other Company Sale with Area will be common between this 2 charts

 Company Product Sales MonthYear Customer Area A MS 25000 201804 C1 Mumbai A HS 35000 201804 C1 Mumbai B MS 55000 201804 C2 Thane B HS 65000 201804 C2 Thane C MS 24000 201804 C3 Raigad C HS 35000 201804 C3 Raigad A MS 24800 201805 C1 Mumbai A HS 34800 201805 C1 Mumbai B MS 54800 201805 C2 Thane B HS 64800 201805 C2 Thane C MS 23800 201805 C3 Raigad C HS 34800 201805 C3 Raigad

Requirement is like this :

 Period  : 201804 Own Company Sales Analysis Company Product Area Sale A MS Mumbai 25000 A HS Thane 35000 Other Company Sales Analysis Company Product Area Sale B MS Mumbai 55000 B HS Thane 65000 C MS Mumbai 24000 C HS Thane 35000

How to achieve the same in Qlik sense ?

Regards

Vikas

• ###### Re: Compare Own Company Sales with Other Company

Hi,

use as first dimension :

if(Company = 'A','Own','Others')

then Company, Product, Area

in expression :

sum({< Area = P({<Company = {'A'} >}) >} sales)

regards

• ###### Re: Compare Own Company Sales with Other Company

Hi

Create 2 Tables

1er table:

Dimension

company

product

area

Mesure : Sum(Sales)

and 2nd table:

Dimension

company

product

area

MEsure :

Sum({1-\$}Sales)

ex :

• ###### Re: Compare Own Company Sales with Other Company

Thanks all for your answers But i have ended with following expression.

Count({< Company=E({<Company={'A'}>}) ,Area = p(Area)  ,Customer=>} Company)

Vikas

• ###### Re: Compare Own Company Sales with Other Company

hi,

are you sure you'll have common area with area= p (area) ?