Skip to main content
Announcements
See what Drew Clarke has to say about the Qlik Talend Cloud launch! READ THE BLOG
cancel
Showing results for 
Search instead for 
Did you mean: 
passionate
Specialist
Specialist

Set Analysis for Modifiers not present

Hi Geeks,

I am using Set analysis to show Product wise sales for every ID.

Eg:- Sum({<Product={'A'}>}Sales)

Please find attached QVW and data file.

Question:

I want to display Sum as Null if no Products are available for a particular id like in below example:

For ID 1 products available are A and B so I don't Want to Show "0" but Null().

Sum(Sales) for a particular product can be Zero or Null()

Set Analysis.PNG

Appreciate your help.

Thanks and Regards,

Pankaj

1 Solution

Accepted Solutions
antoniotiman
Master III
Master III

You wrote

Sum(Sales) for a particular product can be Zero or Null()

May be this

If(Count({<Product={'A'}>} Product)> 0,Sum({<Product={'A'}>} Sales))

View solution in original post

5 Replies
sunny_talwar

May be use a pivot table or use an expression like this

If(Sum({<Product={'A'}>}Sales), Sum({<Product={'A'}>}Sales))


Capture.PNG

passionate
Specialist
Specialist
Author

Thanks Sunny.

What if i also want to show Sum(Sales) as Zero as Well?

antoniotiman
Master III
Master III

You wrote

Sum(Sales) for a particular product can be Zero or Null()

May be this

If(Count({<Product={'A'}>} Product)> 0,Sum({<Product={'A'}>} Sales))

sunny_talwar

What do you mean that you want to show it as 0 and null both at the same time?

passionate
Specialist
Specialist
Author

Thanks, You both are Gem

Cheers!!!!