ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Delete unwanted rows (https://www.excelbanter.com/excel-programming/274081-re-delete-unwanted-rows.html)

Ken Wright

Delete unwanted rows
 
With your data in A1:A1500, in cell B1 put the following formula and copy down:-

=IF(COUNTIF($A$1:$A$1500,A1)1,"Keep Me","")

Now select all the data and sort on Col B in descending order.

Then just delete all the unwanted records at the bottom.

--
Regards
Ken....................... Microsoft MVP - Excel
Sys Spec - Win XP Pro / XL2K & XLXP

----------------------------------------------------------------------------
Attitude - A little thing that makes a BIG difference
----------------------------------------------------------------------------



"Gareth" wrote in message
...
I have a sheet of data which is made up of all customer details and updated
ones (all is approx 1,500 and updated 25).

Each customer has an unique ID number so I am able to sort the data so as to
get the 'old' and 'new' data next to each other.

What I want to now is delete every row apart from the customers who have
updated details.

So I would be left with 50 records.

Thanks in advance.

Gareth





Gareth[_3_]

Delete unwanted rows
 
I was hoping not to have to insert another column, can it be done using
code?

"Ken Wright" wrote in message
...
With your data in A1:A1500, in cell B1 put the following formula and copy

down:-

=IF(COUNTIF($A$1:$A$1500,A1)1,"Keep Me","")

Now select all the data and sort on Col B in descending order.

Then just delete all the unwanted records at the bottom.

--
Regards
Ken....................... Microsoft MVP - Excel
Sys Spec - Win XP Pro / XL2K & XLXP

--------------------------------------------------------------------------

--
Attitude - A little thing that makes a BIG difference
--------------------------------------------------------------------------

--



"Gareth" wrote in message
...
I have a sheet of data which is made up of all customer details and

updated
ones (all is approx 1,500 and updated 25).

Each customer has an unique ID number so I am able to sort the data so

as to
get the 'old' and 'new' data next to each other.

What I want to now is delete every row apart from the customers who have
updated details.

So I would be left with 50 records.

Thanks in advance.

Gareth








All times are GMT +1. The time now is 11:15 AM.

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