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

Problem with full set {1}

Helo,

In attached qv doc, in Table2 straighttable, I am trying to show Parts, corresponding weight and no of suppliers. If I make a selection in Vehicle, Part or Supplier fields I want Table2 to show rows related to the selection however the no of suppliers should be unaffected.

for this i put "count({1} distinct Supplier)" as "no of suppliers" expression. with this the supplier count is unaffected but extra rows show up when i do filtering.

For example if I select Part = P1, I should only get P1 record in Table2 but I get P1 and P3.

Can someone pls tell me why this behavior?

Thanks,

VJ

7 Replies
Not applicable
Author

Hi,

try to use following expression

count({<Supplier =>} distinct Supplier)

it will ignore your selection in Supplier but will react on selection in Part.

If you need to ignore also vehicle please do count({<Supplier =, Vehicle=>} distinct Supplier)

Anonymous
Not applicable
Author

That works. Thank you.

If there is a scenario where I want to ignore all filters and if there are too many of them, what would be the best way to do this?

sunny_talwar

For ignoring all filters you would use {1}, for more specific requirements you can look at the following attached document (page 18)

Copying a small extract from the document:

If I want everything (All values) except for 2 dimensions: PRODUCT and MONTH, I would write:

=sum({$<[$(=Concat({1<$Field-={'PRODUCT','MONTH'}>}distinct $Field,']=,[' )&']=')>} VALUE)

HTH

Best,

S

Anonymous
Not applicable
Author

count({<Supplier=>} distinct Supplier) worked partially. The count is correct now but I still see extra unrelated rows when I select Supplier filter.


For ex, if I select Supplier S1, I should see only Part P1 but I see Part P3 also with corresponding values shown as null.


Does anyone know why this happens?

Not applicable
Author

Hi,

you will put in expression   $ instead of 1. like this.

         =count({$} distinct Supplier)

PrashantSangle

Hi,

did you try with TOTAL keyword...

Regards

Great dreamer's dreams never fulfilled, they are always transcended.
Please appreciate our Qlik community members by giving Kudos for sharing their time for your query. If your query is answered, please mark the topic as resolved 🙂
Anonymous
Not applicable
Author

Total doesnt help because I still want to use the groupby of the table.

count({$} distinct Supplier) gives me 1 if I select a supplier but I want the total suppliers of the part irrespective of the selection.


It almost looks impossible to have a field to filter the rows and still have count unaffected by the filter.