Add values bast on list search

jahnosha

Board Regular
Joined
Mar 22, 2011
Messages
53
I have a set list of values that repeats itself with the column next to it giving a number which may look like this...
A 7
B 8
C 4
B 3
A 2

and a list on a different sheet with this
A X
B Y
C Z

What string of functions should I use if I want X to be a formula that will search the first list and add all values next to A, Y to add all B values and Z to add all C values?

Thanks!
 

Excel Facts

Lock one reference in a formula
Need 1 part of a formula to always point to the same range? use $ signs: $V$2:$Z$99 will always point to V2:Z99, even after copying
I have a set list of values that repeats itself with the column next to it giving a number which may look like this...
A 7
B 8
C 4
B 3
A 2

and a list on a different sheet with this
A X
B Y
C Z

What string of functions should I use if I want X to be a formula that will search the first list and add all values next to A, Y to add all B values and Z to add all C values?

Thanks!
Try this...

=SUMIF(Sheet1!A$2:A$6,A2,Sheet1!B$2:B$6)

Copy down as needed.
 
Upvote 0
Awesome,
Now what if the text and number values were reversed? I did the same thing but its brining 0's
 
Upvote 0
Awesome,
Now what if the text and number values were reversed? I did the same thing but its brining 0's
If you mean the numbers are in column A and the letters are in column B, then simply reverse the ranges...

=SUMIF(Sheet1!B$2:B$6,A2,Sheet1!A$2:A$6)
 
Upvote 0

Forum statistics

Threads
1,224,602
Messages
6,179,845
Members
452,948
Latest member
UsmanAli786

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