mysqljdbcsquirrel-sql

Cant connect to MySQL via Squirrel - Unable to create connection. Check your URL


I can't connect to our database using Squirrel. I am certain my URL is correct as I'm using it via my java code to access the database.

I got the drivers from here: http://dev.mysql.com/downloads/file.php?id=454395

What is interesting is when I add the driver to MySQL in squirrel it shows it as:

com.mysql.fabric.jdbc.FabricMySQLDriver

In the past when I've used squirrel it would just show com.mysql.jdbc.Driver and no "fabric" stuff.

Stack trace:

java.util.concurrent.ExecutionException: java.lang.RuntimeException: java.sql.SQLException: Unable to create connection. Check your URL.
    at java.util.concurrent.FutureTask.report(Unknown Source)
    at java.util.concurrent.FutureTask.get(Unknown Source)
    at net.sourceforge.squirrel_sql.client.mainframe.action.OpenConnectionCommand.awaitConnection(OpenConnectionCommand.java:132)
    at net.sourceforge.squirrel_sql.client.mainframe.action.OpenConnectionCommand.access$100(OpenConnectionCommand.java:45)
    at net.sourceforge.squirrel_sql.client.mainframe.action.OpenConnectionCommand$2.run(OpenConnectionCommand.java:115)
    at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source)
    at java.util.concurrent.FutureTask.run(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.RuntimeException: java.sql.SQLException: Unable to create connection. Check your URL.
    at net.sourceforge.squirrel_sql.client.mainframe.action.OpenConnectionCommand.executeConnect(OpenConnectionCommand.java:171)
    at net.sourceforge.squirrel_sql.client.mainframe.action.OpenConnectionCommand.access$000(OpenConnectionCommand.java:45)
    at net.sourceforge.squirrel_sql.client.mainframe.action.OpenConnectionCommand$1.run(OpenConnectionCommand.java:104)
    ... 5 more
Caused by: java.sql.SQLException: Unable to create connection. Check your URL.
    at net.sourceforge.squirrel_sql.fw.sql.SQLDriverManager.getConnection(SQLDriverManager.java:136)
    at net.sourceforge.squirrel_sql.client.mainframe.action.OpenConnectionCommand.executeConnect(OpenConnectionCommand.java:167)
    ... 7 more

Solution

  • Double-click on the MySQL driver in the Drivers window. Take a look at the class name dropdown at the bottom of the newly opened window. Click on the dropdown arrow and see if you can select the original com.mysql.jdbc.Driver class name.