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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Expression with WHERE clause

I am trying to create a chart with an expression where it retrieve results WHERE status is 'New' and 'Resolved'

..and other expression WHERE status is 'Closed'

I tried the following line of expression, but it shows other status.

=if([Status Description] = 'Closed',[Status Description])

Please assist

7 Replies
Anonymous
Not applicable
Author

Try like this:

= Count( if(StatusDescription='New',StatusDescription))

=Count( if(StatusDescription='Resolved',StatusDescription))

its_anandrjs
Champion III
Champion III

You can try with

If(Match([Status Description],'Closed'),[Status Description])


or check the supress when value null

its_anandrjs
Champion III
Champion III

You can also try with if i am understand your dimension.

If(Match([Status Description],'Closed') And Match(status,'New','Resolved') ,[Status Description])

simondachstr
Specialist III
Specialist III

Use Set-Analysis on the Expression (not Dimension) {<[StatusDescription]={'New',Resolved'}>}

Not applicable
Author

Hi

This would be used as a calculated dimension

=if([Status Description] = 'Closed',[Status Description])

else for an expression use=if(only([Status Description]) = 'Closed', only([Status Description]))

anyway if you want to make some count or sum on this status use the set analysis expression like

=sum({<[Status Description] = {'Closed'}>}  YourField)

best regards

Chris

Not applicable
Author

I am trying to group and Sum the results for two status and give them a new Status Name

New = 20

Resolved = 10

Closed = 5

This is what I am trying to achieve:

Closed = 5

Open = 30

Not applicable
Author

am trying to group and Sum the results for two status and give them a new Status Name

New = 20

Resolved = 10

Closed = 5

This is what I am trying to achieve:

Closed = 5

Open = 30