Query Help: Grouping like rows (1 Viewer)

woknick

Registered User.
Local time
Today, 12:14
Joined
Sep 25, 2004
Messages
85
I have a table that has 2 colums.

Code:
Room_Number           Items
1                      Chair
2                      Chair
2                      Desk
3                      Table
4                      Computer
4                      Radio
4                      Book
4                      Chair
6                      Fish Tank
6                      Chair

I want a query that will select rooms 1-6 and include all items for those rooms on one row. Example below

Code:
Room_Number           Items
1                      Chair
2                      Chair, Desk
3                      Table
4                      Computer, Radio, Book, Chair
6                      Fish Tank, Chair

I hope this makes sense. Thank you in advance.
 

woknick

Registered User.
Local time
Today, 12:14
Joined
Sep 25, 2004
Messages
85
Would you be able to provide my with an example of how to implement this fuction for my example?
 

pbaldy

Wino Moderator
Staff member
Local time
Today, 12:14
Joined
Aug 30, 2003
Messages
36,134
It's pretty much cut and paste, replacing with your object names. Why don't you give it a try and post back if you get stuck?
 

namliam

The Mailman - AWF VIP
Local time
Today, 21:14
Joined
Aug 11, 2003
Messages
11,695
Another idea could be to use a crosstab query?
 

Users who are viewing this thread

Top Bottom