SUMIFS Dynamic range

LBTravis

New Member
Joined
Oct 1, 2015
Messages
8
I need to sum data for each department. This seems simple but my data's columns are not always in the same order. I'm sure there is a way to find the 'department column in an array then find the wages column and sum particular department names.

It just needs to work with dynamic data.

NameDepartmentWages
Smith, JohnAdmin1000
Spalding, SallySales500
Clooney, GeorgeAdmin700Sales800
Revere, PaulSAles300Admin1700

<tbody>
</tbody>
 

Excel Facts

Format cells as date
Select range and press Ctrl+Shift+3 to format cells as date. (Shift 3 is the # sign which sort of looks like a small calendar).
Try:

=SUMIFS(INDEX(A:C,0,MATCH("wages",INDEX(A:C,1,0),0)),INDEX(A:C,0,MATCH("department",INDEX(A:C,1,0),0)),"sales")
 
Upvote 0
Thank you soooo much!!

Now what if I want to total the "Wages" column but I don't know what column tha's going to end up in.


The formula I proposed determines itself the wages column (the column range to sum) and the department column (the condition range) automatically.
 
Last edited:
Upvote 0

Forum statistics

Threads
1,213,517
Messages
6,114,089
Members
448,548
Latest member
harryls

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