2 Replies Latest reply: Aug 9, 2018 12:51 PM by Nayan Mistry RSS

    Only show all company answer if a specific answer has been selected.

    Nayan Mistry

      Hi,

       

      I have encountered this issue a few times and I'm unsure how to get around it. It's difficult to explain out loud but here I go!

       

      I have 3 columns in a table, each its own dimension: CompanyName, Question, Answers.

       

      Say each company is asked 7 questions each, I want to be able to see all the answers of a company if they have answered a specific answer to a specific question.

       

      Example Table:

      CompanyNameQuestionAnswer
      Supplier 1Do we approve:Yes
      Supplier 1ProductApples
      Supplier 1Type of BusinessFood
      Supplier 1AreaUK
      Supplier 1SizeLarge
      Supplier 1InsuredYes
      Supplier 1ContactJohn
      Supplier 2Do we approve:Yes
      Supplier 2ProductBananas
      Supplier 2Type of BusinessFood
      Supplier 2AreaUK
      Supplier 2SizeSmall
      Supplier 2InsuredNo
      Supplier 2ContactBob
      Supplier 3Do we approve:No
      Supplier 3ProductBooks
      Supplier 3Type of BusinessEducation
      Supplier 3AreaEurope
      Supplier 3SizeLarge
      Supplier 3InsuredYes
      Supplier 3ContactSally
      Supplier 4Do we approve:-
      Supplier 4Product-
      Supplier 4Type of Business-
      Supplier 4Area-
      Supplier 4Size-
      Supplier 4Insured-
      Supplier 4Contact-

       

      So for example, I only want to see all 6 answers for every company who have responded 'Yes' to 'Do we approve' and so the below table will be the result:

       

      Output:

      CompanyNameQuestionAnswer
      Supplier 1Do we approve:Yes
      Supplier 1ProductApples
      Supplier 1Type of BusinessFood
      Supplier 1AreaUK
      Supplier 1SizeLarge
      Supplier 1InsuredYes
      Supplier 1ContactJohn
      Supplier 2Do we approve:Yes
      Supplier 2ProductBananas
      Supplier 2Type of BusinessFood
      Supplier 2AreaUK
      Supplier 2SizeSmall
      Supplier 2InsuredNo
      Supplier 2ContactBob

       

      If I were to use the expression:

      If(question like 'Do we approve:' and Answer = 'Yes', CompanyName)

      ...then the table filters to just the two suppliers 1 and 2 and only shows their 1 question 'Do we approve' and its answer 'Yes' and doesn't show the rest of their questions and answers.

       

      In reality, I'm using this to basically create a report where I can review the companies who have responded either 'No' or still null so the 'Yes' companies can be excluded.


      Any help with my example of my real expression will be much appreciated!


      THANK YOU!!!!