SUMIFS with multiple criteria in columns and rows

k_one

New Member
Joined
Mar 22, 2012
Messages
18
Hi all,


I'm attempting to consolidate a big block of data with two columns and a reference to a month into a summary table and I can't seem to get there.

Essentially I want to sum for example, all the items in the reference table that are CAPEX and Labour for the Month of September into the summary table in C2.

Instead of merging cells D1 and E1 previously I was using OFFSET and I had duplicated the month into both columns but it probably isn't the right way to go about it and I can't figure out how to get it to differentiate between Forecast and Actual because I wrote that formula over a year ago...

(To add a layer of complexity - is there also a way to choose the entire Actuals column over the Forecast column if there are Actuals loaded in the column? So for example I won't have Actuals in the November column yet because it's not November - but if I did can I sum that column instead? Knowing also that not every row is always accounted for each month as resources come and go. If not, I can remove the forecast after entering actuals nbd)

I've been working on this on and off for a week and I'm admitting defeat now! Any help would be more than much appreciated. :rolleyes:

Ref data table:

Sep-18

Oct-18
Nov-18
CAPEX / OPEX
Category
Vendor/Description
Forecast
Actual
Forecast
Actual
Forecast
Actual
OPEX
Travel
Travel
$ 1,162.00
$ 1,200.00
$ 2,400.00
OPEX
Training
Training
$ 10,000.00
OPEX
Prof. Services
Professional Services (Marketing)
$ 6,445.00
$ 45,000.00
OPEX
Legal
External Legal
$ 1,646.00
$ 5,000.00
OPEX
Resource
Change
$ 7,402.00
$ 9,825.00
$ 9,825.00
CAPEX
Labour
Resource 1
$ 93,537.00
$ 20,400.00
$ 15,300.00
CAPEX
Labour
Resource 2
$ 23,161.60
$ 23,161.60
CAPEX
Labour
Resource 3
$ 5,000.00
$ 3,000.00
CAPEX
Labour
Resource 4
$ 11,040.00
$ 11,040.00
CAPEX
Labour
Resource 5
CAPEX
Labour
Resource 6
CAPEX
Labour
Resource 7
CAPEX
Labour
Resource 8
$ 10,000.00
CAPEX
Labour
Resource 9
CAPEX
Vendor
Email issue
CAPEX
Vendor
3rd party implementation
$ 11,000.00

<tbody>
</tbody>



Summary table:

Type
Category
Sep-18
Oct-18
Nov-18
CAPEX
Labour
CAPEX
Vendor
CAPEX
Software
CAPEX
Hardware
OPEX
Resource
OPEX
Training
OPEX
Professional Services
OPEX
Legal
OPEX
Maintenance
OPEX
Travel
OPEX
Other

<tbody>
</tbody>
 

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
Here is how you could do the SUMIFS based on the actual column for each month.

=SUMIFS(INDEX($D$2:$I$18,0,MATCH(1,INDEX(--($D$1:$I$1=C$24),0),0)+1),$A$2:$A$18,$A25,$B$2:$B$18,$B25)

Id suggest making a new column that will take care of the actual/forecast problem you have by using an IF statement. It will be far easier that trying to get one formula to do all.
 
Upvote 0
Heres another which will take care of the columns problems:

=SUMPRODUCT(($A$3:$A$18=$A25)*($B$3:$B$18=$B25)*($D$1:$I$1=C$24)*IF(OFFSET($D$3:$I$18,0,1),OFFSET($D$3:$I$18,0,1),$D$3:$I$18))
 
Upvote 0

Forum statistics

Threads
1,215,674
Messages
6,126,144
Members
449,294
Latest member
Jitesh_Sharma

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top