View Single Post
  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Toppers
 
Posts: n/a
Default VLookUp function to return multiple rows

Glad to hear it's worked OK.

Coded myself but requests to reformat data are common so it doesn't take
long to put together. It might be useful again.

(I learn a lot from these NGs .. it's never ending!)

"sebastian stephenson" wrote:

Never mind the last post, that worked brilliantly.

Thank you very much.

Did you write the code yourself or pull it from somewhere???
--
Learning SQL and Access


"sebastian stephenson" wrote:

I have set of data

Key Text
1 x
1 y
1 z
2 a
2 b
3 c
3 d

I want to use a function that will return

Key Text
1 x,y,z
2 a,b
3 c,d

I apply the formula:

VlookUp() to the first data set and I only receive the following output

Key Text newText
1 x
2 a
3 c

Does anyone know of a different formula I can use inplace of VLookUp()??

I have tried to apply the following code from a previous example, but this
gives the same results:

=INDEX($B$1:$B$30,SMALL(IF($A$1:$A$30=E3,ROW($A$1: $A$30)),ROW(A1)))

Can anybody help?


--
Learning SQL and Access