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

Sum of rows in pivot table with "dynamic" columns

Hi all! I'm rather new to Qlik and new to this community so here goes 🙂 I have googled for a solution but can't find anything that would work for my use case. If you happen to have a good link, let me know! 

I'm building a pivot table and would like to have the sums of each row in the column farthest to the right.

The use case is to quickly overview which apps from App store, people in surveys are using. The rows would be the different applications (which could be all the different apps available in App store, hence a lot of rows if no filter is on), and the columns would be the different respondents. The values in the cells would be 0 = not using, 1 = using. I have tried visualising this in a table (see picture 1).

The expression for the values is Count(Distinct(Application)).

I would like to be able to filter on e.g. Respondent 1 and Respondent 3, and then see only the applications that are used by both of them (see picture 2). The rows containing applications that are used by only one of them, would not be visualized.

Thanks in advance!

Labels (1)
1 Reply
marcus_sommer

You may take a look on the AND-Mode - Qlik Community - 1471352 but it's not always trivial because the data-structures within the data-model must support the requirements.

Another approach is to connect the origin expression with any kind of a boolean logic, which may go in your case maybe in this direction:

count(distinct Application) * -(count(distinct total <Application> Respondent)=2)

whereby the boolean condition counts the Respondent by ignoring per TOTAL statement their dimensionality on the application-level. Instead of the fix value of 2 you may add a getselectedcount() and/or adjusting the check with further loops and/or any thresholds.