File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
A friendly place for programming greenhorns!
Big Moose Saloon
Search
|
Java FAQ
|
Recent Topics
Register / Login
Win a copy of
The Mikado Method
this week in the
Agile and other Processes
forum!
JavaRanch
»
Java Forums
»
Java
»
Beginning Java
Author
printStackTrace (); how do I see what it print?
Peter Hammar
Ranch Hand
Joined: Mar 01, 2010
Posts: 34
posted
May 28, 2010 06:35:06
0
Hi!
I am trying an connection to an database. It fails and I want to see why...
catch (java.sql.SQLException ex) { DataCommon.handleError("DataCommon() new DbConnection()", ex, "Something went wrong!", true, true, parent); ex.printStackTrace();
But how can I see what printStackTrace includes?
Regards
Ulf Dittmer
Marshal
Joined: Mar 22, 2005
Posts: 35247
7
posted
May 28, 2010 06:45:23
0
How is this code being run? An application that is started from the command line would print its output to that command line window.
Android apps
–
ImageJ plugins
–
Java web charts
Peter Hammar
Ranch Hand
Joined: Mar 01, 2010
Posts: 34
posted
May 28, 2010 06:46:14
0
Its a
java
application that tries to connect to an database when started. I run it from JDeveloper.
Ulf Dittmer
Marshal
Joined: Mar 22, 2005
Posts: 35247
7
posted
May 28, 2010 06:52:06
0
I'm not familiar with JDeveloper, but I'm sure it has a console window somewhere. If not, run the app from the OS's command line/console window.
I agree. Here's the link:
http://zeroturnaround.com/jrebel
- it saves me about five hours per week
subject: printStackTrace (); how do I see what it print?
Similar Threads
Throwable methods
JPA UserTransaction not rolled back
flow of any application
problem with exception handling
Giving error : ex might not be initialized
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter