3

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

1 Answer 1

5

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.

Sign up to request clarification or add additional context in comments.

2 Comments

I couldn't find any information about that I need to manually choose the class name to make Squirel work with MySQL anywhere except here. What manual or documentation did I miss? Is there any docs mentioning you need to choose the class and how?
If you go into the Help menu item in SQuirreL and go into SQuirreL/How to connect to a database/The Driver you will see "The Class Name specifies the class name of the JDBC driver. Either select an existing entry in the dropdown or key in the class name of the JDBC driver (it can normally be found in the documentation that comes with the driver)."

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.