• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Need help on Stored Procedure Call with CLOB as IN Parameters

 
Ranch Hand
Posts: 83
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Folks,

I need to call a stored procedure where 2 of its IN parameters are of CLOB data type.

Stored procedure looks something like this


I have to query another application(through web-service) to get Emails, subject , body. I get all of those as String.

So I wrote the code that uses a callable statement and does following


No errors, exceptions are thrown. Code just stops while executing those lines and exits.

ENV: JDK1.6, OJDBC14.JAR in class path.

Any help on troubleshooting this is much appreciated.

Best Regards,
Chintan.
 
Ranch Hand
Posts: 182
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
As far as I remember setString will do the trick for reasonable length Strings in newer drivers. But you should check the documentation for details.

By the way you must also use appropriate driver for your database version.

Regards,
Fatih.
 
Chintan B Shah
Ranch Hand
Posts: 83
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Fatih,

Yes, you are right. I was googling around more after posting this topic and found this link

String To Clob in Java

which also says the same thing.

setString did work for my scenario.

Thanks much.

Best Regards,
Chintan.
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic