Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Select Query to merge two identacal tables

Status
Not open for further replies.

jpa

Programmer
Oct 15, 2001
16
0
0
US
I have two tables with identical structures, both linked to different sources that are updated frequently. I would like to write a query that would show all of the data from the two tables as a single unified table with the same fields as the original table.

e.g.

Table1: name, phone
Table2: name, phone

Query: name, phone (showing all records from table1 and table2)
 
Hi

You need a UNION query so:

SELECT Field1, Field2,..etc FROM tbl1
UNION
SELECT Field1, Field2,..etc FROM tbl2
ORDER BY Field1

you can only make a UNION query in SQL view of the query builder, not design view Regards

Ken Reay
Freelance Solutions Developer
Boldon Information Systems Ltd
Website needs upgrading, but for now - UK
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top