Skip to Main Content

Java EE (Java Enterprise Edition) General Discussion

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

java.sql.SQLException: Parameter Type Conflict:sqlType=2003

843836Oct 4 2003 — edited Jan 29 2004
Hi,

I am using JDK1.2.2 & Oracle 8.1.7 with JDBC-Thin
driver(classes12.zip).

I have a PL/SQL function calling as below that returns an OUT
parameter of type ARRAY. I am calling this function from jsp program,
the codesnippet is as below:
------------------------------------
try{
//building query to get consulate offices
cstmt = conOracle.prepareCall("{?=call tcs_hr_email_id.generate_emailid(?,?,?,?)}");
cstmt.setInt(2, Integer.parseInt(logPersonID.trim()));
out.println("<br>Success :");
cstmt.setString(3, fstStr.trim());
out.println("<br>Success :");
cstmt.setString(4, mdlStr.trim());
out.println("<br>Success :");
cstmt.setString(5, lstStr.trim());
out.println("<br>Success :");

cstmt.registerOutParameter(1,Types.ARRAY); //Failed HERE
out.println("<br>Not executed :");

cstmt.execute();

arrayElements = (Vector)cstmt.getArray(1);

isExecutable = false;
out.println("<br>arrayElements :"+arrayElements.size());
} //end of try
catch(Exception expDept5)
{
out.print("<BR>Error while inserting the data</BR>"+expDept5);
}
--------------------------------------

The program compiles fine, but when I run it, it throws SQLException at the
line marked as "//Failed HERE" that is "Error while inserting the data :
java.sql.SQLException: Parameter Type Conflict:sqlType=2003"

IT DOES NOT EVEN REACH THE EXECUTE STATEMENT.

Please help and suggest.

Thanks a lot.

Vayyasi
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Feb 26 2004
Added on Oct 4 2003
2 comments
863 views