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

Import Query as Table?

Status
Not open for further replies.

Blackshark

Programmer
May 7, 2002
48
GB
Just wondering - can I import a query from an external MDB as a table through VBA? Is it the same code as importing a table?
 
What about a make table query to "import" the data.

SELECT * INTO tblLocal FROM tblExternal IN 'C:\Databases\External.MDB';

 
I've been looking for this for a day and half now! I'm so excited to be this close.

I got an error, the db I'm trying to connect to is password protected. I got the "Invalid Password" error.

How do I include the password in my query?
 
Code:
SELECT * INTO tblLocal 
FROM [;Database=C:\Databases\External.MDB;PWD=thepassword].tblExternal
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top