output results of multiple queries.

  • Thread starter Thread starter Matthew
  • Start date Start date
M

Matthew

I have four separate queries that each return one column
of reasults. Is there a way to have the results of each
of the four queries output to the same excel file? For
example, the results of query 1 output to Column A,
results of query 2 output to Column B. Any advice is
greatly appreciated. thanks,

matthew
 
Matthew,

In order to return each ColumnA of each query so it occupies a separate
column in the final query, there must be something that forms a relationship
between each query. In the query below, that relationship is formed by the
ID column in each query.

SELECT Query1.Field1 AS OField1,
Query2.Field1 AS OField2,
Query3.Field1 AS OField3,
Query4.Field1 AS OField4
FROM ((Query1 INNER JOIN Query2 ON Query1.ID = Query2.ID)
INNER JOIN Query3 ON Query1.ID = Query3.ID)
INNER JOIN Query4 ON Query1.ID = Query4.ID

Regards,
Graham R Seach
Microsoft Access MVP
Sydney, Australia
 
Back
Top