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: 
Not applicable

Total count on key field doesn't display any result

Hello,

Why a total count can't be applied to a key field ? The result is always N/A.

I have this issue in a statistics box. But it seems to be the case on graphics too.

Thanks for your help.

Gilles

4 Replies
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Counts on key fields are problematic because the field exists in at least two tables. So which count should be returned? That can't be determined. And that's also why you should use non-key fields for counts. Btw, you'll see the same thing for sum and average for a key field in the statistics box.


talk is cheap, supply exceeds demand
Not applicable
Author

Thanks for this answer Gysbert. I though qv would be able to work on agregate set of data.

Expression configuration in selection list accept the "distinct" but that doesn't help on working on key fields.

So, what could be the workaround ? How can I display the total count of a selection list regarding selection ?

Regards

Gilles

Anonymous
Not applicable
Author

Gilles,

The workaround is to create a copy of the key field, and use it in expressions.

Regards,

Michael

Not applicable
Author

Thanks for all.

Gilles