ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   remove all duplicate records (https://www.excelbanter.com/excel-discussion-misc-queries/242971-remove-all-duplicate-records.html)

dberger16

remove all duplicate records
 
Is there a way to remove the duplicate record(s) and the original record at
the same time in a worksheet? Thanks.
--
DaveB


Gary''s Student

remove all duplicate records
 
Say we have records in column A from A2 thru A100. In B2 enter:
=COUNTIF(A$2:A$100,A2) and copy down. For example:

animal spec
dog 2
cat 1
rat 1
hat 1
bat 2
bat 2
dog 2

Next set an AutoFilter on column B and filter:
Custom... Not equals 1

Then delete the visible rows (they will have blue row numbers). Then remove
the AutoFilter to reveal:

animal spec
cat 1
rat 1
hat 1

--
Gary''s Student - gsnu200903


"dberger16" wrote:

Is there a way to remove the duplicate record(s) and the original record at
the same time in a worksheet? Thanks.
--
DaveB



All times are GMT +1. The time now is 02:00 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com