dbTalk Databases Forums  

[BUGS] BUG #1561: wrong detection of number of parameters in java.sql.PreparedStatement

mailing.database.pgsql-bugs mailing.database.pgsql-bugs


Discuss [BUGS] BUG #1561: wrong detection of number of parameters in java.sql.PreparedStatement in the mailing.database.pgsql-bugs forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
Ingolf Knopf
 
Posts: n/a

Default [BUGS] BUG #1561: wrong detection of number of parameters in java.sql.PreparedStatement - 03-26-2005 , 11:44 PM







The following bug has been logged online:

Bug reference: 1561
Logged by: Ingolf Knopf
Email address: iknopf (AT) csc-dd (DOT) de
PostgreSQL version: 8.0.1
Operating system: JDBC
Description: wrong detection of number of parameters in
java.sql.PreparedStatement
Details:

"java.sql.PreparedStatement.executeUpdate()" throws "java.sql.SQLException",
if the prepared sql-string contains '?' within a C-like comment.

Example:
select relname
from pg_class
where /*relowner = ? and*/
relname = ?

In this case, the java.sql.PreparedStatement of PostgreSQL requires two
parameters, but I have only one.

---------------------------(end of broadcast)---------------------------
TIP 3: if posting/reading through Usenet, please send an appropriate
subscribe-nomail command to majordomo (AT) postgresql (DOT) org so that your
message can get through to the mailing list cleanly

Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.