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 bkrike on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Combine two tables from two databases into one table

Status
Not open for further replies.

needmoremoney

Technical User
Mar 30, 2005
123
US
Can some help me with a sql statement.

I have two access databases. A and B.

I need some tables in A and B to combine together.

For example I want to pull from Database A a table named Adress and the same table from database B into a temp table call ABAdress that is located in A.

I'm trying this:

Select * Into [\\server9\A].ABaddress
From(
Select * From [\\server9\A].address
UNION ALL
Select * From [\\server9\B].address
)temp


Would this work? Or is there a better way. Thanks much.
 
Have you ever tried File | Get External Data | Link Tables?

There ar emany code samples in these forums to show you how to do it programatically, but if your need is simple, then linking to a table on another machine is pretty easy by following the wizard.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top