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: 
RheaQv12
Creator
Creator

include all and at the same time include null values also.. Count({<SalesMan={"*"}>} Distinct PNam )

Hi there,

I have a scenario where there are nulls as part of join in the data model so i am not able to replace the nulls at the load script level... I have this scenario where the user will select the SalesMan listbox and this selection should not be applied to one of the straight table so SalesMan={*} and counting the ProductName values... * is excluding the NULL values

but there are certain ProductNames which do not have a SalesMan...so how do i get both i.e SalesMan={"*"} - this is required because i do not want to SalesMan dimension to change when the user selects the SalesMan in the listbox (the stragiht table should not change) ---not sure how to put this...

Count({<SalesMan]={null}  and     SalesMan]={"*"}>} Distinct PName)  - something like this

thanks a lot

 

1 Solution

Accepted Solutions
Arthur_Fong
Partner - Specialist III
Partner - Specialist III

Try: 

Count({<SalesMan=>} Distinct PName)

View solution in original post

4 Replies
Arthur_Fong
Partner - Specialist III
Partner - Specialist III

Try: 

Count({<SalesMan=>} Distinct PName)

RheaQv12
Creator
Creator
Author

Hi

thanks but this will change the data in the straight table when i select the SalesMan value in a listbox - i do not want the st table to change when a value is selected in salesman listbox

the st table with salesman as dim should not chabge thats why i was using *

 

 

sunny_talwar

This expression by @Arthur_Fong is doing exactly that... ignoring selection in SalesMan field while allowing you to see nulls

Count({<SalesMan=>} DISTINCT PName)

You can also write this without the = sign 

Count({<SalesMan>} DISTINCT PName)

 

RheaQv12
Creator
Creator
Author

Thank you @Arthur_Fong and Sunny_Talwar