+ Reply to Thread
Results 1 to 14 of 14

Unique Dynamic list of numbers from multiple columns

  1. #1
    Forum Contributor
    Join Date
    04-16-2014
    Location
    Witbank, SA
    MS-Off Ver
    Excel 2013
    Posts
    268

    Unique Dynamic list of numbers from multiple columns

    hi good people!,

    Please help me with a formula to extract a unique list of numbers from 3 columns. The columns themselves are different lengths, compared to one another, also, each of these columns is not always the same length. The max number of data in any of these columns would be 20 000 rows, although in 95% of the time, will never contain that much data. I am working with numbers, not text. Lets use columns A, B and C. Thank you all kindly.

  2. #2
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,298

    Re: Unique Dynamic list of numbers from multiple columns

    Try

    =IFERROR(IFERROR(IFERROR(INDEX($A$2:$A$1000, MATCH(0, COUNTIF($D$1:D1, $A$2:$A$1000)+($A$2:$A$1000=""), 0)), INDEX($B$2:$B$1000, MATCH(0, COUNTIF($D$1:D1, $B$2:$B$1000)+($B$2:$B$1000=""), 0))), INDEX($C$2:$C$1000, MATCH(0, COUNTIF($D$1:D1, $C$2:$C$1000)+($C$2:$C$1000=""), 0))), "")

    Enter with Ctrl+Shift+Enter

    Might be easier to copy all data to single column and use "Data" ==> "Remove Duplicates"

  3. #3
    Forum Contributor
    Join Date
    04-16-2014
    Location
    Witbank, SA
    MS-Off Ver
    Excel 2013
    Posts
    268

    Re: Unique Dynamic list of numbers from multiple columns

    Hi JohnTopley,

    I get an excel error "The data you entered is not valid". Yes, I do agree that "remove duplicates" would be the easier way, it's just that the data in the 3 columns change regularly and it's a bit time consuming to perform the copying and so forth...especially if this task is done 5 or more times a day, therefore the "want" to have it work automatically. I would prefer to see the resulting data update live as these columns change...

    Do you think you can please see why the formula is giving this error?

  4. #4
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,298

    Re: Unique Dynamic list of numbers from multiple columns

    I forget to say that the formula should be put in D2. - don't know if that's the problem.

    It worked OK when i tested it with 100 rows of data.

    If you still have an error, post a file with say 200 rows of data.

  5. #5
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Unique Dynamic list of numbers from multiple columns

    This would be relatively easy if you can extract the uniques in sorted order.
    Biff
    Microsoft MVP Excel
    Keep It Simple Stupid

    Let's Go Pens. We Want The Cup.

  6. #6
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,298

    Re: Unique Dynamic list of numbers from multiple columns

    VBA solution:


    Please Login or Register  to view this content.
    With Data starting row 1of A, B , C output in column D row 2 onwards

  7. #7
    Forum Contributor
    Join Date
    04-16-2014
    Location
    Witbank, SA
    MS-Off Ver
    Excel 2013
    Posts
    268

    Re: Unique Dynamic list of numbers from multiple columns

    No, I had the formula in the right place, now it works but for some reason skips some numbers. I have also tried this on a smaller scale, and it works great then but working with 20000 rows in each of the 3 columns, looks problematic. Thanx anyways for your time, I really appreciate your efforts!!. Just to mention, the columns were not really adjacent, and only starts with data from row 3, I did alter the formula to accommodate for this, but don't think that should be the cause?

  8. #8
    Forum Contributor
    Join Date
    04-16-2014
    Location
    Witbank, SA
    MS-Off Ver
    Excel 2013
    Posts
    268

    Re: Unique Dynamic list of numbers from multiple columns

    Yes Tony, that would be...

  9. #9
    Forum Contributor
    Join Date
    04-16-2014
    Location
    Witbank, SA
    MS-Off Ver
    Excel 2013
    Posts
    268

    Re: Unique Dynamic list of numbers from multiple columns

    I have tried this code, it works beautifully!!!..thanx a lot JohnTopley!

  10. #10
    Forum Expert
    Join Date
    05-05-2015
    Location
    UK
    MS-Off Ver
    Microsoft Excel for Microsoft 365 MSO (Version 2402 Build 16.0.17328.20068) 64-bit
    Posts
    28,298

    Re: Unique Dynamic list of numbers from multiple columns

    You're welcome.

    If your problem has been solved, could you please mark thread as such ("Thread Tools" at top of first post)

  11. #11
    Forum Contributor
    Join Date
    04-16-2014
    Location
    Witbank, SA
    MS-Off Ver
    Excel 2013
    Posts
    268

    Re: Unique Dynamic list of numbers from multiple columns

    Sure, thank you..

  12. #12
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Unique Dynamic list of numbers from multiple columns

    Quote Originally Posted by juriemagic View Post
    Yes Tony, that would be...
    Something like this...

    Data Range
    A
    B
    C
    D
    E
    F
    G
    1
    7
    2
    5
    Uniques
    2
    7
    9
    8
    1
    3
    1
    5
    2
    4
    2
    5
    5
    5
    7
    6
    8
    7
    9
    8
    ------
    ------
    ------
    ------
    ------
    ------
    ------


    Enter this formula in G2:

    =MIN(A1:A3,C1:C5,E1:E2)

    This array formula** entered in G3:

    =IFERROR(1/(1/MIN(IF(A$1:A$3>G2,A$1:A$3),IF(C$1:C$5>G2,C$1:C$5),IF(E$1:E$2>G2,E$1:E$2))),"")

    ** array formulas need to be entered using the key
    combination of CTRL,SHIFT,ENTER (not just ENTER).
    Hold down both the CTRL key and the SHIFT key
    then hit ENTER.

    Copy down until you get blanks.
    Last edited by Tony Valko; 06-29-2016 at 11:27 AM.

  13. #13
    Forum Contributor
    Join Date
    04-16-2014
    Location
    Witbank, SA
    MS-Off Ver
    Excel 2013
    Posts
    268

    Re: Unique Dynamic list of numbers from multiple columns

    Hi Tony Valko,

    Do be EXTREMELY honest with you, I really wanted to steer away from VBA for this one, but I have already implemented the code given, and all works just fine now. HOWEVER, I WILL remember this post for future times if I should get myself in a similar position. I really do appreciate all your efforts. Thank you and have a great day..

  14. #14
    Forum Expert Tony Valko's Avatar
    Join Date
    12-31-2011
    Location
    Pittsburgh
    MS-Off Ver
    2002, 2007:2013
    Posts
    18,890

    Re: Unique Dynamic list of numbers from multiple columns

    You're welcome. Thanks for the feedback!

+ 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] Create a unique list from multiple columns with blamks
    By JO505 in forum Excel General
    Replies: 14
    Last Post: 11-18-2015, 08:25 PM
  2. [SOLVED] Dynamic Unique List from multiple dynamic columns
    By JO505 in forum Excel General
    Replies: 7
    Last Post: 06-11-2015, 05:41 PM
  3. Unique list - multiple columns
    By pauldaddyadams in forum Excel General
    Replies: 19
    Last Post: 04-20-2015, 05:20 PM
  4. List of Unique Values from Multiple Columns
    By filkod in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 03-06-2015, 03:57 AM
  5. Replies: 0
    Last Post: 02-25-2015, 10:27 AM
  6. Finding Unique List of Data pulled from multiple columns (Plus sum)
    By emdoak in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 02-09-2015, 10:45 AM
  7. [SOLVED] List unique values from multiple dynamic lists
    By andredl in forum Excel Formulas & Functions
    Replies: 8
    Last Post: 10-22-2014, 02:37 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