+ Reply to Thread
Results 1 to 5 of 5

delete unwanted IDs

Hybrid View

  1. #1
    Registered User
    Join Date
    04-11-2012
    Location
    singapore
    MS-Off Ver
    Excel 2003
    Posts
    26

    delete unwanted IDs

    Hi all,

    I need help badly, this is causing me sleepless nights.

    my IDs are not in order, so might need to look in the range rather than row by row. (or can autofilter them in ascending order)

    IDstest.zip

    but my main objective is to find out the IDs NOT in AID from BID. (i.e. if AID do not have 111 and BID does, get rid of 111)

    so am not sure if 1 code will do and just drag down, but thats the idea.

    not necessary to delete, could just make a marking like 'x' in a new column also works fine.

    my idea is,
    Row 1=if(BID1 <> AID1:600, then delete)
    Row 2=if(BID2 <> AID1:600, then delete)
    drag down

    hope for some help here, thanks.

    regards,
    Melvyn

  2. #2
    Forum Expert Fotis1991's Avatar
    Join Date
    10-11-2011
    Location
    Athens(The homeland of the Democracy!). Greece
    MS-Off Ver
    Excel 1997!&2003 & 2007&2010
    Posts
    13,744

    Re: delete unwanted IDs

    Hi

    Im C2, and copy down.

    =IF(COUNTIF($A$2:$A$600;B2)=0;"x";"")

    Change the semi-colons to comma if you have to do this.

    Is this, helps you?
    Regards

    Fotis.

    -This is my Greek whisper to Europe.

    --Remember, saying thanks only takes a second or two. Click the little star * below, to give some Rep if you think an answer deserves it.

    Advanced Excel Techniques: http://excelxor.com/

    --KISS(Keep it simple Stupid)

    --Bring them back.

    ---See about Acropolis of Athens.

    --Visit Greece.

  3. #3
    Forum Expert dilipandey's Avatar
    Join Date
    12-05-2011
    Location
    Dubai, UAE
    MS-Off Ver
    1997 - 2016
    Posts
    8,191

    Re: delete unwanted IDs

    Hi Melvyn,

    Use below forumla in column C and drag it down:-

    =IF(ISNUMBER(MATCH($B2,A:A,0)),"","x")

    Regards,
    DILIPandey

    <click on below 'star' if this helps>
    DILIPandey, Excel rMVP
    +919810929744 (India), +971528225509 (Dubai), dilipandey@gmail.com

  4. #4
    Valued Forum Contributor
    Join Date
    04-30-2012
    Location
    Australia
    MS-Off Ver
    Excel 2010
    Posts
    547

    Re: delete unwanted IDs

    Hi,

    enter this formula into cell C2:

    =IF(ISNA(MATCH(A2,B:B,0)),"",A2)

    Copy down to row 538. Then add a header in C1 and sort by that column. The result is the list of codes that are in column A AND in column B.

    See attached file.

    regards,
    Attached Files Attached Files

  5. #5
    Registered User
    Join Date
    04-11-2012
    Location
    singapore
    MS-Off Ver
    Excel 2003
    Posts
    26

    Re: delete unwanted IDs

    Guys,

    Thank you, it helped. Appreciate your kindness. Up reputation.

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1