When trying to connect to an MS Access database using ucanaccess I keep getting the "No suitable driver found" error when using the relative path to my database:
SEVERE: null
java.sql.SQLException: No suitable driver found for jdbc:ucanaccess:PatientLog.accdb
at java.sql.DriverManager.getConnection(DriverManager.java:689)
at java.sql.DriverManager.getConnection(DriverManager.java:247)
at connectiontester.OpenDB.openConnection(OpenDB.java:33)
at connectiontester.ConnectionTester$1.handle(ConnectionTester.java:41)
at connectiontester.ConnectionTester$1.handle(ConnectionTester.java:37)
To make sure my relative path was correct, I used DirectoryStream to get a directory list, and my database (PatientLog.accdb) does show up in the list. Curiously, when I use the full path the error disappears.
Anyone know why? Anyone have a solution so I can use the relative path?
Using Java 1.8 update 45
Netbeans 8.0.2
Windows 8
Ucanaccess 2.0.9.5 (and dependencies)