For Oracle 8i, PreparedStatement Query fails for Key.
CGI Tokyo
Greenhorn
Joined: Nov 13, 2001
Posts: 3
posted
0
I m using Oracle 8i with JDBC Thin Driver. I use PreparedStatement to do a Table Update, there is a key Criteria for the Update. Though the Record is present in DB (for that key), the Update gives shows 0 Records updated and Table is not updated. If I pad the Key with spaces for the column length (eg if the key column is 20 characters long, and key is msgID, I pad it with 14 spaces), the Query works!!! If there any solution to this problem without Padding?
"CGI Tokyo", The Java Ranch has thousands of visitors every week, many with surprisingly similar names. To avoid confusion we have a naming convention, described at http://www.javaranch.com/name.jsp . We require names to have at least two words, separated by a space, and strongly recommend that you use your full real name. This account will be closed, please re-register and select a new name which meets the requirements. Thanks. Dave
is the column datatype CHAR or VARCHAR? regarding the query,does it work when left padded or right padded with blanks? ...you'll have to change your name first though. Jamie
I agree. Here's the link: http://ej-technologies/jprofiler - if it wasn't for jprofiler, we would need to
run our stuff on 16 servers instead of 3.
subject: For Oracle 8i, PreparedStatement Query fails for Key.