+ Reply to Thread
Results 1 to 11 of 11

Vlookup and concatenate results - possible with formulas?

  1. #1
    Registered User
    Join Date
    11-21-2012
    Location
    Spain
    MS-Off Ver
    Excel Mac 2008
    Posts
    14

    Vlookup and concatenate results - possible with formulas?

    Hi all,
    I'm using an Excel 2008 for Mac (at work) and we need to do the following.

    We have this list (much longer):
    Please Login or Register  to view this content.
    And we need to group by origin and hour, concatenating results:

    Please Login or Register  to view this content.
    I'm looking for a way to do this in this Excel, with formulas.
    I've seen answers using user defined functions with VB or Kutools, that I can't use in the Mac.

    Any help will be much appreciated.

    Thank you in advance.

  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
    44,099

    Re: Vlookup and concatenate results - possible with formulas?

    This is "work in progress". Please supply more examples. The data you have posted is probably NOT representative.


    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.
    Attached Files Attached Files
    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

  3. #3
    Registered User
    Join Date
    11-21-2012
    Location
    Spain
    MS-Off Ver
    Excel Mac 2008
    Posts
    14

    Re: Vlookup and concatenate results - possible with formulas?

    Thank you Glenn!

    I attach an Excel file with a more real list.
    It's in fact a list of writers signing books at bookshops. (it's St George day in Catalonia, a books festival)

    I see your formula works if there are just 2 destinations and doesn't show nothing if there is a different number.

    Our main problem is that the list is a work in progress. Editors and authors are sending new data every day, that we add to a master Excel file.
    So we don't know how many 'authors' ('origin' column in the OP example) and 'places' (originally 'destinations') we will have in the end.

    Thanks for your help!
    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
    44,099

    Re: Vlookup and concatenate results - possible with formulas?

    In your real data, what is the maximum number of occurrences for a single author/title combination?

  5. #5
    Registered User
    Join Date
    11-21-2012
    Location
    Spain
    MS-Off Ver
    Excel Mac 2008
    Posts
    14

    Re: Vlookup and concatenate results - possible with formulas?

    Not sure if I have understood well your question. My English is far from good.

    1 writer will spend 1 time slot in 1 place.
    i.e. Cervantes will stay in Bookshop1 at 10 ; and he won't return to that place later

    Currently, we have around 350 writers, 100 places, and 15 time slots
    If we put all this in single Excel rows (one row for every unique combination of writer + place + time), we now have 1500 rows.

    Not all places will have a constant amount of writers every time slot (maybe Bookshop1 has 10 writers at 10, but just 6 at 11).

  6. #6
    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
    44,099

    Re: Vlookup and concatenate results - possible with formulas?

    What's the problem with VBA/UDFs???

    What do you see in cell B12 here? It's not your file, I'm just checking....

    Enable macros on opening...
    Attached Files Attached Files

  7. #7
    Registered User
    Join Date
    11-21-2012
    Location
    Spain
    MS-Off Ver
    Excel Mac 2008
    Posts
    14

    Re: Vlookup and concatenate results - possible with formulas?

    The problem is that at work we only have old Excels for Mac, that doesn't allows these macros. (macros windows appear empty).
    There is a technical reason to keep this old Office, according to the IT crew.

    Just in case, I haven't thought about it, we have an updated LibreOffice, that accepts and runs macros.
    I attach 2 images. One is what I see with Excel Mac, and 2nd with updated LibreOffice.

    Captura de pantalla 2017-04-18 a las 16.51.50.png

    Captura de pantalla 2017-04-18 a las 16.38.24.png
    Last edited by nautilia; 04-18-2017 at 10:58 AM.

  8. #8
    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
    44,099

    Re: Vlookup and concatenate results - possible with formulas?

    I'm away for an 8km walk. But it lòoks like it's OK in the first image. You should see the two results D and E concatenated in the same cell, separated by a comma. Look back in two hours.

  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
    44,099

    Re: Vlookup and concatenate results - possible with formulas?

    Back again. Take a look at this. A list of bookshops was generated (in pink) using:

    =IFERROR(INDEX($B$2:$B$51,MATCH(0,INDEX(COUNTIF($F$2:$F2,$B$2:$B$51),0),0)),"")

    This code was pasted into a module (right click on sheet name and view contents of module 1)


    Please Login or Register  to view this content.
    this formula was used to check which authors were at which shop at what times:

    =concatall(IF($B$2:$B$51=$F3,IF($C$2:$C$51=G$2,$A$2:$A$51,""),""),CHAR(10))

    It's an array formula. Each author appears on a separate line because of the use of the "line break" CHAR(10) as the separator. You need to enable text wrapping....


    Array Formulae are a little different from ordinary formulae in that they MUST be confirmed by pressing CTRL+SHIFT+ENTER to activate the array, not just ENTER.

    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...

    In MACs, you will need to check what the equivalent of CTRL-SHIFT-ENTER is. it's version dependent.
    Attached Files Attached Files

  10. #10
    Registered User
    Join Date
    11-21-2012
    Location
    Spain
    MS-Off Ver
    Excel Mac 2008
    Posts
    14

    Re: Vlookup and concatenate results - possible with formulas?

    Glenn, thank you very much!
    I sincerely thank you all your effort. It has been very useful and has saved us hours of manual work.

    With a bit of trial-error in our Mac LibreOffice, your code worked for the full list.
    I couldn't move the formula in the hours row --sure it's because of my inexpertise--, but it run for the rest of the table.

    I'll mark this thread as 'solved'

  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
    44,099

    Re: Vlookup and concatenate results - possible with formulas?

    You don't really need the HOURS formula. It can be done just as easily manually. In any event...

    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. [SOLVED] Concatenate Multiple Vlookup/Index/Match Results with Commas
    By mkay13 in forum Excel Formulas & Functions
    Replies: 5
    Last Post: 12-29-2015, 02:04 PM
  2. Replies: 6
    Last Post: 06-11-2014, 12:54 AM
  3. [SOLVED] Need Formulas to Hide Partial Concatenate Data and Help Determining Two Other Formulas
    By Mattdim805 in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 12-13-2013, 04:11 PM
  4. concatenate listbox results in textbox
    By rickdaw in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-26-2012, 05:46 PM
  5. split text,use in vlookup and concatenate results
    By reghu in forum Excel General
    Replies: 7
    Last Post: 09-07-2010, 07:05 AM
  6. I can't get my concatenate formula results to show
    By Lauren in forum Excel General
    Replies: 3
    Last Post: 11-18-2005, 01:00 PM
  7. Concatenate VBA results and an * in a cell
    By Werner in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 06-30-2005, 12:04 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