wood burning stoves 2.0*
The moose likes JDBC and the fly likes MS Access with DSN Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "MS Access with DSN" Watch "MS Access with DSN" New topic
Author

MS Access with DSN

jamie ong
Greenhorn

Joined: Nov 05, 2001
Posts: 24
Hi,
Just want to ask is it possible for java application to connect to MS access without configuring the DSN? and if i dont have office install on my machine, can the application still connect to the database?
regards
Jamie.
Jamie Robertson
Ranch Hand

Joined: Jul 09, 2001
Posts: 1879

This is how I connect to MSAccess using a dsn-less connection. I believe you will need MSAccess Installed because the jdbc dbc bridge uses its ODBC drivers. Try it with and without to see:

note: spacing matters so just cut and paste your data into this string
Jamie
I had better disable smilies!
[This message has been edited by Jamie Robertson (edited November 12, 2001).]
[This message has been edited by Jamie Robertson (edited November 12, 2001).]
jamie ong
Greenhorn

Joined: Nov 05, 2001
Posts: 24
Thanks a million for the code!
i tried out to run my program without Office installed and it works. Apparently, the ODBC driver comes with the OS.
i will further test the result on other platform.
Thanks again
Jamie.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: MS Access with DSN
 
Similar Threads
jdbc:odbc with DSN less connection for MS Access
Novice to jdbc
Not showing Ms access driver
connect to MS Access database file without making a dsn?
connection to database with struts