Bugs item #1757923, was opened at 2007-07-21 06:36
Message generated for change (Comment added) made by nielsnes
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=482468&aid=1757923&group_id=56967
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: SQL/Core
Group: SQL CVS Head
>Status: Closed
>Resolution: Fixed
Priority: 5
Private: No
Submitted By: Bharani (bharani_monetdb)
Assigned to: Niels Nes (nielsnes)
Summary: SQL: Prepared statement type mismatch
Initial Comment:
I am trying to execute this sql as prepared statement
update reason set failurereason=? where ID=?
reason is a table with two columns
ID is integer
failurereason is a string
During the batch execution i see
exec 3('whatever',2);
in the batch and then i get
MALException:(unknown):wrong argument for prepared statement (expected int
instead of char)
Looks like the types are getting swapped or dosnt maintain the proper order
Thanks
Bharani
----------------------------------------------------------------------
>Comment By: Niels Nes (nielsnes)
Date: 2007-08-12 21:36
Message:
Logged In: YES
user_id=43556
Originator: NO
Fixed checked into the release branch. The problem was that the parameters
were handled only in the semantic phase. Now we allready handle them in the
parser which solves the order problem.
----------------------------------------------------------------------
Comment By: Fabian (mr-meltdown)
Date: 2007-07-26 10:45
Message:
Logged In: YES
user_id=963970
Originator: NO
TEST ADDED
clients/src/java/tests/Test_PStypes
sql/src/jdbc/tests/Tests/Test_PStypes
modified existing test program to include the update statement as in this
bug
----------------------------------------------------------------------
Comment By: Fabian (mr-meltdown)
Date: 2007-07-26 10:29
Message:
Logged In: YES
user_id=963970
Originator: NO
I tried to tarzan around in Niels' jungle, but I can't find it. So I
guess Niels should solve this. It looks like the arguments of the
where_clause are added first to the params list, resulting in this wrong
order.
----------------------------------------------------------------------
Comment By: Fabian (mr-meltdown)
Date: 2007-07-26 08:59
Message:
Logged In: YES
user_id=963970
Originator: NO
never mind, I changed the test to match your statement, and indeed the
server returns the variables in the wrong order for both M4 and M5.
----------------------------------------------------------------------
Comment By: Fabian (mr-meltdown)
Date: 2007-07-26 08:49
Message:
Logged In: YES
user_id=963970
Originator: NO
Hi bharani,
Is it possible to provide a JDBC logfile for this case? Our testing does
a very similar test every night (e.g. Test_PStypes) which doesn't fail. I
suspect you case is slightly different, for instance in the order of
columns. Is ID earlier defined than failurereason in the create statement
for instance? A log of the prepare (anonymised data is fine, I'm looking
for the return of the actual prepare, and the exec commands) would help to
get some grip on this issue.
----------------------------------------------------------------------
Comment By: Stefan Manegold (stmane)
Date: 2007-07-25 15:45
Message:
Logged In: YES
user_id=572415
Originator: NO
fixed/extended administrative info.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=482468&aid=1757923&group_id=56967
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Monetdb-bugs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-bugs