Solved

Java Derby with Squirrel SQL

Posted on 2007-03-26
5
1,006 Views
Last Modified: 2011-10-03
I am using jre 1.6, java db 10.1.3.1, squirrel sql 2.4.1
I follow this instruction
http://db.apache.org/derby/integrate/SQuirreL_Derby.html#Configuring+SQuirreL+for+the+Derby+Embedded+JDBC+Driver
to set my driver (my driver is at C:\Sun\SDK\javadb\lib\derby.jar)

But I keep getting
org.apache.derby.iapi.services.context.ShutdownException:

followed is the stack trace:
org.apache.derby.iapi.services.context.ShutdownException:
      at org.apache.derby.iapi.services.context.ContextService.getFactory(Unknown Source)
      at org.apache.derby.jdbc.InternalDriver.<init>(Unknown Source)
      at org.apache.derby.jdbc.Driver20.<init>(Unknown Source)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
      at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
      at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
      at java.lang.reflect.Constructor.newInstance(Unknown Source)
      at java.lang.Class.newInstance0(Unknown Source)
      at java.lang.Class.newInstance(Unknown Source)
      at net.sourceforge.squirrel_sql.fw.sql.SQLDriverManager.registerSQLDriver(SQLDriverManager.java:75)
      at net.sourceforge.squirrel_sql.fw.sql.SQLDriverManager$MyDriverListener.propertyChange(SQLDriverManager.java:191)
      at java.beans.PropertyChangeSupport.firePropertyChange(Unknown Source)
      at java.beans.PropertyChangeSupport.firePropertyChange(Unknown Source)
      at net.sourceforge.squirrel_sql.fw.util.PropertyChangeReporter.firePropertyChange(PropertyChangeReporter.java:63)
      at net.sourceforge.squirrel_sql.fw.sql.SQLDriver.setJarFileNames(SQLDriver.java:281)
      at net.sourceforge.squirrel_sql.client.gui.db.DriverInternalFrame.applyFromDialog(DriverInternalFrame.java:253)
      at net.sourceforge.squirrel_sql.client.gui.db.DriverInternalFrame.performOk(DriverInternalFrame.java:230)
      at net.sourceforge.squirrel_sql.client.gui.db.DriverInternalFrame.access$200(DriverInternalFrame.java:60)
      at net.sourceforge.squirrel_sql.client.gui.db.DriverInternalFrame$3.actionPerformed(DriverInternalFrame.java:382)
      at javax.swing.AbstractButton.fireActionPerformed(Unknown Source)
      at javax.swing.AbstractButton$Handler.actionPerformed(Unknown Source)
      at javax.swing.DefaultButtonModel.fireActionPerformed(Unknown Source)
      at javax.swing.DefaultButtonModel.setPressed(Unknown Source)
      at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(Unknown Source)
      at java.awt.Component.processMouseEvent(Unknown Source)
      at javax.swing.JComponent.processMouseEvent(Unknown Source)
      at java.awt.Component.processEvent(Unknown Source)
      at java.awt.Container.processEvent(Unknown Source)
      at java.awt.Component.dispatchEventImpl(Unknown Source)
      at java.awt.Container.dispatchEventImpl(Unknown Source)
      at java.awt.Component.dispatchEvent(Unknown Source)
      at java.awt.LightweightDispatcher.retargetMouseEvent(Unknown Source)
      at java.awt.LightweightDispatcher.processMouseEvent(Unknown Source)
      at java.awt.LightweightDispatcher.dispatchEvent(Unknown Source)
      at java.awt.Container.dispatchEventImpl(Unknown Source)
      at java.awt.Window.dispatchEventImpl(Unknown Source)
      at java.awt.Component.dispatchEvent(Unknown Source)
      at java.awt.EventQueue.dispatchEvent(Unknown Source)
      at net.sourceforge.squirrel_sql.client.Application$1.dispatchEvent(Application.java:168)
      at java.awt.EventDispatchThread.pumpOneEventForFilters(Unknown Source)
      at java.awt.EventDispatchThread.pumpEventsForFilter(Unknown Source)
      at java.awt.EventDispatchThread.pumpEventsForHierarchy(Unknown Source)
      at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
      at java.awt.EventDispatchThread.pumpEvents(Unknown Source)
      at java.awt.EventDispatchThread.run(Unknown Source)


What is the likely to be the problem? Any input  is welcome:)
0
Comment
Question by:william007
  • 2
5 Comments
 
LVL 30

Expert Comment

by:Mayank S
ID: 18793587
I *think* its to do with your default Java version and classpath.
0
 
LVL 9

Accepted Solution

by:
william007 earned 0 total points
ID: 18806492
I manage get it to work now, but does not really know what crucial step that I make to make it work. I am using NetBeans IDE 5.5. Last step I make is, open the runtime tab, right click on the Java DB(network), and click "connect using", enter my user name and pasword, click on OK. After that I try to connect using Squirrel SQL, and it works.

Since I have not changed my classpath and install a new java version(I am using jdk 1.6), hence I suspect this is not the problem.

Since I have managed to get it work, I would like to closed this question by refunding.  Thanks for the assistance.
0
 
LVL 30

Expert Comment

by:Mayank S
ID: 18813492
>>  click "connect using", enter my user name and pasword, click on OK.

That's the reason - the authenticaiton being used earlier was incorrect
0

Featured Post

What is SQL Server and how does it work?

The purpose of this paper is to provide you background on SQL Server. It’s your self-study guide for learning fundamentals. It includes both the history of SQL and its technical basics. Concepts and definitions will form the solid foundation of your future DBA expertise.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article describes some very basic things about SQL Server filegroups.
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
This video teaches viewers about errors in exception handling.
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

773 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question