Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
cancel
Showing results for 
Search instead for 
Did you mean: 
Winstodge
Contributor II
Contributor II

How to add a criteria to an expression

Hi All,

Just started using Qlik Sense

am trying to edit a sheet and to show a filtered value

The below is currently what is there

$(vDeliveryCount)

but I want to add a field so that it counts only certain criteria ie a MRPController

$({<MRP_CONTROLLER={'Z01'}>$(vDeliveryCount)

In some cases I will need to add more that 1 MRP Controller and the result should count all instances.

Can you please help me to get the correct expression

Apologies if i have not given enough detail

Thank you, Winstodge

1 Solution

Accepted Solutions
JordyWegman
Partner - Master
Partner - Master

Hi Winstodge,

You have created a variable $(xx). What is inside this variable?

Here is an example:

let vDeliveryCount = Count(Delivery);

Then you want the set analysis in your formula:

let vDeliveryCount = Count( {$< MRP_CONTROLLER = {'Z01'} >} Delivery);

Jordy

Climber

Work smarter, not harder

View solution in original post

3 Replies
JordyWegman
Partner - Master
Partner - Master

Hi Winstodge,

You have created a variable $(xx). What is inside this variable?

Here is an example:

let vDeliveryCount = Count(Delivery);

Then you want the set analysis in your formula:

let vDeliveryCount = Count( {$< MRP_CONTROLLER = {'Z01'} >} Delivery);

Jordy

Climber

Work smarter, not harder
Winstodge
Contributor II
Contributor II
Author

Thanks Jordy for you reply.

 

Unfortunately I am new to Qlik and I have copied the main sheet to create my own, so I do not know what is inside the variable vDeliverycount. Is there a way to check?

Thanks

Winstodge

Winstodge
Contributor II
Contributor II
Author

Hi Jordy

 

I have managed to get what I needed.

I took out the $ sign in from $(vDeliveryCount) variable and it gave me Count(distinct Key)

then I used 

Count( {$< MRP_CONTROLLER = {'Z01'} >} distinct Key)

Thank you for your help