+ Reply to Thread
Results 1 to 7 of 7

Sort results of INDEX/MATCH array formula remove blanks. . .

  1. #1
    Valued Forum Contributor PeteABC123's Avatar
    Join Date
    09-21-2012
    Location
    Chicago, IL
    MS-Off Ver
    MS Office 365 ver 2202
    Posts
    1,104

    Sort results of INDEX/MATCH array formula remove blanks. . .

    Using this array and would like to have the results sorted A->Z (and remove blanks(zeros) if possible:

    in AP8: {=IFERROR(INDEX($G$3:$BK$3, MATCH(0, COUNTIF(AP$7:AP7, $G$3:$BK$3), 0)),"")}

    Entered an adjacent helper col in AO8: =COUNTIF($AP$8:$AP$50,"<="&AP8) and tried sorting by that result, but it will not sort.

    Any ideas on this one?

    Many thanks.

    Pete

  2. #2
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Sort results of INDEX/MATCH array formula remove blanks. . .

    Hi.

    I personally don't like that particular construction. Can you just clarify that you're looking to generate a unique, alphabetical list of entries from the range G3:BK3, excluding any blanks within that range?

    Regards
    Click * below if this answer helped

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

  3. #3
    Valued Forum Contributor PeteABC123's Avatar
    Join Date
    09-21-2012
    Location
    Chicago, IL
    MS-Off Ver
    MS Office 365 ver 2202
    Posts
    1,104

    Re: Sort results of INDEX/MATCH array formula remove blanks. . .

    You nailed it. Need to generate unique list from G3:BK3, eliminating dupes, blanks, and sort results. Helper columns OK.

    Thanks for your interest.

    Pete

  4. #4
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Sort results of INDEX/MATCH array formula remove blanks. . .

    Thanks.

    Put this formula in e.g. E2:

    =SUMPRODUCT((G3:BK3<>"")/COUNTIF(G3:BK3,G3:BK3&""))

    Then put this array formula** in your first cell of choice:

    =IF(ROWS($1:1)>$E$2,"",INDEX($G$3:$BK$3,,MATCH(SMALL(IF(TRANSPOSE(FREQUENCY(IF($G$3:$BK$3<>"",MATCH($G$3:$BK$3,$G$3:$BK$3,0)),COLUMN($G$3:$BK$3)-MIN(COLUMN($G$3:$BK$3))+1)),COUNTIF($G$3:$BK$3,"<"&$G$3:$BK$3)),ROWS($1:1)),COUNTIF($G$3:$BK$3,"<"&$G$3:$BK$3),0)))

    Copy this formula down (though not the one in E2 - that's a one-off) until you start to get blanks for the results.

    Regards


    **Array formulas are not entered in the same way as 'standard' formulas. Instead of pressing just ENTER, you first hold down CTRL and SHIFT, and only then press ENTER. If you've done it correctly, you'll notice Excel puts curly brackets {} around the formula (though do not attempt to manually insert these yourself).

  5. #5
    Valued Forum Contributor PeteABC123's Avatar
    Join Date
    09-21-2012
    Location
    Chicago, IL
    MS-Off Ver
    MS Office 365 ver 2202
    Posts
    1,104

    Re: Sort results of INDEX/MATCH array formula remove blanks. . .

    You are unbelievable!! Thank you!!!!

    Pete

  6. #6
    Forum Expert XOR LX's Avatar
    Join Date
    04-18-2013
    Location
    Turin, Italy
    MS-Off Ver
    Office 365
    Posts
    7,742

    Re: Sort results of INDEX/MATCH array formula remove blanks. . .

    No worries! Glad to help!

    Cheers

  7. #7
    Valued Forum Contributor PeteABC123's Avatar
    Join Date
    09-21-2012
    Location
    Chicago, IL
    MS-Off Ver
    MS Office 365 ver 2202
    Posts
    1,104

    Re: Sort results of INDEX/MATCH array formula remove blanks. . .

    Comment deleted by OP.

    Pete
    Last edited by PeteABC123; 11-14-2014 at 05:19 PM.

+ Reply to Thread

Thread Information

Users Browsing this Thread

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

Similar Threads

  1. How to ignore blanks in an Index/Match Array Formula
    By michaelcarrera in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-06-2015, 08:50 PM
  2. [SOLVED] Index/Match Array with multiple results concatenate in one cell
    By samiesosa in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 01-15-2013, 01:34 PM
  3. Array formula to remove blanks (like autofilter)
    By CST in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 02-13-2012, 12:54 PM
  4. Array formula to remove blanks needs to work in 2003
    By Chinchin in forum Excel General
    Replies: 3
    Last Post: 08-26-2011, 09:15 AM
  5. Sum of results from Index match formula
    By TomJones0505 in forum Excel - New Users/Basics
    Replies: 6
    Last Post: 06-19-2009, 09:49 AM

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