Sum a column, excluding the duplicates.

Preven123

New Member
Joined
Oct 4, 2012
Messages
2
I have a worksheet that consists of 39729 rows, with many duplications. I need to supply a total of column "D". The total must exclude the duplicates. I hope this makes sense. Thank you.
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.
Welcome to the Board!

If you are using Excel 2007 or newer, on the Data Menu, under the Data Tools ribbon, there is a "Remove Duplicates" button.
You can use that to remove your duplicates, then run your SUM.

If you need to maintain all your original data, I would copy all your data to a new tab, then do the steps above on the copy.
 
Upvote 0
here's a formula - but needs assignment of 2 range names...


Excel 2012
ABCD
1119Range Names:refers to:
2471listA1:A5
3119<<< Duplicatelist_startA1
4553
5119
61143<<< Sum EXCLUDING Duplicates
Sheet1
Cell Formulas
RangeFormula
A6{=SUM(IF(IF(MATCH(list, list, 0)=(ROW(list)-ROW(list_start)+1), (ROW(list)-ROW(list_start)+1), 0)<>0, list, ""))}
Press CTRL+SHIFT+ENTER to enter array formulas.
Named Ranges
NameRefers ToCells
list=Sheet1!$A$1:$A$5
list_start=Sheet1!$A$1
 
Upvote 0
Control+shift+enter, not just enter:

=SUM(IF(FREQUENCY(IF(ISNUMBER(D1:D5),MATCH(D1:D5,D1:D5,0)),ROW(D1:D5)-ROW(D1)+1),D1:D5))
 
Upvote 0

Forum statistics

Threads
1,223,238
Messages
6,170,939
Members
452,368
Latest member
jayp2104

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