cocoon-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kevin Sonney <ke...@webslingerz.com>
Subject esql diff of the moment
Date Thu, 14 Sep 2000 20:07:56 GMT
Well, donald has done a supurb job on the newer error handling code in
esql. But not all the JDBC drivers set the message to something
inteligable.

Take, for example, oracle. When the oracle thin driver encounters a Column
index out of bound error, it generates the following inn getMessage() :

0

Wow! How very informative! Thanks Oracle!

So, in order to make life *MUCH* happier, here's a small pacth to dump the
stach trace to the error log. YMMV, and I'm sure there's a better way that
will put it into the doc.

Index: esql.xsl
===================================================================
RCS file: /home/cvspublic/xml-cocoon/src/org/apache/cocoon/processor/xsp/library/sql/esql.xsl,v
retrieving revision 1.12
diff -u -r1.12 esql.xsl
--- esql.xsl	2000/09/06 19:35:43	1.12
+++ esql.xsl	2000/09/14 19:46:42
@@ -266,6 +266,7 @@
 	       } catch (Exception _esql_e) {
 		<exception>
 		 <message><xsp:expr>_esql_e.getMessage()</xsp:expr></message>
+		 <xsp:logic>_esql_e.printStackTrace();</xsp:logic>
 		</exception>
 	       } finally {
 	       if (_esql_session.close_connection) {

-- 
+-------------------------------------------+
| Kevin Sonney        kevin@webslingerZ.com |
| Systems Programmer    www.webslingerZ.com |
+-------------------------------------------+


Mime
View raw message