Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

sculptorlv
Contributor II

Not showing values on expression results

Hello.

I have strait table:

1.jpg

In this table Columns Dates.. and Status are evaluated values based on dimensions.

Can I somehow NOT TO SHOW rows based on evaluated expressions? For example, where Status is OK.

Thank you for help in advance.

Tags (1)
1 Solution

Accepted Solutions
MVP
MVP

Re: Not showing values on expression results

Simply leave the else part blank like with inverse comparison (not equal) :


=IF(Customer_Number <> '40003100906', 'show data')

Or,

=IF(Customer_Number = '40003100906', null() ,'show data')

13 Replies
MVP
MVP

Re: Not showing values on expression results

Try using calculated dimension, like:

          if( Status<>'OK', Title) ; check 'Supress when value is null' in the dimension tab.

If you get 'OK' as a result of expression, you might have to use a bit more complex expression for calculated dimension. Like: =Aggr( if(<expression>='OK', Title), Title)

Assuming Title is your single dimension.

balrajahlawat
Esteemed Contributor

Re: Not showing values on expression results

Why not, If I am not wrong.

Use Calculated dimension for you DateField like:

=IF(Status<>'Ok', DateField)

and use Suppress Null option to be ticked

sculptorlv
Contributor II

Re: Not showing values on expression results

Can you help me with syntax please?

So I have working calculated dimension:

=IF(Customer_Number = '40003100906', 'not to show','show data')

How can I put NULL instead of 'not to show' ??

I don't get the idea of 'Title'.

MVP
MVP

Re: Not showing values on expression results

Simply leave the else part blank like with inverse comparison (not equal) :


=IF(Customer_Number <> '40003100906', 'show data')

Or,

=IF(Customer_Number = '40003100906', null() ,'show data')

sculptorlv
Contributor II

Re: Not showing values on expression results

Thank you.

I got +1 to my qlikview skills

sculptorlv
Contributor II

Re: Not showing values on expression results

Did more complex dimension:

=

IF (SUM(IF(InMonth(Bouth__PostingDate,Today(),0),Bouth_Cofee_Item_Money,0))=0, 'In progress')

And got mistake:

Error in calculated dimension.

MVP
MVP

Re: Not showing values on expression results

In calculated dimension, if you need to use an aggregate function, it has to be used along with Aggr() or Total. Yours suits aggr(). Try like:

Aggr(

          IF (SUM(IF(InMonth(Bouth__PostingDate,Today(),0),Bouth_Cofee_Item_Money,0))=0, 'In progress')

, Bouth__PostingDate)

sculptorlv
Contributor II

Re: Not showing values on expression results

Yes this works. But I still can't understand the idea of Aggr(). Please help! Tried to read manual, not very much info.

I hope, you can spent some more time for additional help

Actually I have much more complicated expression, thus I need to get idea, how to use aggr()

My total expression is:

IF

(SUM(DocumentRows__Quantity) = 0

AND

SUM(IF(InMonth(Bouth__PostingDate,Today(),0),Bouth_Cofee_Item_Money,0))=0

AND

(sum(IF(InMonth(Bouth__PostingDate,Today(),-1),Bouth_Cofee_Item_Money,0)) + sum(IF(InMonth(Bouth__PostingDate,Today(),-2),Bouth_Cofee_Item_Money,0)) + sum(IF(InMonth(Bouth__PostingDate,Today(),-3),Bouth_Cofee_Item_Money,0)))>0,

//Then

'In progress',

//Else

IF

(SUM(DocumentRows__Quantity) > 0

AND

SUM(IF(InMonth(Bouth__PostingDate,Today(),0),Bouth_Cofee_Item_Money,0))=0,

//Then2

'In progress',

//Else2

'OK'))

And I need null() instead of 'OK'

MVP
MVP

Re: Not showing values on expression results

Check if this helps: AGGR...

Community Browser