6 Replies Latest reply on Sep 6, 2018 7:53 PM by meenu choudhary

    Cost Calculation

    Ramakrishna Rallapalli



      In my Invoice i have two line for the same product sold in different quantities. The invoice looks as shown below.


      Line TypeCodeQtyCost Total cost
      Modelabcd382.4     247.20
      Modelabcd482.4     329.60
          782.4     576.80


      In Tableau it is calculating as shown below :



      Line TypeCodeQtyActual Cost In Tableau
      Modelabcd7            164.80    1,153.60



      The problem in tableau, it is adding the cost 82.40+ 82.40 = 164.80.  but the actual cost is 82.40 per piece. 


      my calculation formula :      



      IF [LineType]='Model' THEN
      [ModelStandardCost] * [TG Qty]

      Please help to resolve this issue.