pg.ddx.io pgsql-jdbc@postgresql.org mailing list archive
help / color / mirror / Atom feedPossible Bug with JDBC 8.0-310 JDBC 3
2+ messages / 2 participants
[nested] [flat]
* Possible Bug with JDBC 8.0-310 JDBC 3
@ 2005-02-10 09:44 NielsG <NielsG@aquafold.com>
2005-02-10 19:58 ` Re: Possible Bug with JDBC 8.0-310 JDBC 3 Kris Jurka <books@ejurka.com>
0 siblings, 1 reply; 2+ messages in thread
From: NielsG @ 2005-02-10 09:44 UTC (permalink / raw)
To: pgsql-jdbc
Hi,
I believe there is a bug in JDBC 8 that wasn't there in JDBC 7.4. I
have a function which does a RAISE NOTICE. If I use the 7.4 JDBC driver
and execute it with a Statement.execute("SELECT functionname()"), and
get the warnings with Statement.getWarnings(), the warnings that are
returned do not have any messages with the SQLWarning.getMessage(). I
get the correct number of warnings, but the warning messages are blank.
Doesn't work:
JDBC: JDBC 8.0-310 JDBC 3
Database: Postgresql 8.0 and 7.4.3
Warnings: --->
W (1):
W (2):
W (3):
<---
Works:
JDBC: JDBC 7.4-214 JDBC 3
Database: Postgresql 8.0 and 7.4.3
Warnings: --->
W (1): SNOTICE C00000 my_message_text Fpl_exec.c L1860 Rexec_stmt_raise
W (2): SNOTICE C00000 my_message_text Fpl_exec.c L1860 Rexec_stmt_raise
W (3): SNOTICE C00000 my_message_text Fpl_exec.c L1860 Rexec_stmt_raise
<---
Does anyone know of this bug?
thanks
Niels
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: Possible Bug with JDBC 8.0-310 JDBC 3
2005-02-10 09:44 Possible Bug with JDBC 8.0-310 JDBC 3 NielsG <NielsG@aquafold.com>
@ 2005-02-10 19:58 ` Kris Jurka <books@ejurka.com>
0 siblings, 0 replies; 2+ messages in thread
From: Kris Jurka @ 2005-02-10 19:58 UTC (permalink / raw)
To: NielsG <NielsG@aquafold.com>; +Cc: pgsql-jdbc
On Thu, 10 Feb 2005, NielsG wrote:
> I believe there is a bug in JDBC 8 that wasn't there in JDBC 7.4. I
> have a function which does a RAISE NOTICE. If I use the 7.4 JDBC driver
> and execute it with a Statement.execute("SELECT functionname()"), and
> get the warnings with Statement.getWarnings(), the warnings that are
> returned do not have any messages with the SQLWarning.getMessage(). I
> get the correct number of warnings, but the warning messages are blank.
>
> Doesn't work:
> JDBC: JDBC 8.0-310 JDBC 3
> Database: Postgresql 8.0 and 7.4.3
> W (1):
>
> Works:
> JDBC: JDBC 7.4-214 JDBC 3
> Database: Postgresql 8.0 and 7.4.3
> W (1): SNOTICE C00000 my_message_text Fpl_exec.c L1860 Rexec_stmt_raise
>
> Does anyone know of this bug?
I do now. I've applied a fix to the 8.0 and head branches. In 8.0 we
added some parsing to split out the various fields, but apparently
didn't redirect the getMessage call to actually use them. You will now
get just the message part, so in your example, getMessage should return
"my_message_text".
This fix will go out in the next release, but I've put up temporary jars
if you need them now. http://www.ejurka.com/pgsql/jars/nielsg
Kris Jurka
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2005-02-10 19:58 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2005-02-10 09:44 Possible Bug with JDBC 8.0-310 JDBC 3 NielsG <NielsG@aquafold.com>
2005-02-10 19:58 ` Kris Jurka <books@ejurka.com>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox