#1   Report Post  
Posted to microsoft.public.excel.misc
kix kix is offline
external usenet poster
 
Posts: 2
Default Formula to sort

I have two columns 1st column has certain account numbers, the 2nd has those
same numbers plus a couple hundred more. I want to eliminate the account
numbers in 2nd column that do not exist in 1st column. I don't know how to
write a
formula for this.

Thank you.
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 32
Default Formula to sort

by Advanced filter
For Excel 2003, go Data-Filter-Advanced Filters
List range is your 2nd column, Criteria range is 1st column
Check unique records only will show 1 result of each account

by formula
At new column, type =IF(ISERROR(VLOOKUP(B10,$A:$A,1,FALSE)),"Not
Exist","Exist")
Drag down the formula.

Hope it helps.
eksh

"kix" wrote:

I have two columns 1st column has certain account numbers, the 2nd has those
same numbers plus a couple hundred more. I want to eliminate the account
numbers in 2nd column that do not exist in 1st column. I don't know how to
write a
formula for this.

Thank you.

  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 8,520
Default Formula to sort

In cell C1 apply the below formula and copy/drag down as required...Once done
Copy ColCRight click PasteSpecialValues to convert formulas to
values...Sort data wrt ColC and delete the records in ColB for which ColC is
blank

=IF(COUNTIF(A:A,B1),"Exist","")

Col A Col B Col C
1011 1011 Exist
1012 1015 Exist
1013 1002
1015 1005
1013 Exist
1015 Exist


--
Jacob


"kix" wrote:

I have two columns 1st column has certain account numbers, the 2nd has those
same numbers plus a couple hundred more. I want to eliminate the account
numbers in 2nd column that do not exist in 1st column. I don't know how to
write a
formula for this.

Thank you.

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 345
Default Formula to sort

Assuming lists are in column A & B, try this for a list of a/c nos. compiled
from B that also appear in column A.
Assume row 1 has headings then in C2 enter:
=IF(A2="","",IF(ISNUMBER(MATCH(A2,B:B,0)),"",ROW() ))
in D2 enter:
=IF(ROWS($1:1)COUNT(C:C),"",INDEX(A:A,SMALL(C:C,R OWS($1:1))))
Copy both C & D down to the bottom of your list.
Hide column C and D will contain the list you require.
Hope this helps

"kix" wrote:

I have two columns 1st column has certain account numbers, the 2nd has those
same numbers plus a couple hundred more. I want to eliminate the account
numbers in 2nd column that do not exist in 1st column. I don't know how to
write a
formula for this.

Thank you.

Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
SUM formula (sort of) cjones4mvp Excel Worksheet Functions 1 October 9th 09 04:30 PM
Excel - Want to sort by formula value without losing formula HappyPill Excel Discussion (Misc queries) 3 February 4th 08 06:56 PM
Ascending Sort formula, change to neg #: descending sort.. nastech Excel Discussion (Misc queries) 6 July 2nd 07 11:00 PM
HOW DO I SORT USING THE IF FORMULA!!! HERNAN Excel Discussion (Misc queries) 2 July 17th 06 04:58 PM
Sort formula Robert Excel Worksheet Functions 0 May 24th 05 12:58 PM


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

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"