Forum Discussion

tkainz's avatar
tkainz
Copper Contributor
Jan 21, 2019

calculating sum of values in columns based upon column header

I have 12 columns of data representing the 12 months and a totals column.  I would like a formula to total the individual values in each of the rows of the twelve columns but only if the respective column headers have a certain text value ("Actual" vs. "Budget").  In this example (using 5 months for brevity) the formula in col 6 ("TTL") should only add those values in cols 1 through 5 if row 2 for each corresponding column has the value "Actual".  Thanks!!

 

JanFebMarAprMayTTL
ActualActualActualBudgetBudget 
$100$150$150$200$200$400
  • Hello,

     

    this is easy with the Sumifs function.

     

    =Sumifs(3:3,$2:$2,"Actual")

     

    In words: sum all the values in row 3 where row 2 has the text "Actuals" in the same column. 

    You can copy that formula down to apply to other rows below.

     

    Does that help?

     

  • Hello,

     

    this is easy with the Sumifs function.

     

    =Sumifs(3:3,$2:$2,"Actual")

     

    In words: sum all the values in row 3 where row 2 has the text "Actuals" in the same column. 

    You can copy that formula down to apply to other rows below.

     

    Does that help?

     

Resources