skip to main content
DataDirect Connect Drivers : DB2 Driver : Returning and Inserting/Updating XML Data : Inserting/Updating XML Data : Character Data
  
Character Data
Your application can use the following methods to insert or update XML data as character data:
*PreparedStatement.setString()
*PreparedStatement.setCharacterStream()
*PreparedStatement.setClob()
*PreparedStatement.setObject()
*ResultSet.updateString()
*ResultSet.updateCharacterStream()
*ResultSet.updateClob()
*ReultSet.updateObject()
The driver converts the character representation of the data to the XML character set used by the database server and sends the converted XML data to the server. The driver does not parse or remove any XML processing instructions.
Your application can update XML data as ASCII data using the following methods:
*PreparedStatement.setAsciiStream()
*ResultSet.updateAsciiStream()
The driver interprets the data supplied to these methods using the ISO-8859-1 (latin 1) encoding. The driver converts the data from ISO-8859-1 to the XML character set used by the database server and sends the converted XML data to the server.