Granny's Programming Pearls
"inside of every large program is a small program struggling to get out"
The moose likes JDBC and Relational Databases and the fly likes Informix and Blob and CallableStatement Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC and Relational Databases
Bookmark "Informix and Blob and CallableStatement" Watch "Informix and Blob and CallableStatement" New topic

Informix and Blob and CallableStatement

Kishore Nair

Joined: Nov 30, 2004
Posts: 10
I have a stored proc in Informix, which looks like this update_business_object(String,Blob)
This is the code I have:
IfmxCallableStatement ifxCstmt = (IfmxCallableStatement)ifxCon.prepareCall(statement);
ifxCstmt.setString(1, "holidays");
ifxCstmt.setBlob(2, ifb);
IFB is a Ifx blob
if( DEBUG )
System.out.println("Binding of smart large object to table is done");

catch(SQLException se)

This throws a "Unable to resolve procedure" on the execute(). We know for sure that the signature is correct and the proc exists. Any ideas?

Never resign to your fate
Jeanne Boyarsky
author & internet detective

Joined: May 26, 2003
Posts: 32614

What is in the statement object?

[OCA 8 book] [Blog] [JavaRanch FAQ] [How To Ask Questions The Smart Way] [Book Promos]
Other Certs: SCEA Part 1, Part 2 & 3, Core Spring 3, TOGAF part 1 and part 2
Kishore Nair

Joined: Nov 30, 2004
Posts: 10
This is what the statement looks like
String statement = "{call update_business_object(?,?)}";

I have also tried a PreparedStatement which looks like this
"Execute Procedure update_business_object(?,?). Neither one of them work. I can do a prepared statement with "INSERT INTO table_name......" and that works fine. But big bad corporate audit teams want me to call a stored procedure because it is more "secure" :-)
[ December 01, 2004: Message edited by: Kishore Nair ]
I agree. Here's the link:
subject: Informix and Blob and CallableStatement
jQuery in Action, 3rd edition