2 Replies Latest reply on Feb 13, 2019 5:23 AM by Ashwini Singh

    Total showing incorrect numbers

    Ashwini Singh

      Hi Everyone


      Here is one challenging situation that I faced in tableau desktop, Please address me.


      Blanks filled using ZN and Lookup, Calculated field created basis on this field however the total is showing incorrect number in table calculation.

      Dashboard has been attached.


      Here few points on which I need assistance


      I . Met#  = if [case created]>=3 then 1 else 0 end, but the grand total is incorrect.

      II. Missed#  = if [case created]<3 then 1 else 0 end, but the grand total is incorrect.

      So it goes to the incorrect grand total of compliance% as well.


      would appreciate if anyone from the forum comes up with a solution.





        • 1. Re: Total showing incorrect numbers
          Michel Caissie



          Here is a little trick to add marks where there is no data.

          Just create a table calc  index()  and put it on the detail shelf.

          When computing the index,  Tableau will add marks where there is no data,  and you will not need  to  lookup you measures.

          Note, this trick only works with specific combination of dimensions on Rows and Columns  and I don't know the exact rules, but it your case it works.


          Now regarding the Total, by default when computing the Total,  Tableau does not simply Sums the value of each cell of the row,  it computes the measure without taking into account the granularity of the row,  so your logic  if value = x  is computed only once using all the records of the context for the specific owner.


          You can change that, by right-clicking each green pill , and selecting  Total using SUM  instead of Automatic.

          For Compliance I used Total using AVG, which is probably what you want since it is a ratio.


          Also, if you look back at your sheet,  since your measures where Table calculations, the options for Total was limited to Automatic, since the other options only works on simple aggregation measures.



          1 of 1 people found this helpful
          • 2. Re: Total showing incorrect numbers
            Ashwini Singh

            Hey Michel


            Woo Hoo......It works for me!!!!!


            Thanks  a ton for your help on this.


            I tried a lot to resolve the above mentioned issue but it didn't worked at all. It failed in some way or others.


            Really appreciate your work and hope same continues to help others in this forum    whenever they need.