• 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

String to XMLType Conversion

 
Greenhorn
Posts: 25
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi everyone... I hope everyone's doing good.

I've run into an issue with XMLType. Here's the problem:

I have an XML stored in a XMLType column in the database. I extracted it from the database, did the parsing, did all the modification and now I have an updated XML string that I need to update back into the column I fetched it from. Now this is where I'm stuck. How can I convert a String containing XML into an XMLType object?

Any ideas?

XMLType has this method:

XMLType.createXML(Connection conn, String xmlString).

I'm trying to use this one. Can anyone tell me how to go about getting the first parameter?
If there is a totally different way to do the String -> XMLType conversion, please let me know that as well.

This is a pure Java app and I'm using iBatis.
 
author & internet detective
Posts: 41860
908
Eclipse IDE VI Editor Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Dibyendu,
I vaguely remember reading you can use stmt.setAsciiStream() for this. I don't remember where I read it though so I don't know how well supported it is.
 
reply
    Bookmark Topic Watch Topic
  • New Topic