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

Excluding dimension values from total row in pivot table

Hi,

I would like to exclude from the total row in a pivot table, values of  a certain dimension (family code).

The dimension is flagged in the database for that. Another words, there is a boolean field which indicates whether to include it in the total or not.

But just to check it, I used a specific value (1001).

I wrote the following expression:

=if(RowNo() = 0 or IsNull(RowNo()), Sum({$<[Family Code] ={'<>1001'}>} [Total Available Balance]), sum([Total Available Balance]))

It works fine when there is no selection. The problem is that when a certain family code is selected, the total still shows all values.

Any idea how to resolve it?

Thanks!

1 Solution

Accepted Solutions
swuehl
MVP
MVP

It might be better if you could upload a small sample application, because without knowing your data model etc., it's not easy to give a correct answer.

Instead of checking for rowno()=0, you could also look into dimensionality() function, but that's probably not causing the issue.

Have you tried excluding the records with the flag like

=if(RowNo() = 0 or IsNull(RowNo()), Sum({$<[Family Code] -= {1001}>} [Total Available Balance]), sum([Total Available Balance]))

View solution in original post

2 Replies
swuehl
MVP
MVP

It might be better if you could upload a small sample application, because without knowing your data model etc., it's not easy to give a correct answer.

Instead of checking for rowno()=0, you could also look into dimensionality() function, but that's probably not causing the issue.

Have you tried excluding the records with the flag like

=if(RowNo() = 0 or IsNull(RowNo()), Sum({$<[Family Code] -= {1001}>} [Total Available Balance]), sum([Total Available Balance]))

dafnis14
Specialist
Specialist
Author

It works!

Thanks!