View Full Version : Combining Fields


bbulla
10-12-2007, 07:08 AM
Hello,

I need to find a way to modify the following structure:

Name, Page, Grid
Acton Rd, G10, 12
Acton Rd, G10, 4
Acton Rd, G10, 8
Adams Ct, F6, 2

Into something like this:

Name Page Grid
Acton Rd, G10, '4, 8, 12'
Adams Ct, F6, '2'

What is the best way to go about tackling this?? I need to create this in a table so that I can export it from Access and into a .dbf to be used with another program.

Thanks,

Uncle Gizmo
10-12-2007, 10:54 AM
I'm not sure if it's exactly what you want, however I suspect you may be able to adapt the code in this example: (http://www.access-programmers.co.uk/forums/showpost.php?p=308045&postcount=2)

Uncle Gizmo
10-12-2007, 10:56 AM
There is a slightly different version of the same code here which places the results in a text box instead of a query Field . (http://www.access-programmers.co.uk/forums/showpost.php?p=427023&postcount=6)

bbulla
10-12-2007, 11:32 AM
Actually, by searching on 'combine rows into one field', I found a nice bit of code that created a 'Concat' function to combine them the way I needed.

Thanks!