Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Highlighted

count using set analysis based on selection

Hi Team,

i have the listbox for "Status". that contain "i1","i2","i3", like that.

i need count for if the type is "finished" or "Pending". But the status should be i1,i2, i3 and i4.

=Count(distinct

{

<

  type={'finished'},

  Status={'i1','i2','i3','i4',' '}

>

+

<

  type={'Pending'},

  Status={'i1','i2','i3','i4',' '}

>

}  Product)

Now, i need the count based on the Status. If i select "i1",  I need the count for Status "i1".

could you please give me the expression.

Thanks & regards,

Sethu

6 Replies
Not applicable

Re: count using set analysis based on selection

Hi,

Count(distinct{< type={'finished','Pending'}>} Product)

Regards,

Joshmi

Re: count using set analysis based on selection

Hi Joshmi,

i need to consider the status also.

when i select the status, that should only show.

regards,

sethu

ychaitanya
Contributor III

Re: count using set analysis based on selection

i hope you can use combination of GetFieldSelections() to identify the slected value

if(GetFieldSeclections(type='Pending'),sum({<Status={'i1','i2','i3','i4',' '}> Sales)

,sum({<status={'i1','i2','i3','i4'}>Sales)

Regards

Chaitanya Y

Not applicable

Re: count using set analysis based on selection

Hi,

Please try this,

Count(distinct{< type={'finished','Pending'}>} if(Match(Status,'i1','i2','i3','i4'), Product))

Regards,

Joshmi

Re: count using set analysis based on selection

will check

ychaitanya
Contributor III

Re: count using set analysis based on selection

Hi

Have you used my recommendation.

Thanks

Chaitanya