+ Reply to Thread
Results 1 to 15 of 15

Multiple columns into one

  1. #1
    Registered User
    Join Date
    09-21-2017
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    12

    Multiple columns into one

    Hi there,

    I have been looking around, but haven't found a solution which suits my current need! I have found a fair few which are macro based / work but only with adjacent columns.

    I am looking for a formula (not a macro as my colleagues might find it too confusing I'm afraid!), which is able to pull the values from multiple rows in 3 columns and sort it (ideally A-Z) in another column while ignoring duplicates.

    Many thanks in advance for any help!

    Nick

  2. #2
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,900

    Re: Multiple columns into one

    Will you please attach a SMALL sample Excel workbook (10-20 rows of data is usually enough)? Please don't attach a picture of one (no-one will want to re-type all your stuff before starting).

    1. Make sure that your sample data are truly REPRESENTATIVE of your real data. The use of unrepresentative data is very frustrating and can lead to long delays in reaching a solution.

    2. Make sure that your desired solution is also shown (mock up the results manually).

    3. Make sure that all confidential information is removed first!!

    4. Try to avoid using merged cells. They cause lots of problems!

    Unfortunately the attachment icon doesn't work at the moment. So, to attach an Excel file you have to do the following: Just before posting, scroll down to Go Advanced and then scroll down to Manage Attachments. Now follow the instructions at the top of that screen.

    ALSO..... ROUGHLY how many rows do you need to combine in each of your 3 columns???
    Glenn




    None of us get paid for helping you... we do this for fun. So DON'T FORGET to say "Thank You" to all who have freely given some of their time to help YOU.

    Temporary addition of accented to illustrate ongoing problem to the TT: L? fh?ile P?draig sona dhaoibh

  3. #3
    Registered User
    Join Date
    09-21-2017
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    12

    Re: Multiple columns into one

    Thanks for the advice.

    Number of rows varies for the 3 columns. one of them has 600! The other 2 are more reasonable, around 200 and 80

    Please see attached.
    Attached Files Attached Files

  4. #4
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,900

    Re: Multiple columns into one

    Non-sorted can be done (hopefully....) on that sort of scale, without VBA. However, can there be blank cells WITHIN the 600 rows of data? Getting an alphabetical sort as well would kill your PC, i think... If they were contiguous that would be another matter, but, they're not.

  5. #5
    Registered User
    Join Date
    09-21-2017
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    12

    Re: Multiple columns into one

    Within the 600, no, obviously, the others will have "blanks" after the last entry, but not within the ranges for any of the columns.

    Alphabetical not a huge issue, but would be the cherry on top!

  6. #6
    Registered User
    Join Date
    09-21-2017
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    12

    Re: Multiple columns into one

    Just head from a colleague, no longer use the middle columns (with 600 rows).

    Is it possible / easier, with just the two shorter columns?

  7. #7
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,900

    Re: Multiple columns into one

    Yes and no... it'll work, for sure. Sorting, probably still no. What about my Q regarding blanks?

  8. #8
    Registered User
    Join Date
    09-21-2017
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    12

    Re: Multiple columns into one

    No blanks in the columns during the data set

  9. #9
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,900

    Re: Multiple columns into one

    Two dynamic named ranges (CTRL-F3) to adjust ranges to suit... Here's one (List1):

    =Sheet1!$A$4:INDEX(Sheet1!$A$4:$A$1000,COUNTA(Sheet1!$A$4:$A$1000))

    and an array formula to do the work (in I4, copied down):

    =IFERROR(IFERROR(INDEX(List1, MATCH(0, COUNTIF($I$3:I3, List1), 0)), INDEX(List2, MATCH(0, COUNTIF($I$3:I3, List2), 0))), "")


    Array Formulae are a little different from ordinary formulae in that they MUST be confirmed in the FIRST CELL ONLY by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER. After that, the array can be dragged down as normal, to cover the desired range.

    You will know the array is active when you see curly brackets { } - or "curly braces" for those of you in the USA, or "flower brackets" for those of you in India - appear around the outside of your formula. If you do not use CTRL+SHIFT+ENTER you will (almost always) get an error message or an incorrect answer. Press F2 on that cell and try again.

    Don't type the curly brackets yourself - it won't work...
    Attached Files Attached Files

  10. #10
    Registered User
    Join Date
    09-21-2017
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    12

    Re: Multiple columns into one

    Thanks for the solution.

    Not quite sure where I am going wrong, as whenever I do the dynamic named ranges of the array formula I get a popup asking me to select a file to update values? No idea what that means if I'm being honest!

    EDIT:

    Have worked out why it wasnt working for the dynamic ranges. Still having the same with the array formula though!
    Last edited by Nickrox; 09-21-2017 at 08:21 AM.

  11. #11
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,900

    Re: Multiple columns into one

    Nor me. If you haven't created the named ranges correctly wou might get some odd responses. Are you, by any chance, trying to copy values from one workbook to another?

  12. #12
    Registered User
    Join Date
    09-21-2017
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    12

    Re: Multiple columns into one

    What I am trying to do, is to use this spreadsheet as the master and taking information from it to other spreadsheets.

    All the information in this spreadsheet will be entered manually. Has been copied and pasted in in the first instance.

  13. #13
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,900

    Re: Multiple columns into one

    Thats another q altogether. Please post sample of master and slave sheets clearly indicating what you want to appear on the slave...

    Im away for a while now... Couple of hours.

  14. #14
    Registered User
    Join Date
    09-21-2017
    Location
    London
    MS-Off Ver
    Office 365
    Posts
    12

    Re: Multiple columns into one

    Thanks for your help! Ended up just opening a new spreadsheet and got it working!

    Thanks for your help!

  15. #15
    Forum Moderator Glenn Kennedy's Avatar
    Join Date
    07-08-2012
    Location
    Digital Nomad... occasionally based in Ireland.
    MS-Off Ver
    O365 (PC) V 2403
    Posts
    43,900

    Re: Multiple columns into one

    You're welcome.



    If that takes care of your original question, please select "Thread Tools" from the menu link above and mark this thread as SOLVED.

    It'd also be appreciated if you were to click the Add Reputation button at the foot of any of the posts of all members who helped you reach a solution.

+ 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. VBA Code to compare/match multiple columns in one sheet with multiple columns in another
    By cellsearch123 in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 06-27-2016, 09:25 AM
  2. Add Multiple Columns based on same criteria found in multiple columns
    By KathyBNelson in forum Excel Formulas & Functions
    Replies: 4
    Last Post: 08-29-2014, 04:42 PM
  3. Replies: 9
    Last Post: 12-15-2013, 10:05 PM
  4. Combining multiple rows from 2 columns into sorted columns depending on 1st columns value
    By Dexamphetamine in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 08-11-2013, 10:00 AM
  5. Replies: 1
    Last Post: 07-22-2013, 07:08 AM
  6. [SOLVED] Sum Multiple Columns if successful criteria are matched in multiple columns
    By dharmeshchavda in forum Excel Formulas & Functions
    Replies: 2
    Last Post: 04-03-2013, 11:02 PM
  7. Multiple rows with assoicated columns to multiple columns
    By fergiepl7 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 02-09-2013, 03:34 AM

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