Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> using xmltype and jdbc insert

using xmltype and jdbc insert

From: Scott <scottb022563_at_hotmail.com>
Date: 21 Apr 2003 06:24:19 -0700
Message-ID: <918e20bc.0304210524.6f88453@posting.google.com>


I am having trouble inserting a document into a table. What is the correct datatype to use for a column specfifed as xmltype? here is a simple exmple below. thanks for the help

Scott

CREATE TABLE XML_TEST Oracle 9i
(
  DOC SYS.XMLTYPE
)

import org.w3c.dom.*;

InputStream is=PropertiesUtils.loadResourceAsStream("HealthAutoInventoryInputTemplate.xml");

            Document doc=XMLUtils.createDocFromStream(is);
            stmt=con.prepareStatement("insert into xml_test
values(?)");
            stmt.set????(1,doc);
Received on Mon Apr 21 2003 - 08:24:19 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US