2 Replies Latest reply on Aug 22, 2016 2:01 PM by Suraj Shah

    Calculation across filters

    Suraj Shah

      Hi,

       

      I have attached a Tableau workbook (v 9.3) with my problem. I have also attached the sample data in excel. I have described the steps in the dashboard itself but please also find them below.

       

      1. I have a value: 'Kris' available in two different fields Org2 and Org3.

      2. I have both Org2 and Org3 as filters.

      3. When I pick 'Kris' in Org2 I get a count of 10.

      4. When I pick 'Kris' in Org3 I get a count of 4.

       

      Expected output: I want to know if, when I pick Kris in either of the filters, I can get a sum of the two numbers (10+4) 14. Also, please note, I want the functionality to be dynamic to accommodate the logic for any other value in the filters.

       

      Help is much appreciated.

      Thanks,

      Suraj.

        • 1. Re: Calculation across filters
          Naveen Agarwal

          The reason you are not able to do this is because Kris is part of 2 different hierarchies. Kris appears in Org 2 but also in Org 3 under Jeff's (Org 1) Organization. You will need to make sure Org 2 shows both Jeff and Kris to be able to get the right count. See screen shot below.

           

          Do you need to be able to count the total number of times "Kris" appears in your dataset? In that case, you will have to setup a calculated Field.

           

          1 of 1 people found this helpful
          • 2. Re: Calculation across filters
            Suraj Shah

            Hi Naveen,

             

            Thank you for the reply. Yes, I understand Kris is in different organizations and that's what is causing me the issue.

             

            If I were to count the number of time Kris appears in my data set, how would I do that? Can you help with the formula I write in the calculated field?

             

            I am afraid, even after that, when I pick a value in the filter, the count will be incorrect, because it'll try and limit the count to the filter selected.

             

            Thanks,

            Suraj.