+ Reply to Thread
Results 1 to 5 of 5

Checking duplicate codes

  1. #1
    Forum Contributor
    Join Date
    05-17-2010
    Location
    Nigeria, Owerri
    MS-Off Ver
    Excel 2007 and 2013
    Posts
    254

    Checking duplicate codes

    Hi,

    Please I have a file containing list of staff and codes in a sheet named codes. In the confirmation sheet, I want excel to confirm codes that are available in the list and also check duplicates. The countif formular works fine for confirming available but is not checking duplicate. Please what I need is a formular the will also check duplicates.

    Thanks.
    Attached Files Attached Files
    Last edited by [email protected]; 06-26-2013 at 01:52 AM.

  2. #2
    Forum Guru benishiryo's Avatar
    Join Date
    03-25-2011
    Location
    Singapore
    MS-Off Ver
    Excel 2013
    Posts
    5,147

    Re: Checking duplicate codes

    hi there. it seems like you got no sheet named codes. you mean List? it's also good to manually key in the results you wish to see & give egs like which rows should be labelled "Duplicated". let me explain what your formula is doing currently. IF will work parts by parts, whichever comes first as priority.

    so your first IF checks if A1 appears more than 0 times in List. if it appears once, great. it will return "Confirmed". if it appears twice or more, it will ALSO return "Confirmed" since it's your first IF. the IF stops checking after whichever comes first turns TRUE.

    your 2nd COUNTIF seems to have the opposite arguments. you are counting how many times the List appeared in A1 instead of the other way round.

    so my guess is that your 2nd IF should come first and the COUNTIF is:
    =IF(COUNTIF(List!$A$1:$A$25,A1)>1,"Duplicated",IF(COUNTIF(List!$A$1:$A$25,A1)=1,"Confirmed",""))

    but none is a duplicate here since it all appeared only once in List

    Thanks, if you have clicked on the * and added our rep.

    If you're satisfied with the answer, click Thread Tools above your first post, select "Mark your thread as Solved".

    "Contentment is not the fulfillment of what you want, but the realization of what you already have."


    Tips & Tutorials I Compiled | How to Get Quick & Good Answers

  3. #3
    Banned User!
    Join Date
    10-14-2006
    Posts
    1,211

    Re: Checking duplicate codes

    =CHOOSE(MIN(COUNTIF(List!A$1:A$25,A1)+1,3),"","Confirmed","Duplicate")

  4. #4
    Valued Forum Contributor
    Join Date
    10-10-2012
    Location
    New York
    MS-Off Ver
    Excel 2007/2010
    Posts
    337

    Re: Checking duplicate codes

    try this
    =IF(COUNTIF(List!$A$1:$A$25,Confirmation!A1)>1,"Duplicated",IF(COUNTIF(List!$A$1:$A$25,Confirmation!A1)>0,"Confirmed",""))
    Don't just use the answers provided for you. Try to understand how it works by reverse engineering or asking about it.

    Please mark the thread as [SOLVED] (Thread Tools->Mark thread as Solved) when answered.
    If you're happy with an answer given, please click the * under the person's name to boost their reputation.

  5. #5
    Forum Contributor
    Join Date
    05-17-2010
    Location
    Nigeria, Owerri
    MS-Off Ver
    Excel 2007 and 2013
    Posts
    254

    Re: Checking duplicate codes

    Thanks guys. All the formulas worked perfectly. I appreciate.

+ 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