+ Reply to Thread
Results 1 to 8 of 8

Extract a non-sorted list with blank cells into a sorted list

  1. #1
    Registered User
    Join Date
    12-11-2011
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel Pro Plus 2019
    Posts
    67

    Extract a non-sorted list with blank cells into a sorted list

    Found this formula and used it in B2:B1500 as an array formula
    {=INDEX(List,MATCH(MIN(IF(ISBLANK(List)+COUNTIF(B1:$B$1,List),"",IF(ISNUMBER(List),COUNTIF(List,"<"&List),COUNTIF(List,"<"&List)+SUM(IF(ISNUMBER($A$2:$A$15),1,0))+1))),IF(ISBLANK(List)+COUNTIF(B1:$B$1,List),"",IF(ISNUMBER(List),COUNTIF(List,"<"&List),COUNTIF(List,"<"&List)+SUM(IF(ISNUMBER(List),1,0))+1)),0))}

    I have a non-sorted list of values and many blanks (total over 1500 of them) in column A (List). I am able to get a unique sorted list of the values in column B (varies between 50 and 200 unique items). Once the list is created the trailing cells show the ugly "#N/A" in rest of the cells.

    I tried to surround the above formula with an IF(Unique,"AA"," blank ") function, but I keep getting an error that reads "The specified formula cannot be entered because it uses more levels of nesting than are allowed in the current file format."

    Cannot figure out how to get around this error, and get rid of those confusing #N/A's at the end of column B

    Column A looks something like this:
    AA
    21
    8
    "blank"
    XX
    TT
    KK
    "blank"
    AA
    FF
    "blank"
    CC
    8
    9

    Column B should look like this
    8
    9
    21
    AA
    CC
    FF
    KK
    TT
    XX

    I would appreciate a workaround this or a suggestion.
    RJK

  2. #2
    Forum Expert
    Join Date
    08-12-2012
    Location
    Sydney, Australia
    MS-Off Ver
    Excel 2010
    Posts
    5,636

    Re: Extract a non-sorted list with blank cells into a sorted list

    this site has all sorts of formulas you can use
    http://www.get-digital-help.com/exce...rray-formulas/

    for your one
    Formula: copy to clipboard
    Please Login or Register  to view this content.


    where list is named range for your list
    Attached Files Attached Files
    If you are satisfied with the solution(s) provided, please mark your thread as Solved.
    Select Thread Tools-> Mark thread as Solved. To undo, select Thread Tools-> Mark thread as Unsolved.

  3. #3
    Forum Expert
    Join Date
    08-12-2012
    Location
    Sydney, Australia
    MS-Off Ver
    Excel 2010
    Posts
    5,636

    Re: Extract a non-sorted list with blank cells into a sorted list

    alternatively if it gets too slow and complicated you can just make a unique list and then sort it afterwards as i would imagine with 1500 lines it would run slow

  4. #4
    Registered User
    Join Date
    12-11-2011
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel Pro Plus 2019
    Posts
    67

    Re: Extract a non-sorted list with blank cells into a sorted list

    Thanks mate. Now I see what I was doing wrong. You are right it is very slow, but I guess I have to live with that.

    Again thank you for your quick help.

  5. #5
    Forum Expert
    Join Date
    08-12-2012
    Location
    Sydney, Australia
    MS-Off Ver
    Excel 2010
    Posts
    5,636

    Re: Extract a non-sorted list with blank cells into a sorted list

    not a problem

    if the speed does become a problem...

    As you are using excel 2007
    essentially what you can write out is copy the column of data
    sort it and remove duplicates

  6. #6
    Registered User
    Join Date
    12-11-2011
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel Pro Plus 2019
    Posts
    67

    Re: Extract a non-sorted list with blank cells into a sorted list

    OOPS,

    I just noticed the duplicate values are listing all occurrences instead of unique values.

    Any suggestions? The end user does not know how to cut & paste and remove duplicates with "Data".

  7. #7
    Registered User
    Join Date
    12-11-2011
    Location
    Los Angeles, CA
    MS-Off Ver
    Excel Pro Plus 2019
    Posts
    67

    Re: Extract a non-sorted list with blank cells into a sorted list

    When I enclose my formula into an IFERROR(formula,"blank"), I get the smallest value in ALL the cells in column B.

  8. #8
    Forum Expert
    Join Date
    08-12-2012
    Location
    Sydney, Australia
    MS-Off Ver
    Excel 2010
    Posts
    5,636

    Re: Extract a non-sorted list with blank cells into a sorted list

    hmmm how about a different approach that would work much faster

    Pivot table
    refresh pivot table and refreshes data

    works faster
    no messy formula to deal with
    no duplicates
    Attached Files Attached Files

+ 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. [SOLVED] Displaying Lookup List; without Blank entries or Repitition and in Sorted Order
    By Raabi in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 12-07-2014, 01:44 PM
  2. [SOLVED] Extract Unique Values from Long list and Put in Sorted Order
    By snapfade in forum Excel Programming / VBA / Macros
    Replies: 15
    Last Post: 04-08-2013, 09:10 PM
  3. Extract a sorted and ranked unique list of items
    By bruno_ in forum Excel Formulas & Functions
    Replies: 0
    Last Post: 02-11-2013, 09:52 PM
  4. How to copy cells from one sorted list to another
    By excel-novice-2010 in forum Excel General
    Replies: 1
    Last Post: 09-06-2010, 04:02 PM
  5. [SOLVED] Referencing to cells in a sorted list
    By tbobster in forum Excel General
    Replies: 2
    Last Post: 05-08-2006, 02:45 PM

Tags for this Thread

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