Reputation: 427
I'm struggling to get Squirrel SQL to connect to MS Access database (just a normal one, no password):
I guest this should be a simple straight forward process, but please advise me how to get it working.
Upvotes: 9
Views: 10235
Reputation: 123409
Now that the JDBC-ODBC Bridge has been removed from Java 8 the previous answer to this question will become less relevant over time. The following method uses the UCanAccess JDBC driver.
Go to UCanAccess on Maven Central, Browse the latest version, and download the uber.jar file.
In Squirrel SQL, create a new "Driver" entry for UCanAccess and specify the location of the uber.jar on the "JDBC Driver Class Path" pane
Note: Remember to enter net.ucanaccess.jdbc.UcanaccessDriver
as the "Class Name" (see above).
To open a specific database, create a Squirrel SQL "Alias" entry, replacing the <path_to_database_file>
placeholder with the actual path to the file
Important: Make sure that the connection URL ends with ;showSchema=true
.
Upvotes: 10
Reputation: 427
I found the solution. Put below string in URL:
(Assuming that path to your database file is D:\DBs\DatabaseFile.mdb)
jdbc:odbc:Driver={Microsoft Access Driver (*.mdb, *.accdb)};Dbq=D:\DBs\DatabaseFile.mdb
Upvotes: 2