#1 We need the full exception stacktrace from the JDBC Driver. Right now, the SQLUnit code is consuming this and throwing it's own exception. Only e.getMessage() is being propagated up.
#2 The gui/tui tools seems to support simple select stagements. I was not successfull in running a Stored Proc through these tools. Is this how the tools are implemented?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I am getting following exceptions when I tried to execute a stored proc:
-----------
gui:
[java] SQLUnit GUI Tool
[java] Copyright(c) 2003 The SQLUnit Team
[java] DEBUG [AWT-EventQueue-0] (HandlerFactory.java:49) - >> getInstance(call)
[java] DEBUG [AWT-EventQueue-0] (CallHandler.java:59) - >> process()
[java] Exception caught in generate: Connection(DEFAULT) is NULL or incorrectly specified
[java] net.sourceforge.sqlunit.SQLUnitException: Connection(DEFAULT) is NULL or incorrectly specified
[java] DEBUG [AWT-EventQueue-0] (SymbolTable.java:61) - >> getValue(null)
[java] DEBUG [AWT-EventQueue-0] (SymbolTable.java:155) - >> isVariableName(null)
[java] at net.sourceforge.sqlunit.CallHandler.process(CallHandler.java:73)
[java] DEBUG [AWT-EventQueue-0] (ConnectionRegistry.java:48) - >> getDefaultConnection()
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool.btnGenerateActionPerformed(SQLUnitGUITool.java:477)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool.access$3(SQLUnitGUITool.java:425)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool$5.actionPerformed(SQLUnitGUITool.java:341)
[java] at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1786)
[java] at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1839)
[java] at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
[java] at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
[java] at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:245)
[java] at java.awt.Component.processMouseEvent(Component.java:5100)
[java] at java.awt.Component.processEvent(Component.java:4897)
[java] at java.awt.Container.processEvent(Container.java:1569)
[java] at java.awt.Component.dispatchEventImpl(Component.java:3615)
[java] at java.awt.Container.dispatchEventImpl(Container.java:1627)
[java] at java.awt.Component.dispatchEvent(Component.java:3477)
[java] at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483)
[java] at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
[java] at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
[java] at java.awt.Container.dispatchEventImpl(Container.java:1613)
[java] at java.awt.Window.dispatchEventImpl(Window.java:1606)
[java] at java.awt.Component.dispatchEvent(Component.java:3477)
[java] at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)
[java] at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)
[java] at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
[java] at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
[java] at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
[java] at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
[java] DEBUG [AWT-EventQueue-0] (HandlerFactory.java:49) - >> getInstance(call)
[java] DEBUG [AWT-EventQueue-0] (CallHandler.java:59) - >> process()
[java] Exception caught in generate: Connection(DEFAULT) is NULL or incorrectly specified
[java] DEBUG [AWT-EventQueue-0] (SymbolTable.java:61) - >> getValue(null)
[java] net.sourceforge.sqlunit.SQLUnitException: Connection(DEFAULT) is NULL or incorrectly specified
[java] DEBUG [AWT-EventQueue-0] (SymbolTable.java:155) - >> isVariableName(null)
[java] DEBUG [AWT-EventQueue-0] (ConnectionRegistry.java:48) - >> getDefaultConnection()
[java] at net.sourceforge.sqlunit.CallHandler.process(CallHandler.java:73)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool.btnGenerateActionPerformed(SQLUnitGUITool.java:477)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool.access$3(SQLUnitGUITool.java:425)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool$5.actionPerformed(SQLUnitGUITool.java:341)
[java] at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1786)
[java] at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1839)
[java] at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
[java] at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
[java] at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:245)
[java] at java.awt.Component.processMouseEvent(Component.java:5100)
[java] at java.awt.Component.processEvent(Component.java:4897)
[java] at java.awt.Container.processEvent(Container.java:1569)
[java] at java.awt.Component.dispatchEventImpl(Component.java:3615)
[java] at java.awt.Container.dispatchEventImpl(Container.java:1627)
[java] at java.awt.Component.dispatchEvent(Component.java:3477)
[java] at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483)
[java] at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
[java] at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
[java] at java.awt.Container.dispatchEventImpl(Container.java:1613)
[java] at java.awt.Window.dispatchEventImpl(Window.java:1606)
[java] at java.awt.Component.dispatchEvent(Component.java:3477)
[java] at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)
[java] at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)
[java] at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
[java] at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
[java] at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
[java] at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Answers to your questions:
#1 We need the full exception stacktrace from the JDBC Driver....
There were some issues in being able to throw the full stacktrace when I first wrote the code, we should do this now, at least when setting the debug=true. With debug=true, the stack trace is returned but this is ant's stack trace, which is not of much use. I will work on this and put this in.
#2 The gui/tui tools seems to support simple select stagements...
Both the tools delegate the actual work of building the result to the SQL or Call handler based on what the SQL looks like, basically if it starts with "select" then its SQL handler, else its a call handler. We can probably do better than that though.
The problem you are getting (in your second email) has to do with connection. You may want to use the connection properties file, although I do see that the connection can be entered manually as well.
I will look at these problems and get back to you next week with more details.
-sujit
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have put in functionality so SQLUnit will pass the exception up and if you set the debug attribute of the sqlunit task to true, then it will print the stack trace of the error that occured. Can you give this a try and let me know how it went?
Thanks
Sujit
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Did the new stacktrace functionality work for you? Based on Dave's suggestion, I changed it to print the stack trace regardless of whether the debug attribute is set to true or not.
Were you able to run the tools with the tools property file to specify the connection information?
Thanks
Sujit
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
#1 We need the full exception stacktrace from the JDBC Driver. Right now, the SQLUnit code is consuming this and throwing it's own exception. Only e.getMessage() is being propagated up.
#2 The gui/tui tools seems to support simple select stagements. I was not successfull in running a Stored Proc through these tools. Is this how the tools are implemented?
I am getting following exceptions when I tried to execute a stored proc:
-----------
gui:
[java] SQLUnit GUI Tool
[java] Copyright(c) 2003 The SQLUnit Team
[java] DEBUG [AWT-EventQueue-0] (HandlerFactory.java:49) - >> getInstance(call)
[java] DEBUG [AWT-EventQueue-0] (CallHandler.java:59) - >> process()
[java] Exception caught in generate: Connection(DEFAULT) is NULL or incorrectly specified
[java] net.sourceforge.sqlunit.SQLUnitException: Connection(DEFAULT) is NULL or incorrectly specified
[java] DEBUG [AWT-EventQueue-0] (SymbolTable.java:61) - >> getValue(null)
[java] DEBUG [AWT-EventQueue-0] (SymbolTable.java:155) - >> isVariableName(null)
[java] at net.sourceforge.sqlunit.CallHandler.process(CallHandler.java:73)
[java] DEBUG [AWT-EventQueue-0] (ConnectionRegistry.java:48) - >> getDefaultConnection()
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool.btnGenerateActionPerformed(SQLUnitGUITool.java:477)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool.access$3(SQLUnitGUITool.java:425)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool$5.actionPerformed(SQLUnitGUITool.java:341)
[java] at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1786)
[java] at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1839)
[java] at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
[java] at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
[java] at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:245)
[java] at java.awt.Component.processMouseEvent(Component.java:5100)
[java] at java.awt.Component.processEvent(Component.java:4897)
[java] at java.awt.Container.processEvent(Container.java:1569)
[java] at java.awt.Component.dispatchEventImpl(Component.java:3615)
[java] at java.awt.Container.dispatchEventImpl(Container.java:1627)
[java] at java.awt.Component.dispatchEvent(Component.java:3477)
[java] at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483)
[java] at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
[java] at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
[java] at java.awt.Container.dispatchEventImpl(Container.java:1613)
[java] at java.awt.Window.dispatchEventImpl(Window.java:1606)
[java] at java.awt.Component.dispatchEvent(Component.java:3477)
[java] at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)
[java] at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)
[java] at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
[java] at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
[java] at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
[java] at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
[java] DEBUG [AWT-EventQueue-0] (HandlerFactory.java:49) - >> getInstance(call)
[java] DEBUG [AWT-EventQueue-0] (CallHandler.java:59) - >> process()
[java] Exception caught in generate: Connection(DEFAULT) is NULL or incorrectly specified
[java] DEBUG [AWT-EventQueue-0] (SymbolTable.java:61) - >> getValue(null)
[java] net.sourceforge.sqlunit.SQLUnitException: Connection(DEFAULT) is NULL or incorrectly specified
[java] DEBUG [AWT-EventQueue-0] (SymbolTable.java:155) - >> isVariableName(null)
[java] DEBUG [AWT-EventQueue-0] (ConnectionRegistry.java:48) - >> getDefaultConnection()
[java] at net.sourceforge.sqlunit.CallHandler.process(CallHandler.java:73)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool.btnGenerateActionPerformed(SQLUnitGUITool.java:477)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool.access$3(SQLUnitGUITool.java:425)
[java] at net.sourceforge.guisqlunittool.SQLUnitGUITool$5.actionPerformed(SQLUnitGUITool.java:341)
[java] at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1786)
[java] at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1839)
[java] at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
[java] at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
[java] at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:245)
[java] at java.awt.Component.processMouseEvent(Component.java:5100)
[java] at java.awt.Component.processEvent(Component.java:4897)
[java] at java.awt.Container.processEvent(Container.java:1569)
[java] at java.awt.Component.dispatchEventImpl(Component.java:3615)
[java] at java.awt.Container.dispatchEventImpl(Container.java:1627)
[java] at java.awt.Component.dispatchEvent(Component.java:3477)
[java] at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3483)
[java] at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3198)
[java] at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3128)
[java] at java.awt.Container.dispatchEventImpl(Container.java:1613)
[java] at java.awt.Window.dispatchEventImpl(Window.java:1606)
[java] at java.awt.Component.dispatchEvent(Component.java:3477)
[java] at java.awt.EventQueue.dispatchEvent(EventQueue.java:456)
[java] at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:201)
[java] at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:151)
[java] at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:145)
[java] at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:137)
[java] at java.awt.EventDispatchThread.run(EventDispatchThread.java:100)
Hi Satheesh,
Answers to your questions:
#1 We need the full exception stacktrace from the JDBC Driver....
There were some issues in being able to throw the full stacktrace when I first wrote the code, we should do this now, at least when setting the debug=true. With debug=true, the stack trace is returned but this is ant's stack trace, which is not of much use. I will work on this and put this in.
#2 The gui/tui tools seems to support simple select stagements...
Both the tools delegate the actual work of building the result to the SQL or Call handler based on what the SQL looks like, basically if it starts with "select" then its SQL handler, else its a call handler. We can probably do better than that though.
The problem you are getting (in your second email) has to do with connection. You may want to use the connection properties file, although I do see that the connection can be entered manually as well.
I will look at these problems and get back to you next week with more details.
-sujit
Hi Satheesh,
I have put in functionality so SQLUnit will pass the exception up and if you set the debug attribute of the sqlunit task to true, then it will print the stack trace of the error that occured. Can you give this a try and let me know how it went?
Thanks
Sujit
Hi Satheesh,
Did the new stacktrace functionality work for you? Based on Dave's suggestion, I changed it to print the stack trace regardless of whether the debug attribute is set to true or not.
Were you able to run the tools with the tools property file to specify the connection information?
Thanks
Sujit
The stack trace feature is now in release 3.7 which was release late Friday night. Would appreciate any feedback you can provide.
-sujit