Adding together multiple rows values from columns in unorganized fashion

Gadman

New Member
Joined
Mar 21, 2017
Messages
20
Office Version
  1. 365
Platform
  1. Windows
I have a dump file that unfortunately doesn't organize the rows or columns of data in the same order every time, but does match the right values as needed. I have been working on a formula that can add up multiple row values across several columns and just run into a wall every time :(

Simplified:
For example in Cells B1:D1 I have Jan, Sue, Billy
And in cells A2:A4 I have Cars, Dollars, Pets

Again, the Cars, dollars, and pets can organize sometimes as dollars, pets, cars... Same with Jan Sue and Billy, they could be in any particular order... or any other combination from a dump file that's automatically generated.

I need a formula that can, for example, add up how many Dollars and Cars that Jan has, or how many Pets and Dollars Sue has, or How many Dollars and Pets Billy has... I'm sure once I see a working formula, I can grasp the basis and edit it as I need specifically.

Any help greatly appreciated, thanks.

JanSueBilly
Cars325
Dollars7001000800
Pets2010
 

Excel Facts

Shade all formula cells
To shade all formula cells: Home, Find & Select, Formulas to select all formulas. Then apply a light fill color.
Try sumproduct -

=SUMPRODUCT(($B$1:$E$1=$A11)*($A$2:$A$4=$B11)*$B$2:$E$4)

1588344169154.png
 
Upvote 0
Try sumproduct -

=SUMPRODUCT(($B$1:$E$1=$A11)*($A$2:$A$4=$B11)*$B$2:$E$4)

View attachment 12795
Originally I didn't think that would work because I needed to add two different values, but I simply copied the formula and added another value beside cars and added cars and whatever.

That worked great, thanks!

SOLVED
 
Upvote 0

Forum statistics

Threads
1,215,013
Messages
6,122,690
Members
449,092
Latest member
snoom82

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