XML Parsing from Template

Ok, I'm very new to Oracle, porting from SQL Server. Getting a bit lost.
I have an XML template similar to :
<?xml version="1.0"?>
<xsql:query connection="demo" xmlns:xsql="urn:oracle-xsql" >
SELECT 'Hello World' AS "GREETING" FROM DUAL
</xsql:query>
We have a Windows 2000 based Web server. The problem is that the above select statement is not being converted into a database action and is just displayed in the browser as a string.
I have read about Servlets and XML Parsers and XML Developers Kits but am not sure what I need. Presumably something installed on our Windows Web Server? Is this correct? We do have Java support installed on the Oracle server.
Hopefully when I understand what needs installing I will know where to find a file XSQLConfig.xml which will let me configure the database connection to the alias name 'demo'. I will then be ok creating an XSL stylesheet.
We are using Oracle 8i.
Thanks for any pointers, help, advice etc.

This forum is dedicated to Oracle XML DB, which is a feature of Oracle9iR2. Questions related to earlier versions of the database are better posted in the XML forum under the technology heading

Similar Messages

  • Remove xml parser from the database

    I am deinstalling a version of xml and putting a newer version of
    it. how do i do that? I know that there is something like
    dropjava , but still there are other packages which are loaded
    into the schema. I want to clean out the earlier version and
    install the new version in a clean manner.
    Thanks
    nidhi
    null

    you'll need to write SQL to write SQL
    based on the USER_OBJECTS table
    where:
    SELECT 'drop java class '''&#0124; &#0124;
    dbms_java.longname(object_name)&#0124; &#0124;''';'
    from user_objects where
    OBJECT_TYPE = 'JAVA CLASS'
    and DBMS_JAVA.LONGNAME(OBJECT_NAME)
    LIKE 'oracle/xml/parser/%'
    This will spew out a set of DROP JAVA CLASS
    command which you can capture in a file
    using SQL*Plus':
    SPOOL somefilename
    command. Then run that spool file as a
    SQL script and all the right classes
    will be dropped.

  • XML Parsing From A String (Not a File)

    Hi all,
    I've been looking throughout this forum and still can't find a total answer to my question. I was wondering if it is possible to do the following:
    I want to pass in a string of XML code to a java stored procedure; the XML string looking like the following (for example):
    <Table-Name="PersonalInfo">
    <row>
    <First-Name>Bob</First-Name>
    <Last-Name>Smith</Last-Name>
    <Age>55</Age>
    </row>
    </Table-Name>
    We don't want to be passing in an XML file; we want to pass in the actual string of XML code that would be in the file.
    Is it possible to put into the DOM format (like every example I've seen so far) by parsing an XML formatted string? If so, how would I go about doing that?
    Thanks in advance!
    Jadie

    <Table-Name="PersonalInfo">
    <row>
    <First-Name>Bob</First-Name>
    <Last-Name>Smith</Last-Name>
    <Age>55</Age>
    </row>
    </Table-Name>This is exactly what JAXB is for! :)
    With JAXB unmarshalling against an XSD file can be applied to any InputStream, etc.
    Take a look at JAXB, and you'll find it'll be just what you're looking for. :)
    In fact, here's a short segment of the XSD you'd write for the above:
    <xsd:complexType name="PersonalInfo">
    <xsd:sequence>
    <xsd:element name="row" type="PersonalInfoRow" minOccurs="0" maxOccurs="unbounded"/>
    <xsd:sequence>
    </xsd:complexType>
    <xsd:complexType name="PersonalInfoRow">
    <xsd:sequence>
    <xsd:element name="First-Name" type="xsd:string" minOccurs="1" maxOccurs="1"/>
    <xsd:element name="Last-Name" type="xsd:string" minOccurs="1" maxOccurs="1"/>
    <xsd:element name="Age" type="xsd:int" minOccurs="1" maxOccurs="1"/>
    <xsd:sequence>
    </xsd:complexType>
    Also, perhaps redesign your XML a little, since each table will be different, simply use its name as the tags...i.e. <PersonalInfo></PersonalInfo> and change the <row> to <PersonalInfo> since <row> is pretty generic and will probably occur many times in other places.
    Hope this helps you along your way. :)
    -G

  • Changing xml parser from xerces 1 to xerces 2

    Hi
    Iam installing opencms 6.2 on weblogic 9.1, opencms 6.2 requires xerces 2 whereas the default version for weblogic 9.1 is xerces 1. Please help in changing from xerces1 to xerces 2 in weblogic 9.1
    Any help would be graetly appreciated
    Thanks
    Chaitanya

    don't use the goto functions and don't use scene info for
    navigation. use the goto methods and frame labels:
    on (release) {
    _root.gotoAndPlay ("Scene 2_Frame1"); // <- label this
    frame
    }

  • XML Parser Limitations?

    I'm having problems using the XML Parser from
    Oracle. I've encountered this both in the
    transviewer beans as well as my own implemenatation of the parser.
    The problem occurs when I use an XSL document with a for-each declarative in it. Internet Explorer successfully parses an XML document using this XLS file, but when I use the Oracle Transviewer, the data from the XML document is not parsed into the output.
    Is this an error of mine or a limitation of XML Parser?
    Here are my XML and XLS docs:
    <?xml version = '1.0'?><?xml-stylesheet type="text/xsl" href="cd.xsl"?>
    <PatientSummary>
    <PATIENT>
    <PatName>JONES
    </PatName>
    <PatFirstName>FRED Z
    </PatFirstName>
    <PatGenderCode>M
    </PatGenderCode>
    <PatBirthDtm>06Jul1976
    </PatBirthDtm>
    <PatPrimAddressStreet>123 Main Street
    </PatPrimAddressStreet>
    <PatPrimAddressPost>498555
    </PatPrimAddressPost>
    <PatPrimAddressCity>Edmonton
    </PatPrimAddressCity>
    <PatPrimPhoneNum>6045374321
    </PatPrimPhoneNum>
    </PATIENT>
    <PATIENT>
    <PatName>JONES
    </PatName>
    <PatFirstName>FRED Z
    </PatFirstName>
    <PatGenderCode>M
    </PatGenderCode>
    <PatBirthDtm>06Jul1976
    </PatBirthDtm>
    <PatPrimAddressStreet>123 Main Street
    </PatPrimAddressStreet>
    <PatPrimAddressPost>498555
    </PatPrimAddressPost>
    <PatPrimAddressCity>Edmonton
    </PatPrimAddressCity>
    <PatPrimPhoneNum>6045374321
    </PatPrimPhoneNum>
    </PATIENT>
    </PatientSummary>
    <?xml version = '1.0'?>
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/TR/WD-xsl">
    <xsl:template match="/">
    <html>
    <body>
    <xsl:for-each select="PatientSummary/PATIENT">
    <table border="2" bgcolor="yellow">
    <tr>
    <td>
    <xsl:value-of select="PatName"/>
    </td>
    </tr>
    <tr>
    <td>
    <xsl:value-of select="PatFirstName"/>
    </td>
    </tr>
    <tr>
    <td>
    <xsl:value-of select="PatGenderCode"/>
    </td>
    </tr>
    <tr>
    <td>
    <xsl:value-of select="PatBirthDtm"/>
    </td>
    </tr>
    <tr>
    <td>
    <xsl:value-of select="PatPrimAddressStreet"/>
    </td>
    </tr>
    <tr>
    <td>
    <xsl:value-of select="PatPrimAddressPost"/>
    </td>
    </tr>
    </table>
    </xsl:for-each>
    </body>
    </html>
    </xsl:template>
    </xsl:stylesheet>
    null

    Hi,
    For the XSL file, you need to use
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/XSL/Transform/1.0" version="1.0">
    instead of
    <xsl:stylesheet xmlns:xsl="http://www.w3.org/TR/WD-xsl">
    We were able to parse the file with this modification. If this does not solve your problem, please provide us with some description of the error that you are getting.
    Thank you,
    Oracle XML Team

  • XML Parse issues when using Network Data Model LOD with Springframework 3

    Hello,
    I am having issues with using using NDM in conjuction with Spring 3. The problem is that there is a dependency on the ConfigManager class in that it has to use Oracle's xml parser from xmlparserv2.jar, and this parser seems to have a history of problems with parsing Spring schemas.
    My setup is as follows:
    Spring Version: 3.0.1
    Oracle: 11GR2 and corresponding spatial libraries
    Note that when using the xerces parser, there is no issue here. It only while using Oracle's specific parser which appears to be hard-coded into the ConfigManager. Spring fortunately offers a workaround, where I can force it to use a specific parser when loading the spring configuration as follows:
    -Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl But this is an extra deployment task we'd rather not have. Note that this issue has been brought up before in relation to OC4J. See the following link:
    How to change the defaut xmlparser on OC4J Standalone 10.1.3.4 for Spring 3
    My question is, is there any other way to configure LOD where it won't have the dependency on the oracle parser?
    Also, fyi, here is the exception that is occurring as well as the header for my spring file.
    org.springframework.beans.factory.xml.XmlBeanDefinitionStoreException:
    Line 11 in XML document from URL [file:/C:/projects/lrs_network_domain/service/target/classes/META-INF/spring.xml] is invalid;
    nested exception is oracle.xml.parser.schema.XSDException: Duplicated definition for: 'identifiedType'
         at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:396)
         [snip]
         ... 31 more
    Caused by: oracle.xml.parser.schema.XSDException: Duplicated definition for: 'identifiedType'
         at oracle.xml.parser.v2.XMLError.flushErrorHandler(XMLError.java:425)
         at oracle.xml.parser.v2.XMLError.flushErrors1(XMLError.java:287)
         at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:331)
         at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:222)
         at oracle.xml.jaxp.JXDocumentBuilder.parse(JXDocumentBuilder.java:155)
         at org.springframework.beans.factory.xml.DefaultDocumentLoader.loadDocument(DefaultDocumentLoader.java:75)
         at org.springframework.beans.factory.xml.XmlBeanDefinitionReader.doLoadBeanDefinitions(XmlBeanDefinitionReader.java:388)Here is my the header for my spring configuration file:
    <?xml version="1.0" encoding="UTF-8"?>
    <beans xmlns="http://www.springframework.org/schema/beans"
           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xmlns:aop="http://www.springframework.org/schema/aop"
           xmlns:tx="http://www.springframework.org/schema/tx"
           xmlns:context="http://www.springframework.org/schema/context"
           xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
           http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop.xsd
           http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd
           http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd">Thanks, Tom

    I ran into this exact issue while trying to get hibernate and spring working with an oracle XMLType column, and found a better solution than to use JVM arguments as you mentioned.
    Why is it happening?
    The xmlparserv2.jar uses the JAR Services API (Service Provider Mechanism) to change the default javax.xml classes used for the SAXParserFactory, DocumentBuilderFactory and TransformerFactory.
    How did it happen?
    The javax.xml.parsers.FactoryFinder looks for custom implementations by checking for, in this order, environment variables, %JAVA_HOME%/lib/jaxp.properties, then for config files under META-INF/services on the classpath, before using the default implementations included with the JDK (com.sun.org.*).
    Inside xmlparserv2.jar exists a META-INF/services directory, which the javax.xml.parsers.FactoryFinder class picks up and uses:
    META-INF/services/javax.xml.parsers.DocumentBuilderFactory (which defines oracle.xml.jaxp.JXDocumentBuilderFactory as the default)
    META-INF/services/javax.xml.parsers.SAXParserFactory (which defines oracle.xml.jaxp.JXSAXParserFactory as the default)
    META-INF/services/javax.xml.transform.TransformerFactory (which defines oracle.xml.jaxp.JXSAXTransformerFactory as the default)
    Solution?
    Switch all 3 back, otherwise you'll see weird errors.  javax.xml.parsers.* fix the visible errors, while the javax.xml.transform.* fixes more subtle XML parsing (in my case, with apache commons configuration reading/writing).
    QUICK SOLUTION to solve the application server startup errors:
    JVM Arguments (not great)
    To override the changes made by xmlparserv2.jar, add the following JVM properties to your application server startup arguments.  The java.xml.parsers.FactoryFinder logic will check environment variables first.
    -Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl -Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl -Djavax.xml.transform.TransformerFactory=com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl
    However, if you run test cases using @RunWith(SpringJUnit4ClassRunner.class) or similar, you will still experience the error.
    BETTER SOLUTION to the application server startup errors AND test case errors:
    Option 1: Use JVM arguments for the app server and @BeforeClass statements for your test cases.
    System.setProperty("javax.xml.parsers.DocumentBuilderFactory","com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl");
    System.setProperty("javax.xml.parsers.SAXParserFactory","com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl");
    System.setProperty("javax.xml.transform.TransformerFactory","com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl");
    If you have a lot of test cases, this becomes painful.
    Option 2: Create your own Service Provider definition files in the compile/runtime classpath for your project, which will override those included in xmlparserv2.jar.
    In a maven spring project, override the xmlparserv2.jar settings by creating the following files in the %PROJECT_HOME%/src/main/resources directory:
    %PROJECT_HOME%/src/main/resources/META-INF/services/javax.xml.parsers.DocumentBuilderFactory (which defines com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl as the default)
    %PROJECT_HOME%/src/main/resources/META-INF/services/javax.xml.parsers.SAXParserFactory (which defines com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl as the default)
    %PROJECT_HOME%/src/main/resources/META-INF/services/javax.xml.transform.TransformerFactory (which defines com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl as the default)
    These files are referenced by both the application server (no JVM arguments required), and solves any unit test issues without requiring any code changes.
    This is a snippet of my longer solution for how to get hibernate and spring to work with an oracle XMLType column, found on stackoverflow.

  • How do I create individual xml files from the parsed data output of a xml file?

    I have written a program (DOM Parser) that parses data from a XMl File. I would like to create an individual file with the corresponding name for each set of data parsed from the xml document. If the parsed output is Single, Double, Triple, I would like to create an individual xml file (Single.xml, Double.xml, Triple.xml)with those corresponding names. How do I create the xml files and give each file the name of my parsed data output? Thanks in advance for your help.
    import java.io.IOException;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;
    import javax.xml.parsers.ParserConfigurationException;
    import org.w3c.dom.Document;
    import org.w3c.dom.Element;
    import org.w3c.dom.Node;
    import org.w3c.dom.NodeList;
    import org.xml.sax.SAXException;
    public class MyDomParser {
      public static void main(String[] args) {
      DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
      try {
      DocumentBuilder builder = factory.newDocumentBuilder();
      Document doc = builder.parse("ENtemplate.xml");
      doc.normalize();
      NodeList rootNodes = doc.getElementsByTagName("templates");
      Node rootNode = rootNodes.item(0);
      Element rootElement = (Element) rootNode;
      NodeList templateList = rootElement.getElementsByTagName("template");
      for(int i=0; i < templateList.getLength(); i++) {
      Node theTemplate = templateList.item(i);
      Element templateElement = (Element) theTemplate;
      System.out.println("Template" + ": " +templateElement.getAttribute("name")+ ".xml");
      } catch (ParserConfigurationException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
      } catch (SAXException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
      } catch (IOException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();

    Ive posted the new code but now I'm getting a FileAlreadyExistException error. How do I handle this exception error correctly in my code?
    import java.io.IOException;
    import java.nio.file.FileAlreadyExistsException;
    import java.nio.file.Files;
    import java.nio.file.Paths;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;
    import javax.xml.parsers.ParserConfigurationException;
    import org.w3c.dom.Document;
    import org.w3c.dom.Element;
    import org.w3c.dom.Node;
    import org.w3c.dom.NodeList;
    import org.xml.sax.SAXException;
    public class MyDomParser {
      public static void main(String[] args) {
      DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
      try {
      DocumentBuilder builder = factory.newDocumentBuilder();
      Document doc = builder.parse("ENtemplate.xml");
      doc.normalize();
      NodeList rootNodes = doc.getElementsByTagName("templates");
      Node rootNode = rootNodes.item(0);
      Element rootElement = (Element) rootNode;
      NodeList templateList = rootElement.getElementsByTagName("template");
      for(int i=0; i < templateList.getLength(); i++) {
      Node theTemplate = templateList.item(i);
      Element templateElement = (Element) theTemplate;
      System.out.println(templateElement.getAttribute("name")+ ".xml");
      for(int i=0; i < templateList.getLength(); i++) {
      Node theTemplate = templateList.item(i);
      Element templateElement = (Element) theTemplate;
      String fileName = templateElement.getAttribute("name") + ".xml";
      Files.createFile(Paths.get(fileName));
      System.out.println("File" + ":" + fileName + ".xml created");
      } catch (ParserConfigurationException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
      } catch (SAXException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();
      } catch (IOException e) {
      // TODO Auto-generated catch block
      e.printStackTrace();

  • Parsing XML files from application server

    I need to read  an XML file from the application server. This can be done using OPEN DATASET in BINARY MODE and reading into internal table of type binary data.
    But inorder to parse the document using the iXML library, i need to pass the filesize of the XML file that is read into internal table.
    Please let me know how to calculate this filesize ?

    Hi ,
    Check the FM : /SAPDMC/LSM_F4_SERVER_FILE.
    Inside this FM , subroutine below exists.The main program for routine is /SAPDMC/LLSMW_AUX_020F02.
    Call this routine from your program. You will get the length in bytes from the field len of table pt_file.
    data:
      begin of gs_file,
        directory(75) type c,              " name of directory.
                                           " (possibly truncated.)
        name(75)    type c,                " name of entry.
                                           " (possibly truncated.)
        type(10)    type c,                " type of entry: directory, file
        *len(8)      type p,                " length in bytes*
        owner(8)    type c,                " owner of the entry
        mtime(6)    type p,                " last modification date,
                                           " seconds since 1970
        mode(9)     type c,                " like "rwx-r-x--x":
                                           " protection mode
        errno(3)    type c,
        errmsg(40)  type c,
        mod_date    type d,
        mod_time(8) type c,                " hh:mm:ss
        subrc like sy-subrc,
    end of gs_file.
    DATA : pt_file LIKE TABLE OF gs_file.
    DATa : p_ok.
      PERFORM /sapdmc/llsmw_aux_020f02(directory_contents_get)
      TABLES   pt_file
                                USING    '/TMP' ""!!! Here is your filepath
                                CHANGING p_ok

  • Calling Web Service from PL/SQL (ORA-31011: XML parsing failed)

    hi all,
    i want to invoke a web service from PL/SQL.
    i found a soap_api package from "Tim Hall".
    but it gives error in "ealtas.soap_api.invoke function"
    ORA-31011: XML parsing failed
    ORA-19202: Error occurred in XML processing
    LPX-00007: unexpected end-of-file encountered
    ORA-06512: at "SYS.XMLTYPE", line 48
    ORA-06512: at "EALTAS.SOAP_API", line 135
    ORA-06512: at line 44
    set scan off;
    declare
    P_ADRES_WS VARCHAR2(100) := 'http://<host>:<port>/dswsbobje/qaawsservices/biws?wsdl=1&cuid=AVhBxL14I2dDjz8yFoznRLY';
    P_ENVELOPE VARCHAR2(32767);
    P_FNC VARCHAR2(256) := 'runQueryAsAService';
    ol_req ealtas.soap_api.t_request;
    ol_resp ealtas.soap_api.t_response;
    message varchar2(500);
    BEGIN
    p_envelope := '<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:db="DB_SUBS_BUDGET">
    <soapenv:Body>
    <db:runQueryAsAService>
    <db:login>DWH_BO</db:login>
    <db:password>Pass1234</db:password>
    </db:runQueryAsAService>
    </soapenv:Body>
    </soapenv:Envelope>
    ol_req := ealtas.soap_api.new_request(P_FNC, 'xmlns="'||P_ADRES_WS||'"');
    ol_resp := ealtas.soap_api.invoke(ol_req, P_ADRES_WS, p_fnc,P_ENVELOPE);
    ealtas.soap_api.show_envelope(p_envelope);
    message := ealtas.soap_api.get_return_value(ol_resp, 'Db_Timeid', 'xmlns:m="'||P_ADRES_WS||'"');
    DBMS_OUTPUT.PUT_LINE('AAAA -'||message);
    end;
    thanks.
    ealtas.

    AlexAnd thanks for your help.
    ACL is ok.
    can you help me about how can i edit this function. i tried many times but i could not do it :( .
    web service url : <host>:<port>/dswsbobje/qaawsservices/biws?WSDL=1&cuid=AVhBxL14I2dDjz8yFoznRLY
    what must be these variables values ?
    l_url :=
    l_namespace :=
    l_method :=
    l_soap_action :=
    l_result_name :=
    this is the xml;
    <?xml version="1.0" encoding="UTF-8" ?>
    - <definitions xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:s="http://www.w3.org/2001/XMLSchema" xmlns:s0="DB_SUBS_BUDGET" xmlns:tns1="dsws.businessobjects.com" targetNamespace="DB_SUBS_BUDGET" xmlns="http://schemas.xmlsoap.org/wsdl/" name="queryasaservice">
    - <types>
    - <s:schema elementFormDefault="qualified" targetNamespace="DB_SUBS_BUDGET">
    - <s:element name="runQueryAsAService">
    - <s:complexType>
    - <s:sequence>
    <s:element name="login" type="s:string" />
    <s:element name="password" type="s:string" />
    </s:sequence>
    </s:complexType>
    </s:element>
    - <s:complexType name="Row">
    - <s:sequence>
    <s:element name="Db_Timeid" type="s:string" nillable="true" />
    <s:element name="Db_Tariff" type="s:string" nillable="true" />
    <s:element name="Grossadds" type="s:double" nillable="true" />
    <s:element name="Cancellations" type="s:double" nillable="true" />
    <s:element name="Netadds" type="s:double" nillable="true" />
    <s:element name="Subs" type="s:double" nillable="true" />
    <s:element name="Churn_P" type="s:double" nillable="true" />
    </s:sequence>
    </s:complexType>
    - <s:complexType name="Table">
    - <s:sequence>
    <s:element name="row" maxOccurs="unbounded" type="s0:Row" />
    </s:sequence>
    </s:complexType>
    - <s:element name="runQueryAsAServiceResponse">
    - <s:complexType>
    - <s:sequence>
    <s:element name="table" type="s0:Table" />
    <s:element name="message" type="s:string" />
    <s:element name="creatorname" type="s:string" />
    <s:element name="creationdate" type="s:dateTime" />
    <s:element name="creationdateformated" type="s:string" />
    <s:element name="description" type="s:string" />
    <s:element name="universe" type="s:string" />
    <s:element name="queryruntime" type="s:int" />
    <s:element name="fetchedrows" type="s:int" />
    </s:sequence>
    </s:complexType>
    </s:element>
    - <s:element name="QaaWSHeader">
    - <s:complexType>
    - <s:sequence>
    <s:element name="sessionID" type="s:string" minOccurs="0" maxOccurs="1" nillable="true" />
    <s:element name="serializedSession" type="s:string" minOccurs="0" maxOccurs="1" nillable="true" />
    </s:sequence>
    </s:complexType>
    </s:element>
    </s:schema>
    </types>
    - <message name="runQueryAsAServiceSoapIn">
    <part name="parameters" element="s0:runQueryAsAService" />
    <part name="request_header" element="s0:QaaWSHeader" />
    </message>
    - <message name="runQueryAsAServiceSoapOut">
    <part name="parameters" element="s0:runQueryAsAServiceResponse" />
    </message>
    - <portType name="QueryAsAServiceSoap">
    - <operation name="runQueryAsAService">
    <documentation>Get Web Service Provider server info</documentation>
    <input message="s0:runQueryAsAServiceSoapIn" />
    <output message="s0:runQueryAsAServiceSoapOut" />
    </operation>
    </portType>
    - <binding name="QueryAsAServiceSoap" type="s0:QueryAsAServiceSoap">
    <soap:binding transport="http://schemas.xmlsoap.org/soap/http" style="document" />
    - <operation name="runQueryAsAService">
    <soap:operation soapAction="DB_SUBS_BUDGET/runQueryAsAService" style="document" />
    - <input>
    - <soap:header message="s0:runQueryAsAServiceSoapIn" part="request_header" use="literal">
    <soap:headerfault message="s0:runQueryAsAServiceSoapIn" part="request_header" use="literal" />
    </soap:header>
    <soap:body use="literal" parts="parameters" />
    </input>
    - <output>
    <soap:body use="literal" />
    </output>
    </operation>
    </binding>
    - <service name="DB_SUBS_BUDGET">
    <documentation />
    - <port name="QueryAsAServiceSoap" binding="s0:QueryAsAServiceSoap">
    <soap:address location="http://<host>:<port>/dswsbobje/qaawsservices/queryasaservice?&cuid=AVhBxL14I2dDjz8yFoznRLY&authType=secEnterprise&locale=en_US&timeout=60&ConvertAnyType=false" />
    </port>
    </service>
    </definitions>

  • Parse a xml file from clob column.

    Dear,
    i have been suffreing a problem about xml.
    i have a table with two columns, one is bfile data type other is clob data type. A xml data is stored into both cloumns
    as clob and bfile. My xml data format is correct.
    when i took xml data from bfile column, then dbms_xmlparser.parseClob successfully parse my xml data.
    Code below:
    =======================================
    dbms_lob.createtemporary(l_clob, cache=>FALSE);
    dbms_lob.loadFromFile(dest_lob => l_clob,
    src_lob => l_bfile,
    amount => dbms_lob.getLength(l_bfile));
    l_parser := dbms_xmlparser.newParser;
    dbms_xmlparser.parseClob(l_parser, l_clob); ========================================
    But when i took xml data form clob clumn directly, then dbms_xmlparser.parseClob parse failed and go to exception.
    Code below:
    ====================================================================
    dbms_lob.createtemporary(l_clob, cache=>FALSE);
    select xml_cfile,xml_bfile                    
    into l_clob ,l_bfile
    from xml_load_in
    l_parser := dbms_xmlparser.newParser;
    dbms_xmlparser.parseClob(l_parser, l_clob); --failed parse    
    ====================================================================
    declare
    l_bfile BFILE;
    l_clob CLOB;
    l_parser dbms_xmlparser.Parser;
    l_doc dbms_xmldom.DOMDocument;
    begin
    dbms_lob.createtemporary(l_clob, cache=>FALSE);
    select xml_cfile,xml_bfile
    into l_clob ,l_bfile
    from xml_load_in
    l_parser := dbms_xmlparser.newParser;
    dbms_xmlparser.parseClob(l_parser, l_clob);
    l_doc := dbms_xmlparser.getDocument(l_parser);
    dbms_lob.freetemporary(l_clob);
    dbms_xmlparser.freeParser(l_parser);
    exception
    dbms_lob.freetemporary(l_clob);
    dbms_xmlparser.freeParser(l_parser);
    dbms_xmldom.freeDocument(l_doc);
    End;
    Example:
    ======--File_name := Outward.xml;
    CREATE OR REPLACE DIRECTORY
    MY_INWARD AS
    'D:\PBM\Inward\';
    CREATE TABLE XML_LOAD_IN
    ( XML_CFILE CLOB,
    XML_BFILE BFILE
    INSERT INTO XML_LOAD_IN ( XML_CFILE, XML_BFILE )
    VALUES (
    '<?xml version="1.0" encoding="UTF-8"?>
    <BACPSInterface>
    <OCE>
    <EHR>
    <StandardLevel>03</StandardLevel>
    <TestFiledIndicator>T</TestFiledIndicator>
    <ImmediateDestRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </ImmediateDestRoutingNumber>
    <ImmediateOriginRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </ImmediateOriginRoutingNumber>
    <FileCreationDate>20090714</FileCreationDate>
    <FileCreationTime>1047</FileCreationTime>
    <ResendIndicator>N</ResendIndicator>
    <ECESettlementDate>20090714</ECESettlementDate>
    <ECESessionTime>1047</ECESessionTime>
    <ECESettlementTime>1047</ECESettlementTime>
    <ECEtype>01</ECEtype>
    <CountryCode>BD</CountryCode>
    </EHR>
    <Collection>
    <CHR>
    <CashLetterBusinessDate>20090714</CashLetterBusinessDate>
    <CashLetterCreationDate>20090714</CashLetterCreationDate>
    <CashLetterCreationTime>1047</CashLetterCreationTime>
    <CashLetterRecordTypeInd>I</CashLetterRecordTypeInd>
    <CashLetterDocTypeIndicator>G</CashLetterDocTypeIndicator>
    <CashLetterID>1</CashLetterID>
    <OriginatorContactName>Bank Asia</OriginatorContactName>
    <OriginatorContactPhoneNumber>XXX</OriginatorContactPhoneNumber>
    </CHR>
    <ForwardBundle>
    <BHR>
    <CollectionTypeIndicator>I</CollectionTypeIndicator>
    <DestRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </DestRoutingNumber>
    <ECEInstitutionRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </ECEInstitutionRoutingNumber>
    <BundleBusinessDate>20090714</BundleBusinessDate>
    <BundleCreationDate>20090714</BundleCreationDate>
    <BundleID>1</BundleID>
    <ReturnLocationRoutingNumber>070127538</ReturnLocationRoutingNumber>
    </BHR>
    <CDR>
    <CDR num="1">
    <ECESettlementDate>20090714</ECESettlementDate>
    <ECESessionTime>1047</ECESessionTime>
    <ECESettlementTime>1047</ECESettlementTime>
    <ECEItemType>N</ECEItemType>
    <IssuingBranchRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </IssuingBranchRoutingNumber>
    <AccountNumber>0000334008221</AccountNumber>
    <ChequeSequenceNumber>1601735</ChequeSequenceNumber>
    <ItemAmount>500</ItemAmount>
    <ECEInstitutionItemSequencNum>0701275380000001</ECEInstitutionItemSequencNum>
    <DocumentationTypeIndicator>I</DocumentationTypeIndicator>
    <ReturnAcceptanceIndicator>6</ReturnAcceptanceIndicator>
    <MICRValidIndicator>1</MICRValidIndicator>
    <BOFDIndicator>Y</BOFDIndicator>
    <ChequeDetailRecAddendumCount>0</ChequeDetailRecAddendumCount>
    <CorrectionIndicator>0</CorrectionIndicator>
    <RepresentmentIndicator>0</RepresentmentIndicator>
    <ArchiveTypeIndicator>F</ArchiveTypeIndicator>
    </CDR>
    <CDR num="2">
    <ECESettlementDate>20090714</ECESettlementDate>
    <ECESessionTime>1047</ECESessionTime>
    <ECESettlementTime>1047</ECESettlementTime>
    <ECEItemType>N</ECEItemType>
    <IssuingBranchRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </IssuingBranchRoutingNumber>
    <AccountNumber>0000345682256</AccountNumber>
    <ChequeSequenceNumber>1234567</ChequeSequenceNumber>
    <ItemAmount>1000</ItemAmount>
    <ECEInstitutionItemSequencNum>0701275380000002</ECEInstitutionItemSequencNum>
    <DocumentationTypeIndicator>I</DocumentationTypeIndicator>
    <ReturnAcceptanceIndicator>6</ReturnAcceptanceIndicator>
    <MICRValidIndicator>1</MICRValidIndicator>
    <BOFDIndicator>Y</BOFDIndicator>
    <ChequeDetailRecAddendumCount>0</ChequeDetailRecAddendumCount>
    <CorrectionIndicator>0</CorrectionIndicator>
    <RepresentmentIndicator>0</RepresentmentIndicator>
    <ArchiveTypeIndicator>F</ArchiveTypeIndicator>
    </CDR>
    </CDR>
    <CDA>
    <CDA num="1">
    <AddendumRecordNumber>1</AddendumRecordNumber>
    <BOFDRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>75</DistrictCode>
    <BranchCode>12</BranchCode>
    <CheckDigit>8</CheckDigit>
    </BOFDRoutingNumber>
    <BOFDBusinessEndorsementDate>20090714</BOFDBusinessEndorsementDate>
    <BOFDDepositAccountNumber>0000334008221</BOFDDepositAccountNumber>
    <BOFDDepositBranch>753</BOFDDepositBranch>
    <PayeeName>XXX</PayeeName>
    <TruncationIndicator>Y</TruncationIndicator>
    <BOFDConversionIndicator>2</BOFDConversionIndicator>
    <BOFDCorrectionIndicator>0</BOFDCorrectionIndicator>
    </CDA>
    <CDA num="2">
    <AddendumRecordNumber>1</AddendumRecordNumber>
    <BOFDRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>75</DistrictCode>
    <BranchCode>12</BranchCode>
    <CheckDigit>8</CheckDigit>
    </BOFDRoutingNumber>
    <BOFDBusinessEndorsementDate>20090714</BOFDBusinessEndorsementDate>
    <BOFDDepositAccountNumber>0000345682256</BOFDDepositAccountNumber>
    <BOFDDepositBranch>753</BOFDDepositBranch>
    <PayeeName>XXX</PayeeName>
    <TruncationIndicator>Y</TruncationIndicator>
    <BOFDConversionIndicator>2</BOFDConversionIndicator>
    <BOFDCorrectionIndicator>0</BOFDCorrectionIndicator>
    </CDA>
    </CDA>
    <CDC>
    <CDC num="1">
    <AddendumCRecordNumber>1</AddendumCRecordNumber>
    <EndorsingBankRountingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </EndorsingBankRountingNumber>
    <EndorsingBankEndorsementDate>20090714</EndorsingBankEndorsementDate>
    <EndorsingBankEndorsementDate>20090714</EndorsingBankEndorsementDate>
    <EndorsingBankItemSequenceNum>0701275380000001</EndorsingBankItemSequenceNum>
    <TruncationIndicator>Y</TruncationIndicator>
    <EndorsingBankConversionInd>2</EndorsingBankConversionInd>
    <EndorsingBankCorrectionInd>0</EndorsingBankCorrectionInd>
    </CDC>
    <CDC num="2">
    <AddendumCRecordNumber>1</AddendumCRecordNumber>
    <EndorsingBankRountingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </EndorsingBankRountingNumber>
    <EndorsingBankEndorsementDate>20090714</EndorsingBankEndorsementDate>
    <EndorsingBankEndorsementDate>20090714</EndorsingBankEndorsementDate>
    <EndorsingBankItemSequenceNum>0701275380000002</EndorsingBankItemSequenceNum>
    <TruncationIndicator>Y</TruncationIndicator>
    <EndorsingBankConversionInd>2</EndorsingBankConversionInd>
    <EndorsingBankCorrectionInd>0</EndorsingBankCorrectionInd>
    </CDC>
    </CDC>
    <IVD>
    <IVD num="1">
    <ImageIndicator>1</ImageIndicator>
    <ImageCreatorRountingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </ImageCreatorRountingNumber>
    <ImageCreatorDate>20090714</ImageCreatorDate>
    <ImageViewFormatIndicator>0</ImageViewFormatIndicator>
    <ImageViewCompressionAlg>0</ImageViewCompressionAlg>
    <ViewSideIndicator>0</ViewSideIndicator>
    <ViewDescriptor>0</ViewDescriptor>
    <DigitalSignatureIndicator>1</DigitalSignatureIndicator>
    <DigitalSignatureMethod>0</DigitalSignatureMethod>
    <SecurityKeySize>12235</SecurityKeySize>
    <ImageRecreateIndicator>0</ImageRecreateIndicator>
    </IVD>
    <IVD num="2">
    <ImageIndicator>1</ImageIndicator>
    <ImageCreatorRountingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </ImageCreatorRountingNumber>
    <ImageCreatorDate>20090714</ImageCreatorDate>
    <ImageViewFormatIndicator>0</ImageViewFormatIndicator>
    <ImageViewCompressionAlg>0</ImageViewCompressionAlg>
    <ViewSideIndicator>0</ViewSideIndicator>
    <ViewDescriptor>0</ViewDescriptor>
    <DigitalSignatureIndicator>1</DigitalSignatureIndicator>
    <DigitalSignatureMethod>0</DigitalSignatureMethod>
    <SecurityKeySize>12235</SecurityKeySize>
    <ImageRecreateIndicator>0</ImageRecreateIndicator>
    </IVD>
    </IVD>
    <IVT>
    <IVT num="1">
    <ECEInstitutionRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </ECEInstitutionRoutingNumber>
    <BundleBusinessDate>20090714</BundleBusinessDate>
    <CycleNumber>0</CycleNumber>
    <ECEInstitutionItemSeqNumber>0701275380000001</ECEInstitutionItemSeqNumber>
    <ClippingOrigin>
    <Origin>0</Origin>
    <CoordinateH1>0000</CoordinateH1>
    <CoordinateH2>0000</CoordinateH2>
    <CoordinateV1>0000</CoordinateV1>
    <CoordinateV2>0000</CoordinateV2>
    </ClippingOrigin>
    <LengthofImageReferenceKey>0</LengthofImageReferenceKey>
    <LengthofDigitalSignature>0</LengthofDigitalSignature>
    <LengthofImageData>1</LengthofImageData>
    <OffsetToImageData>01001000</OffsetToImageData>
    </IVT>
    <IVT num="2">
    <ECEInstitutionRoutingNumber>
    <BankCode>070</BankCode>
    <DistrictCode>12</DistrictCode>
    <BranchCode>75</BranchCode>
    <CheckDigit>8</CheckDigit>
    </ECEInstitutionRoutingNumber>
    <BundleBusinessDate>20090714</BundleBusinessDate>
    <CycleNumber>0</CycleNumber>
    <ECEInstitutionItemSeqNumber>0701275380000002</ECEInstitutionItemSeqNumber>
    <ClippingOrigin>
    <Origin>0</Origin>
    <CoordinateH1>0000</CoordinateH1>
    <CoordinateH2>0000</CoordinateH2>
    <CoordinateV1>0000</CoordinateV1>
    <CoordinateV2>0000</CoordinateV2>
    </ClippingOrigin>
    <LengthofImageReferenceKey>0</LengthofImageReferenceKey>
    <LengthofDigitalSignature>0</LengthofDigitalSignature>
    <LengthofImageData>1</LengthofImageData>
    <OffsetToImageData>01001000</OffsetToImageData>
    </IVT>
    </IVT>
    <IVA>
    <IVA num="1">
    <GlobalImageQuality>0</GlobalImageQuality>
    <GlobalImageUsability>1</GlobalImageUsability>
    <ImagingBankSpecificTest>1</ImagingBankSpecificTest>
    </IVA>
    <IVA num="2">
    <GlobalImageQuality>0</GlobalImageQuality>
    <GlobalImageUsability>1</GlobalImageUsability>
    <ImagingBankSpecificTest>1</ImagingBankSpecificTest>
    </IVA>
    </IVA>
    <BCR>
    <ItemsWithinBundleCount>2</ItemsWithinBundleCount>
    <BundleTotalAmount>1500</BundleTotalAmount>
    <MICRValidTotalAmount>1500</MICRValidTotalAmount>
    </BCR>
    </ForwardBundle>
    <CCR>
    <BundleCount>1</BundleCount>
    <ItemWithinCashLetterCount>2</ItemWithinCashLetterCount>
    <CashLetterTotalAmount>1500</CashLetterTotalAmount>
    <ImagesWithinCashLetterCount>2</ImagesWithinCashLetterCount>
    <ECEInstitutionName>Bank Asia</ECEInstitutionName>
    <SettlementDate>20090714</SettlementDate>
    </CCR>
    </Collection>
    <ECR>
    <CashLetterCount>1</CashLetterCount>
    <TotalRecordCount>2</TotalRecordCount>
    <TotalItemCount>2</TotalItemCount>
    <FileTotalAmount>1500</FileTotalAmount>
    <ImmediateOriginContactName>Bank Asia</ImmediateOriginContactName>
    <ImmediateOriginContactNumber>XXX</ImmediateOriginContactNumber>
    </ECR>
    </OCE>
    </BACPSInterface>'
    , BFILENAME('MY_INWARD','Outward.xml'));
    COMMIT;

    What version of Oracle (4 digits) and what is the error?
    This runs without error on 10.2.0.4 (though you can go directly from a CLOB to a DOMDocument via dbms_xmldom)
    -- Created on 9/14/2009 by JH20567
    declare
      -- Local variables here
      l_clob   CLOB;
      l_parser dbms_xmlparser.Parser;
      l_doc    dbms_xmldom.DOMDocument;
    begin
      -- Test statements here
       l_clob := '<?xml version="1.0" encoding="UTF-8"?>
    <BACPSInterface>
       <OCE>
          <EHR>
             <StandardLevel>03</StandardLevel>
             <TestFiledIndicator>T</TestFiledIndicator>
             <ImmediateDestRoutingNumber>
                <BankCode>070</BankCode>
                <DistrictCode>12</DistrictCode>
                <BranchCode>75</BranchCode>
                <CheckDigit>8</CheckDigit>
             </ImmediateDestRoutingNumber>
             <ImmediateOriginRoutingNumber>
                <BankCode>070</BankCode>
                <DistrictCode>12</DistrictCode>
                <BranchCode>75</BranchCode>
                <CheckDigit>8</CheckDigit>
             </ImmediateOriginRoutingNumber>
             <FileCreationDate>20090714</FileCreationDate>
             <FileCreationTime>1047</FileCreationTime>
             <ResendIndicator>N</ResendIndicator>
             <ECESettlementDate>20090714</ECESettlementDate>
             <ECESessionTime>1047</ECESessionTime>
             <ECESettlementTime>1047</ECESettlementTime>
             <ECEtype>01</ECEtype>
             <CountryCode>BD</CountryCode>
          </EHR>
          <Collection>
             <CHR>
                <CashLetterBusinessDate>20090714</CashLetterBusinessDate>
                <CashLetterCreationDate>20090714</CashLetterCreationDate>
                <CashLetterCreationTime>1047</CashLetterCreationTime>
                <CashLetterRecordTypeInd>I</CashLetterRecordTypeInd>
                <CashLetterDocTypeIndicator>G</CashLetterDocTypeIndicator>
                <CashLetterID>1</CashLetterID>
                <OriginatorContactName>Bank Asia</OriginatorContactName>
                <OriginatorContactPhoneNumber>XXX</OriginatorContactPhoneNumber>
             </CHR>
             <ForwardBundle>
                <BHR>
                   <CollectionTypeIndicator>I</CollectionTypeIndicator>
                   <DestRoutingNumber>
                      <BankCode>070</BankCode>
                      <DistrictCode>12</DistrictCode>
                      <BranchCode>75</BranchCode>
                      <CheckDigit>8</CheckDigit>
                   </DestRoutingNumber>
                   <ECEInstitutionRoutingNumber>
                      <BankCode>070</BankCode>
                      <DistrictCode>12</DistrictCode>
                      <BranchCode>75</BranchCode>
                      <CheckDigit>8</CheckDigit>
                   </ECEInstitutionRoutingNumber>
                   <BundleBusinessDate>20090714</BundleBusinessDate>
                   <BundleCreationDate>20090714</BundleCreationDate>
                   <BundleID>1</BundleID>
                   <ReturnLocationRoutingNumber>070127538</ReturnLocationRoutingNumber>
                </BHR>
                <CDR>
                   <CDR num="1">
                      <ECESettlementDate>20090714</ECESettlementDate>
                      <ECESessionTime>1047</ECESessionTime>
                      <ECESettlementTime>1047</ECESettlementTime>
                      <ECEItemType>N</ECEItemType>
                      <IssuingBranchRoutingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>12</DistrictCode>
                         <BranchCode>75</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </IssuingBranchRoutingNumber>
                      <AccountNumber>0000334008221</AccountNumber>
                      <ChequeSequenceNumber>1601735</ChequeSequenceNumber>
                      <ItemAmount>500</ItemAmount>
                      <ECEInstitutionItemSequencNum>0701275380000001</ECEInstitutionItemSequencNum>
                      <DocumentationTypeIndicator>I</DocumentationTypeIndicator>
                      <ReturnAcceptanceIndicator>6</ReturnAcceptanceIndicator>
                      <MICRValidIndicator>1</MICRValidIndicator>
                      <BOFDIndicator>Y</BOFDIndicator>
                      <ChequeDetailRecAddendumCount>0</ChequeDetailRecAddendumCount>
                      <CorrectionIndicator>0</CorrectionIndicator>
                      <RepresentmentIndicator>0</RepresentmentIndicator>
                      <ArchiveTypeIndicator>F</ArchiveTypeIndicator>
                   </CDR>
                   <CDR num="2">
                      <ECESettlementDate>20090714</ECESettlementDate>
                      <ECESessionTime>1047</ECESessionTime>
                      <ECESettlementTime>1047</ECESettlementTime>
                      <ECEItemType>N</ECEItemType>
                      <IssuingBranchRoutingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>12</DistrictCode>
                         <BranchCode>75</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </IssuingBranchRoutingNumber>
                      <AccountNumber>0000345682256</AccountNumber>
                      <ChequeSequenceNumber>1234567</ChequeSequenceNumber>
                      <ItemAmount>1000</ItemAmount>
                      <ECEInstitutionItemSequencNum>0701275380000002</ECEInstitutionItemSequencNum>
                      <DocumentationTypeIndicator>I</DocumentationTypeIndicator>
                      <ReturnAcceptanceIndicator>6</ReturnAcceptanceIndicator>
                      <MICRValidIndicator>1</MICRValidIndicator>
                      <BOFDIndicator>Y</BOFDIndicator>
                      <ChequeDetailRecAddendumCount>0</ChequeDetailRecAddendumCount>
                      <CorrectionIndicator>0</CorrectionIndicator>
                      <RepresentmentIndicator>0</RepresentmentIndicator>
                      <ArchiveTypeIndicator>F</ArchiveTypeIndicator>
                   </CDR>
                </CDR>
                <CDA>
                   <CDA num="1">
                      <AddendumRecordNumber>1</AddendumRecordNumber>
                      <BOFDRoutingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>75</DistrictCode>
                         <BranchCode>12</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </BOFDRoutingNumber>
                      <BOFDBusinessEndorsementDate>20090714</BOFDBusinessEndorsementDate>
                      <BOFDDepositAccountNumber>0000334008221</BOFDDepositAccountNumber>
                      <BOFDDepositBranch>753</BOFDDepositBranch>
                      <PayeeName>XXX</PayeeName>
                      <TruncationIndicator>Y</TruncationIndicator>
                      <BOFDConversionIndicator>2</BOFDConversionIndicator>
                      <BOFDCorrectionIndicator>0</BOFDCorrectionIndicator>
                   </CDA>
                   <CDA num="2">
                      <AddendumRecordNumber>1</AddendumRecordNumber>
                      <BOFDRoutingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>75</DistrictCode>
                         <BranchCode>12</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </BOFDRoutingNumber>
                      <BOFDBusinessEndorsementDate>20090714</BOFDBusinessEndorsementDate>
                      <BOFDDepositAccountNumber>0000345682256</BOFDDepositAccountNumber>
                      <BOFDDepositBranch>753</BOFDDepositBranch>
                      <PayeeName>XXX</PayeeName>
                      <TruncationIndicator>Y</TruncationIndicator>
                      <BOFDConversionIndicator>2</BOFDConversionIndicator>
                      <BOFDCorrectionIndicator>0</BOFDCorrectionIndicator>
                   </CDA>
                </CDA>
                <CDC>
                   <CDC num="1">
                      <AddendumCRecordNumber>1</AddendumCRecordNumber>
                      <EndorsingBankRountingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>12</DistrictCode>
                         <BranchCode>75</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </EndorsingBankRountingNumber>
                      <EndorsingBankEndorsementDate>20090714</EndorsingBankEndorsementDate>
                      <EndorsingBankEndorsementDate>20090714</EndorsingBankEndorsementDate>
                      <EndorsingBankItemSequenceNum>0701275380000001</EndorsingBankItemSequenceNum>
                      <TruncationIndicator>Y</TruncationIndicator>
                      <EndorsingBankConversionInd>2</EndorsingBankConversionInd>
                      <EndorsingBankCorrectionInd>0</EndorsingBankCorrectionInd>
                   </CDC>
                   <CDC num="2">
                      <AddendumCRecordNumber>1</AddendumCRecordNumber>
                      <EndorsingBankRountingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>12</DistrictCode>
                         <BranchCode>75</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </EndorsingBankRountingNumber>
                      <EndorsingBankEndorsementDate>20090714</EndorsingBankEndorsementDate>
                      <EndorsingBankEndorsementDate>20090714</EndorsingBankEndorsementDate>
                      <EndorsingBankItemSequenceNum>0701275380000002</EndorsingBankItemSequenceNum>
                      <TruncationIndicator>Y</TruncationIndicator>
                      <EndorsingBankConversionInd>2</EndorsingBankConversionInd>
                      <EndorsingBankCorrectionInd>0</EndorsingBankCorrectionInd>
                   </CDC>
                </CDC>
                <IVD>
                   <IVD num="1">
                      <ImageIndicator>1</ImageIndicator>
                      <ImageCreatorRountingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>12</DistrictCode>
                         <BranchCode>75</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </ImageCreatorRountingNumber>
                      <ImageCreatorDate>20090714</ImageCreatorDate>
                      <ImageViewFormatIndicator>0</ImageViewFormatIndicator>
                      <ImageViewCompressionAlg>0</ImageViewCompressionAlg>
                      <ViewSideIndicator>0</ViewSideIndicator>
                      <ViewDescriptor>0</ViewDescriptor>
                      <DigitalSignatureIndicator>1</DigitalSignatureIndicator>
                      <DigitalSignatureMethod>0</DigitalSignatureMethod>
                      <SecurityKeySize>12235</SecurityKeySize>
                      <ImageRecreateIndicator>0</ImageRecreateIndicator>
                   </IVD>
                   <IVD num="2">
                      <ImageIndicator>1</ImageIndicator>
                      <ImageCreatorRountingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>12</DistrictCode>
                         <BranchCode>75</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </ImageCreatorRountingNumber>
                      <ImageCreatorDate>20090714</ImageCreatorDate>
                      <ImageViewFormatIndicator>0</ImageViewFormatIndicator>
                      <ImageViewCompressionAlg>0</ImageViewCompressionAlg>
                      <ViewSideIndicator>0</ViewSideIndicator>
                      <ViewDescriptor>0</ViewDescriptor>
                      <DigitalSignatureIndicator>1</DigitalSignatureIndicator>
                      <DigitalSignatureMethod>0</DigitalSignatureMethod>
                      <SecurityKeySize>12235</SecurityKeySize>
                      <ImageRecreateIndicator>0</ImageRecreateIndicator>
                   </IVD>
                </IVD>
                <IVT>
                   <IVT num="1">
                      <ECEInstitutionRoutingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>12</DistrictCode>
                         <BranchCode>75</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </ECEInstitutionRoutingNumber>
                      <BundleBusinessDate>20090714</BundleBusinessDate>
                      <CycleNumber>0</CycleNumber>
                      <ECEInstitutionItemSeqNumber>0701275380000001</ECEInstitutionItemSeqNumber>
                      <ClippingOrigin>
                         <Origin>0</Origin>
                         <CoordinateH1>0000</CoordinateH1>
                         <CoordinateH2>0000</CoordinateH2>
                         <CoordinateV1>0000</CoordinateV1>
                         <CoordinateV2>0000</CoordinateV2>
                      </ClippingOrigin>
                      <LengthofImageReferenceKey>0</LengthofImageReferenceKey>
                      <LengthofDigitalSignature>0</LengthofDigitalSignature>
                      <LengthofImageData>1</LengthofImageData>
                      <OffsetToImageData>01001000</OffsetToImageData>
                   </IVT>
                   <IVT num="2">
                      <ECEInstitutionRoutingNumber>
                         <BankCode>070</BankCode>
                         <DistrictCode>12</DistrictCode>
                         <BranchCode>75</BranchCode>
                         <CheckDigit>8</CheckDigit>
                      </ECEInstitutionRoutingNumber>
                      <BundleBusinessDate>20090714</BundleBusinessDate>
                      <CycleNumber>0</CycleNumber>
                      <ECEInstitutionItemSeqNumber>0701275380000002</ECEInstitutionItemSeqNumber>
                      <ClippingOrigin>
                         <Origin>0</Origin>
                         <CoordinateH1>0000</CoordinateH1>
                         <CoordinateH2>0000</CoordinateH2>
                         <CoordinateV1>0000</CoordinateV1>
                         <CoordinateV2>0000</CoordinateV2>
                      </ClippingOrigin>
                      <LengthofImageReferenceKey>0</LengthofImageReferenceKey>
                      <LengthofDigitalSignature>0</LengthofDigitalSignature>
                      <LengthofImageData>1</LengthofImageData>
                      <OffsetToImageData>01001000</OffsetToImageData>
                   </IVT>
                </IVT>
                <IVA>
                   <IVA num="1">
                      <GlobalImageQuality>0</GlobalImageQuality>
                      <GlobalImageUsability>1</GlobalImageUsability>
                      <ImagingBankSpecificTest>1</ImagingBankSpecificTest>
                   </IVA>
                   <IVA num="2">
                      <GlobalImageQuality>0</GlobalImageQuality>
                      <GlobalImageUsability>1</GlobalImageUsability>
                      <ImagingBankSpecificTest>1</ImagingBankSpecificTest>
                   </IVA>
                </IVA>
                <BCR>
                   <ItemsWithinBundleCount>2</ItemsWithinBundleCount>
                   <BundleTotalAmount>1500</BundleTotalAmount>
                   <MICRValidTotalAmount>1500</MICRValidTotalAmount>
                </BCR>
             </ForwardBundle>
             <CCR>
                <BundleCount>1</BundleCount>
                <ItemWithinCashLetterCount>2</ItemWithinCashLetterCount>
                <CashLetterTotalAmount>1500</CashLetterTotalAmount>
                <ImagesWithinCashLetterCount>2</ImagesWithinCashLetterCount>
                <ECEInstitutionName>Bank Asia</ECEInstitutionName>
                <SettlementDate>20090714</SettlementDate>
             </CCR>
          </Collection>
          <ECR>
             <CashLetterCount>1</CashLetterCount>
             <TotalRecordCount>2</TotalRecordCount>
             <TotalItemCount>2</TotalItemCount>
             <FileTotalAmount>1500</FileTotalAmount>
                   <ImmediateOriginContactName>Bank Asia</ImmediateOriginContactName>
                   <ImmediateOriginContactNumber>XXX</ImmediateOriginContactNumber>
              </ECR>
         </OCE>
    </BACPSInterface>';
       l_parser := dbms_xmlparser.newParser;
       dbms_xmlparser.parseClob(l_parser, l_clob);
       l_doc := dbms_xmlparser.getDocument(l_parser);
       dbms_lob.freetemporary(l_clob);
       dbms_xmlparser.freeParser(l_parser); 
       dbms_xmldom.freeDocument(l_doc);
    end;

  • Error parsing XML file from a HttpServletRequest using JAXP

    Hi,
    I am trying to generate an XML file from an HttpServletRequest. I am actually using file uploading method in JSP to send the XML file. I think the parser isnt able to correctly identify the XML file from the message body and hence it is giving some strange error messages. Has anyone of u managed to solve this problem ?
    Code snippet:
    //now build an XML document from the requested input stream
    InputStream in = myRequest.getInputStream();
    try {
    myDocRequest = myParser.parse(in);
    } catch (Throwable t) {
    throw new Exception("Could not build document",t);
    Error message is:
    [Fatal Error] :1:1: Content is not allowed in prolog.
    java.lang.Exception: Could not build document
    at XMLUtil.<init>(XMLUtil.java:91)
    at WCS.doPost(WCS.java:44)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:362)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
    at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
    at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
    at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
    at java.lang.Thread.run(Thread.java:534)
    Caused by: org.xml.sax.SAXParseException: Content is not allowed in prolog.
    at org.apache.xerces.parsers.DOMParser.parse(Unknown Source)
    at org.apache.xerces.jaxp.DocumentBuilderImpl.parse(Unknown Source)
    at javax.xml.parsers.DocumentBuilder.parse(Unknown Source)
    at XMLUtil.<init>(XMLUtil.java:89)
    ... 20 more
    Actually if i just print out the message, it gives something like this:
    -----------------------------7d63dc71b06b2
    Content-Disposition: form-data; name="W"; filename="C:\work_projects\Capas.xml"
    Content-Type: text/xml
    <?xml version="1.0" encoding="UTF-8"?>
    <GetCapabilities version="1.0.0" service="wcs">
    <section>/WCS_Capabilities/Capability</section>
    </GetCapabilities>
    -----------------------------7d63dc71b06b2--
    Cheers.

    The ServletInput stream contains this:
    -----------------------------7d63dc71b06b2
    Content-Disposition: form-data; name="W"; filename="C:\work_projects\Capas.xml"
    Content-Type: text/xml
    <?xml version="1.0" encoding="UTF-8"?>
    i.e., its the HTTP File Upload MIME stuff, followed by the XML. You need to wrap around the input stream something that can decode the HTTP MIME stuff and let you get at the XML itself, i.e., something like: com.orielly.servlet.multipart.MultipartParser (Apache has a similar 'file upload servlet).
    Jeremy

  • Upload xml file from aplication server using read dataset, parser error.

    Hi,
    I would like to upload xml file from app. server but parser failed. If I upload this xml file from workstation (using ws_upload) it is correct. For uploading xml file from app. server I use open dataset... read dataset. In loop section I remove '#' char. How do You upload xml file from app server? What Could be incorrect.
    I try to open dataset in binary mode, text mode...
    TYPES: BEGIN OF xml_line,
            data(255) TYPE c,
          END OF xml_line.
    DATA: gt_xml_table TYPE TABLE OF xml_line,
          gs_xml_structure TYPE  xml_line,
          gv_xml_table_size TYPE i.
    OPEN DATASET s FOR INPUT IN BINARY MODE.
      IF sy-subrc <> 0.
        MESSAGE e001(zet) WITH '....'.
      ENDIF.
      DO.
        READ DATASET s INTO gs_xml_structure.
        IF sy-subrc <> 0.
          EXIT.
        ELSE.
         len = STRLEN( gs_xml_structure ).
         len = len - 1.
         check len > 0.
         WRITE gs_xml_structure(len) TO gs_xml_structure.
          APPEND gs_xml_structure TO gt_xml_table.
        ENDIF.
      ENDDO.

    You Can do this too
    parameters: p_file like rlgrap-filename.
    data: subrc like sy-subrc.
      create object me.
      REFRESH t_data.
    *  Open XML File
      CALL METHOD me->CREATE_WITH_FILE
        EXPORTING
          filename = p_file
        RECEIVING
          retcode  = subrc.
    * Saves Data in an itab from XML File.
      CALL METHOD me->get_data
        IMPORTING
          retcode    = subrc
        CHANGING
          dataobject = t_data[].
    Regards,
    Claudio.

  • How to parse XML files from normal FTP Servers?

    I want to parse xml files from a normal FTP Servers , NOT the sap application severs itself. How can i do that?
    I know how to use the SAPFTP getting and putting files ,but I don't want to download and then parse it.
    Who knows how to parse it directly? I Just need to read the contents into a database.
    Thanks.

    I want to parse xml files from a normal FTP Servers , NOT the sap application severs itself. How can i do that?
    I know how to use the SAPFTP getting and putting files ,but I don't want to download and then parse it.
    Who knows how to parse it directly? I Just need to read the contents into a database.
    Thanks.

  • I want to make a schedular which read xml files from a folder ,import in Indesign template then export as a pdf....

    i want to make a schedular probably in Coldfusion or using javascript ,  which read xml files from a folder ,import in Indesign template then export as a pdf....

    I don't think you understand: I want to open Dreamweaver and build a brand new site, then when I am done I want to host the dreamweaver site on the Business Catalyst platform. I dont want to use anything in BC to build the site, I just want to use the hosting platform. I do not want to import a BC site into dreamweaver or anything like that. I just want to use BC the same way I would use godaddy, or uhost or any other hosting provider. Based on your response you said that "of course its possible to build a BC site in Dreamweaver" I dont want to build a BC site, I want to build a Dreamweaver site and host it on the BC platform. Like I said before it doesnt seem like this is possible. As of now we can only build a new site in MUSE and integrate it into BC without using a BC template. Can you understand what I am saying. I DONT WANT TO USE A BC TEMPLATE, I WANT NOTHING TO DO WITH BC WHILE I AM BUILDING THE SITE WITH DREAMWEAVER, JUST LIKE MUSE DOES.

  • Parsing an xml data from a buffer

    I have an XML file loaded into a string buffer in java. I would like to know if I can parser XMl data from that buffer using the SAX parser. I do not want to load the xml using the parser, I would like to load the buffer instead.
    Thanks in advance,
    Sudheer.

    StreamSource ss = new StreamSource(new StringReader(myString));
    transformer.transform(ss, new StreamResult(outputFile));

Maybe you are looking for

  • Problems setting up used ipa2 with ios7 due to Find My My Ipad Feature being left on by previous owner

    Hi!! Im having problems setting up a used ipad 2.with ios7. The previous owner forgot to turn off the find my ipad feature so now its asking me for her itunes username an password. I dont have that info and i lost her phone number

  • The work book does not exist in the document store

    Hi Forum, Has anyone come accross this error "The work book does not exist in the document store" I just changed the description of my Work book in Development and saved. Now it wont open. The error message is "The work book does not exist in the doc

  • 4:3 and 16:9 on same disc OK?

    I'm getting the sense from some posts that the answer may be "no," from the standpoint of end-user TV's being able to switch from 4:3 to 16:9 on the same disc, but wanted to make sure if it either can't be done or is not advisable to combine video cl

  • Problem to activate an append structure

    Hi Guys, I'm trying to activate an append structure for a specific extractor, bu the next error is raised Activity terminated because errors occurred during package checks and then, itis telling me to follow up the the next procedure: Keep note of th

  • Image Capturing for DnD via Robot

    Ladies n Gents I am attempting to enhance the drag and drop functionality of a certain jtable. Most of it works quite nicely, except, when I drag a row with no data; the image of the component physically under the jtable is captured and not of the ro