Click here to Skip to main content
15,889,695 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi There, I am having problem of ODBC connection with access files. I got 2 access files from client, the one for the program file including interface, the other one is data file that only contains tables.

The program file supposed to connect to the data file through ODBC connection but it failed to connect. What I done is following:

1. Create DSN with access driver and named that ODBC connection as the name that pre-set in the program file and point to the data file by selecting data file in the dialog. - Error: ODBC--connection to <ODBC DSN name> failed.

2. Recreate link to ODBC Database by selecting "External Data" > "More" > "ODBC Database" > "Link to the source data into a new table in the current database" > "Machine data source" > pick the DSN Ive created. - Error: "You cannot use ODBC to import from, export to, or link an external Microsoft Access or ISAM database table to your database."

3. Tried that same DSN from Excel to see if its working - Working fine.

Env:
- Windows 7 Pro
- Tried with both MS Access 2010 and 2007 - Result is same.

I googled what the error means but what I found is that I could be using SQL driver instead of access driver in the DSN setting which is not true.

Please let me know if you have any clue to resolve this.

Thanks!
Posted
Updated 5-Oct-15 1:33am
v2
Comments
Maciej Los 5-Oct-15 8:01am    
What's error message?
vikas vyas 5-Oct-15 8:14am    
Error: "You cannot use ODBC to import from, export to, or link an external Microsoft Access or ISAM database table to your database."

1 solution

The error message is quite clear.

Go to External Data, don't pick ODBC but pick Access.
Then look up the database file and link the tables you need.
 
Share this answer
 
Comments
Maciej Los 5-Oct-15 13:41pm    
Wow! The shortest answer on the world!
+5!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900