Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Not applicable

Expression with Alternate State not working

Hi,

In my Straight table chart I am using the following formula in the expression:

num(sum({$<Customer = p({[AltState1]}Customer)- p({[AltState2]} Customer)>}Sales),'$#,##0')

where I am trying to find out list of Customers slected in Alternate State AltState1 and not there in alternate state 2 AltState2.

and the Straight Table is in AltState1.

Whenever selection is made in AltState2 the values are not reflected.

Dimension used is: Customer

Thanks in advance!!

Regards,

Pooja

7 Replies
MVP
MVP

Re: Expression with Alternate State not working

Try this:

num(sum({<Customer = [AltState1]::Customer>- <Customer=[AltState2]::Customer>}Sales),'$#,##0')

Not applicable

Re: Expression with Alternate State not working


Thank you for your suggestion..

But this expression doesn't seem to work for me..

MVP
MVP

Re: Expression with Alternate State not working

It's working with me. Could you please share your sample app?

MVP
MVP

Re: Expression with Alternate State not working

Hi,


Try like this


=num(sum({[AltState1]<Customer -= P({<Customer=[AltState2]::Customer>})>} Sales),'$#,##0')


Regards,

Jagan.


Not applicable

Re: Expression with Alternate State not working

Hi Jagan,

Thank You for your suggestion.

The problem I faced while using your expression was it gave an error at the p().

Regards,

Pooja

MVP
MVP

Re: Expression with Alternate State not working

Hi,

I will show error but it works.  It is showing because -=.

Regards,

Jagan.

Not applicable

Re: Re: Expression with Alternate State not working

Hi

PFA, Sample app.

Regards,

Pooja

Community Browser