
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Null and Not equal to in the QV10 Set analysis
Hi Guys,
Can anyone please let me know how to use Isnull in the QV-10 Set Analysis ?
also I would like to know what is operator we can use in the set analysis for not equal to.I am trying to achieve
Count(distinct{$ <Type <> {'CAL','MEM'} >} Nbr)
For not equal to ,i tried with <> and -= It seems these are not the right operator for QV10 setanalysis.
In the same way if would like to count the NBR where type=NULL,how to do it the set analysis?
Count(distinct{$ <Type = {NULL} >} Nbr)--This is not working.
Thanks...
Accepted Solutions

.png)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I agree with his take on how you read set analysis and I think many developers misinterpret the = in set analysis. I had never thought of excluding NULL in that way so I did some tests in the QV attached. The set analysis {"<>43"} and -{43} appears to give a different result because using a >,< or = in a search string automatically filters out strings and empty stringsfrom the list of values since they can not be evaluated in that way.
Karl

.png)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
The correct syntax for not equal is -= even though the syntax checker says it is incorrect. In theory, to filter the nulls the set analysis should be Type = {}, but this doesn't always work. Please confirm in your app.
Karl

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hey,
About the not equal to, i made a different example.

.png)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Here's the example with other expressions. Are you looking for null or ''?

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I just compared these three expressions myself, i initially thought {"<>43"} would give the same as -={43}, do you have an explanation why they differ?

.png)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
On the first problem, there is no "not equal". These are sets and you need to define the values that Type should have. I suspect you want the complement values to the two values 'CAL' and 'MEM', i.e. <Type= -{'CAL','MEM'}>. With a minus sign. I haven't tried this myself, but I think it should work.
Secondly, again this is set analysis: you need to define the values that Type should have. If you want he records where Type is NULL, then you also need to define in which field you should make the selection - where you should pick out the values. For example, if you want to select the orders where Type is NULL, then you should use {$<OrderID= E(-{1<Type={'*'}>})>}. This will select all values in Type and then see which OrderIDs that are excluded.

.png)
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I agree with his take on how you read set analysis and I think many developers misinterpret the = in set analysis. I had never thought of excluding NULL in that way so I did some tests in the QV attached. The set analysis {"<>43"} and -{43} appears to give a different result because using a >,< or = in a search string automatically filters out strings and empty stringsfrom the list of values since they can not be evaluated in that way.
Karl

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Thank you so much for the explainations and the sample.
