7 Replies Latest reply: May 22, 2015 5:53 AM by Michelle Tapper RSS

    Pivot table - count on rows

      Hi all,

       

      I am quite new on Qlik Sense... At the moment I'm doing an applikation with information from a survey. The survey has Qustions with subquestions and our information is organized as follows:

       

      Question  |  QuestionID  |  SubQuestion  |  SubQuestionID  |  Answer

       

      Many questions has subquestions with many alternative answers, organized as a matrix.

       

      (To avoid the problem of synthetic keys, I had to rename SubQuestion in the data model --> Question.SubQuestion

       

      I now want to do a Pivot table showing dimension Answers (showing the different answer alternatives: daily, weekly, monthly and so on) on columns and dimension Subquestions on rows for a specific Question. However, I can't get the results correct and don't know how to fix it. At the moment I'm using one measure which only presents the figures of one subquestion. The measure looks like this:
      COUNT({$<Question.SubQuestionID={7}>}Answer)

       

      My problem is that I don't know how to write a measure that counts all cells/rows.

       

      Thank you in advance for your input and help!!!

       

      Kind regards

      Michelle