Forum Discussion

Rena's avatar
Rena
Resolver II
1 year ago
Solved

Total Not Actually Adding - already using SUMX/VALUES

Here is my problem.  I am trying to get an estimated annualized number.  I have the YTD Volume, and the Volume Remaining for the rest of the year.  Dividing these gives me the volume factor (so I can take YTD actuals * the volume factor) to get an annualized number.  Everything works until the totals column.  Instead of summing the Volume Adjusted Yield Loss, it is multiplying the Total Yield Loss * the average volume factor.  

The total for the last column should be $4,106,751 (the sum of the three numbers in the column) but instead it is taking $1,389,422 (total yield loss for the 3 plants) * 2.908 (average volume factor) and only returning a value of $4,040,439.

 

TheoC 

FreemanZ 

  • Rena's avatar
    Rena
    1 year ago

    I probably did this the longest way possible, but it works!  I went through and created a new table that simply had the plant name in one column.  Then I added 3 columns - Volume YTD using the same formula I had for measure, Volume Remaining using the same formula as the measure, and Volume Factor using the same formula for the measure I already had.

     

    Then I changed my measure to this and it worked.

     

     

     

8 Replies

  • Hi Rena 

    You can accomplish it by splitting it into two measures:

    First measure is your normal calculation:

    CALCULATE( SUM(YieldLoss[_BIC_Z_YLD_LSA]), FITLER_CRITERIA )

     

    Then use the SUMX separately:

    Corrected Totals = 
    SUMX( VALUES(BIC_ZAGGRESC), [VA_PO_SFG_Yield_Loss_TEST])
    • hnguy71's avatar
      hnguy71
      Super User

      Hi Rena 

      I see plant as the row in your visual, is that the same field name?

      • hnguy71's avatar
        hnguy71
        Super User

        Okay, let's try a different method...

        VA PO SFG Yield Loss Test =
        
        VAR _Tbl = SUMMARIZE(Yield_List, Yield_Loss[_BIC_ZAGGRESC], "@Value", [VA PO SFG Yield Loss $])
        RETURN
        SUMX(_Tbl, [@Value])