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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Help to aggr a result

Hi guys,

I'm in trouble with an aggregation.

I have a straight table with two dimension and one expression:

nominativoDnominativoRGAP -1
Berti ValterAvondoglio Marco1
Berti ValterBeldi' Paola0
Berti ValterCotto Giovanni0
Berti ValterDiretti Berti Valter0
Berti ValterMorera Maurizio2
Berti ValterValperga Giovanni0

the expression for GAP-1 is:

if(

    sum(

        if(annomese_MNG=$(vTrimAct_MNG), left(ConsAvanzata,1))

        )

    -

    sum(

        if(annomese_MNG=$(vTrimPrec_MNG), left(ConsAvanzata,1))

        )

    =-1

,

    1

,

    0

)

I'd like to have a table with only one dimension "nominativoD" and aggr the result of GAP-1.

In poor words I'd like to have a table like this:

nominativoDGAP -1
Berti Valter3

How can I change my expression to reach my goal ??

Thank you so much in advance

Giampiero

My question is in the attached image.

1 Solution

Accepted Solutions
Not applicable
Author

Hi,

See this Attched File...........hope your needful has been done.

Regards,

Nirmal Raj.

View solution in original post

10 Replies
Anonymous
Not applicable
Author

   use this expression in chart

aggr(if(sum(if(annomese_MNG=$(vTrimAct_MNG), left(ConsAvanzata,1))  - sum(if(annomese_MNG=$(vTrimPrec_MNG), left(ConsAvanzata,1)))=-1,1,0)  ,  nominativoD )

add only single dimension nominativoD

Regards,

anant

Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Try

sum(aggr(

  if( sum(if(annomese_MNG=$(vTrimAct_MNG), left(ConsAvanzata,1))) -

      sum(if(annomese_MNG=$(vTrimPrec_MNG), left(ConsAvanzata,1))) =-1,

    1,

    0),nominativoRM))


talk is cheap, supply exceeds demand
Not applicable
Author

Hi,

Can you please Upload your Application. I will try to solve.

Regards,

Nirmal Raj.

Not applicable
Author

Hi guys,

first of all THANKS to reply.

@ Anant  and Gysbert: Unfortunately it doesn't work. The result is 1 and not 3

@ Nirmal Raj: Unfortunately My Qvw is to big and I can't put it on internet. I'll try to create a Qvw similar.

Any other idea ??

I'm really in trouble. I have to show the result today and I don't know how to solve this problem.

THANK YOU SO MUCH

Giampiero

Not applicable
Author

Atleast upload simple sample application.

Not applicable
Author

Hi,

I attach a simple application.

Hope it helps.

Thanks all.

Giampiero

Not applicable
Author

Hi,

Please Find The Attachment hope problem is solved.

Regards,

Nirmal Raj.

Not applicable
Author

Hi,

I Hope This is Exact Output you need.

Regards,

K.J.Nirmal Raj.

Not applicable
Author

Hi,

See this Attched File...........hope your needful has been done.

Regards,

Nirmal Raj.