+ Reply to Thread
Results 1 to 4 of 4

Distinct values

  1. #1
    Registered User
    Join Date
    02-21-2012
    Location
    America
    MS-Off Ver
    Excel 2003
    Posts
    5

    Thumbs up Distinct values

    Am trying to list distinct values in a column from a column of another sheet.
    ColA Col B
    A 3
    B 4
    B 4
    C 5
    A 3
    C 5
    B 4

    Always A, b and C are having same values for Col B

    am trying to get the below output:

    A 3
    B 4
    C 5

    I used If and COuntif, but not possible. Can somebody help me
    Last edited by kushibobby; 02-23-2012 at 07:58 AM.

  2. #2
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Distinct values

    Did you try using Advanced Filter for Unique Values?

    Go to Sheet2, select Data|Filter|Advanced filter, select Copy to another Location and check Unique Records only... select the List range from Sheet1, then select the cell you want to copy to in Sheet2 in the Copy To field.
    Where there is a will there are many ways.

    If you are happy with the results, please add to the contributor's reputation by clicking the reputation icon (star icon) below left corner

    Please also mark the thread as Solved once it is solved. Check the FAQ's to see how.

  3. #3
    Registered User
    Join Date
    02-21-2012
    Location
    America
    MS-Off Ver
    Excel 2003
    Posts
    5

    Re: Distinct values

    Hi NBVC,

    THanks for your reply.

    But am trying to have a formula.can u pls help

    Regards

  4. #4
    Forum Expert NBVC's Avatar
    Join Date
    12-06-2006
    Location
    Mississauga, CANADA
    MS-Off Ver
    2003:2010
    Posts
    34,898

    Re: Distinct values

    Assuming your data is in Sheet1, A2:B8 (not including headers)

    Then in Sheet2, A2 enter:

    =LOOKUP(REPT("z",255),CHOOSE({1,2},"",INDEX(Sheet1!A$2:A$8,MATCH(0,INDEX(COUNTIF($A$1:$A1,Sheet1!$A$2:$A$8),0),0)),""))

    confirmed with CTRL+SHIFT+ENTER not just ENTER and copied down as far as needed.

    In B2 enter:

    =IF(A2="","",VLOOKUP(A2,Sheet1!$A$2:$B$8,2,0))

    copied down same distance.

+ 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