Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Different results in set analysis

I am using a set analysis statement like the following in a QlikView document.

I am finding that if there are NO records where [Scope State] has a non-null value, then I get the entire list of records, where I would expect NO records returned.

However, if I have at least 1 record where [Scope State] has a non-null value, then I get just the records I would expect, records where [Scope State] is set to a non-null value.

Any ideas on this?

 

=Concat({<[Scope State] = {"*"} >}[Scope Name], '    ')

1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

Hey Fred,

You may want to filter out null values in your load script, or at least flag them like this:

if(isnull([Scope State]),0,[Scope State]) as [Scope State]

Then in your set analysis use

=Concat({<[Scope State] -= {0} >}[Scope Name], '    ')

Your statement is showing different results because when there are no values in Scope State, Qlikview doesn't have anything to select in your set analysis so it doesn't filter on anything.

Does this help you?

View solution in original post

2 Replies
Anonymous
Not applicable
Author

Hey Fred,

You may want to filter out null values in your load script, or at least flag them like this:

if(isnull([Scope State]),0,[Scope State]) as [Scope State]

Then in your set analysis use

=Concat({<[Scope State] -= {0} >}[Scope Name], '    ')

Your statement is showing different results because when there are no values in Scope State, Qlikview doesn't have anything to select in your set analysis so it doesn't filter on anything.

Does this help you?

Not applicable
Author

Thanks Napac1458,

Your answer clarifies why I was getting the strange results.  And I was able to implement a solution based on your code sample.  So thank you very much.

Fred