+ Reply to Thread
Results 1 to 4 of 4

Array formular - Return only unique values

  1. #1
    Registered User
    Join Date
    06-06-2012
    Location
    Philippine
    MS-Off Ver
    Excel 2007
    Posts
    16

    Array formular - Return only unique values

    Hi,

    I've an array formular where it will returns multiple value. However, i will need it to return only unique values rather than the duplicate values. Could someone please help me with the formular? Thanks in advance. Please find the atatched excel file for further info.

    Regards,
    Jack
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    07-16-2010
    Location
    Northumberland, UK
    MS-Off Ver
    Excel 2007 (home), Excel 2010 (work)
    Posts
    3,054

    Re: Array formular - Return only unique values

    Try changing your formula in B11 to:

    =INDEX($B$2:$B$8, SMALL(IF(($A11=$A$2:$A$8)*(IFERROR(MATCH($B$2:$B$8,INDEX(IF($A$2:$A$8=$A11,$B$2:$B$8),0),0),0)=ROW($A$2:$A$8)-ROW($A$2)+1), ROW($A$2:$A$8)-ROW($A$2)+1), COLUMN(A1)))

    Confirmed with Ctrl-Shift-Enter

    Because this uses the IFERROR function it will not work in versions of Excel prior to 2007.

  3. #3
    Forum Expert daddylonglegs's Avatar
    Join Date
    01-14-2006
    Location
    England
    MS-Off Ver
    Microsoft 365
    Posts
    14,719

    Re: Array formular - Return only unique values

    Try this version in B11

    =IFERROR(INDEX($B$2:$B$8,MATCH(1,($A$2:$A$8=$A11)*(COUNTIF($A11:A11,$B$2:$B$8)=0),0)),"")

    confirmed with CTRL+SHIFT+ENTER
    Audere est facere

  4. #4
    Registered User
    Join Date
    06-06-2012
    Location
    Philippine
    MS-Off Ver
    Excel 2007
    Posts
    16

    Re: Array formular - Return only unique values

    Thanks both for the advice. The code works well.

+ 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