From 98b4d55cbc2d5f17aa11c5f5c5315b80827c32a6 Mon Sep 17 00:00:00 2001 From: baztian Date: Thu, 13 Feb 2014 00:02:35 +0100 Subject: [PATCH] Retrieve message for jpype SQLExceptions --- src/jaydebeapi/dbapi2.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/jaydebeapi/dbapi2.py b/src/jaydebeapi/dbapi2.py index 8051ec3..067b868 100644 --- a/src/jaydebeapi/dbapi2.py +++ b/src/jaydebeapi/dbapi2.py @@ -107,8 +107,8 @@ def _handle_sql_exception_jpype(ex): import jpype SQLException = jpype.java.sql.SQLException if issubclass(ex.__javaclass__, SQLException): - # TODO get message and stacktrace - raise Error + # TODO get stacktrace + raise Error, ex.message() else: raise ex