You want a crosstab. In Access, use the crosstab wizard. If SQL Server, do a
Google Advanced Groups search in m.p.sqlserver.programming for "crosstab".
Zillions of solutions have been posted there.

Bob Barrows

Tom B wrote:
> This is more of a SQL query question than an asp question.
>
> I've three tables...
> tbl Staff
> ID int IDENTITY
> FName varchar
> LName varchar
>
> tblOffices
> OfficeID int IDENTITY
> Title varchar
>
> tblStaffExtensions
> StaffID int
> OfficeID int
> PhoneExtension char(5)
>
> I'd like a query that returns
> FName LName OfficeTitle Extension OfficeTitle2
> Extension Joe Blow Main Office 1234
> Branch 4321
>
> There are only two offices right now...but you never know when there
> may be more.
> Is this possible? Or am I dreaming?
> Thanks