sum in list

nada

Board Regular
Joined
Jul 4, 2006
Messages
193
Hi! I have a long list with bank names and depost values. The list of banks is sorted based on bank names. One bank can occur several times in the list (but since it is sorted they come after each other). I want to have the sum of deposit values for every bank. How can this be done?
Example:
Cititgroup 120
Cititgroup 100
Cititgroup 54
ABN 320
ABN 140
etc.

I want to have a third column with the sums like this:

Cititgroup 120
Cititgroup 100
Cititgroup 54 274
ABN 320
ABN 140 460
etc.

Any help very much appreciated! Thanks alot!
 

Excel Facts

Does the VLOOKUP table have to be sorted?
No! when you are using an exact match, the VLOOKUP table can be in any order. Best-selling items at the top is actually the best.

Aladin Akyurek

MrExcel MVP
Joined
Feb 14, 2002
Messages
85,209
Hi! I have a long list with bank names and depost values. The list of banks is sorted based on bank names. One bank can occur several times in the list (but since it is sorted they come after each other). I want to have the sum of deposit values for every bank. How can this be done?
Example:
Cititgroup 120
Cititgroup 100
Cititgroup 54
ABN 320
ABN 140
etc.

I want to have a third column with the sums like this:

Cititgroup 120
Cititgroup 100
Cititgroup 54 274
ABN 320
ABN 140 460
etc.

Any help very much appreciated! Thanks alot!

C2, copied down:

=IF(A2<>A3,SUMIF($A$2:A2,A2,$B$2:B2),"")
 

Richard Schollar

MrExcel MVP
Joined
Apr 19, 2005
Messages
23,707
Hi

Sounds like a SUMIF would suit your needs:

=SUMIF(A:A,C1,B:B)

where A and B columns holds your list of names and balances and C1 holds the name of the bank for which you wish to sum for.

Best regards

Richard

EDIT: Please ignore my post - completely misread the requirement. I'll leave it up as a monument to my own stupidity
 

nada

Board Regular
Joined
Jul 4, 2006
Messages
193
hi! Thanks that works fine except when there is a bank with only one occurence. Please help me with this! thanks alot!
 

Aladin Akyurek

MrExcel MVP
Joined
Feb 14, 2002
Messages
85,209
hi! Thanks that works fine except when there is a bank with only one occurence. Please help me with this! thanks alot!

What is wrong with a bank with only one occurrence?
 

Forum statistics

Threads
1,136,305
Messages
5,674,984
Members
419,540
Latest member
Nereus A

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
Top