DOM parser Detecting Closing Element Tag

hi all,
Is it possible to detect the closing element tag for following XML code.
<seq>
<par>
<img...>
<img..>
</par>
<img ...>
</seq>
I want to detect closing </seq> & </par> elements Nodes.
Thanks in advance,
Regards,
-Harshad

No, DOM parsers deal with elements and not "tags". It's much easier to do what you ask with a SAX parser. See Chapter 6 of the tutorial:
http://java.sun.com/webservices/docs/1.1/tutorial/doc/index.html

Similar Messages

  • Dom Parsing and BR tag problem...

    hi all,
    I have a Dom parser which examines an xml file and creates a Jtree from its content... it works fine except that when it meets a </br> tag it creates a new node for it in the tree... is there anyway to get it to consider the two "node" as one...
    example:
    - <p>
    some text 1
    some text 2
    </p>
    should be added in one node as some text 1 some text 2 instead it puts some text 1 in one node and some text 2 in another....
    thanks
    Lila

    oooh sorry i didnt check how the message looked this is the question:
    hi all, I have a Dom parser which examines an xml file and creates a Jtree from its content... it works fine except that when it meets a / BR tag it creates a new node for it in the tree... is there anyway to get it to consider the two "node" as one... example: -
    < p >
    some text 1
    < / BR > <--- THIS NODE IS PROBLEM
    some text 2
    < / p >
    should be added in one node as some text 1 some text 2 instead it puts some text 1 in one node and some text 2 in another....
    thanks
    Lila

  • Context change by DOM parsing Java Mapping in XI

    Hi Team,
    I would like to know that how can I handle Context Change by DOM Parser Java Mapping in XI.?
    Suppose  the source XML structure I have like below:
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:Header xmlns:ns0="urn:bp:xi:hr:edm:test:100">
       <FileName>
          <filesub>
             <subname>a</subname>
             <subname>b</subname>
             <subname>c</subname>
          </filesub>
       </FileName>
       <FileName>
          <filesub>
             <subname>d</subname>
             <subname>e</subname>
             <subname>f</subname>
          </filesub>
       </FileName>
    </ns0:Header>
    Where the field FileName can occur maximum thrice(0...3) but the subname field is (0....unbounded) but in the target source I would like to have as given below:
    <?xml version="1.0" encoding="UTF-8" ?>
    - <MT_Test4 xmlns="urn:bp:xi:hr:edm:test:100">
    - <Header>
      <FileName>a</FileName>
      <FileName1>d</FileName1>
        </Header>
    - <Header>
      <FileName>b</FileName>
      <FileName1>e</FileName1>
       </Header>
    Header>
      <FileName>c</FileName>
      <FileName1>f</FileName1>
       </Header>
    </MT_Test4>
    That means the first value from every context of the source field is forming my first and second value in my target first context.Thensecond value from every context is forming my 1st and 2nd value of my target 2nd context and finally 3rd value of every context is forming my 1st and 2nd value of my target 3rd context.Is this possible to done through DOM parsing or we have to do it by UDF only?

    Hi Atanu,
        In my last post I gave an alogorithm to solve the mapping problem. Here is the complete program for the mapping.
    import java.io.FileInputStream;
    import java.io.FileOutputStream;
    import java.io.InputStream;
    import java.io.OutputStream;
    import java.util.Map;
    import javax.xml.parsers.DocumentBuilder;
    import javax.xml.parsers.DocumentBuilderFactory;
    import javax.xml.transform.Transformer;
    import javax.xml.transform.TransformerFactory;
    import javax.xml.transform.dom.DOMSource;
    import javax.xml.transform.stream.StreamResult;
    import org.w3c.dom.Document;
    import org.w3c.dom.Element;
    import org.w3c.dom.Node;
    import org.w3c.dom.NodeList;
    import com.sap.aii.mapping.api.StreamTransformation;
    import com.sap.aii.mapping.api.StreamTransformationException;
    public class DOMParser1  implements StreamTransformation{
         public void execute(InputStream in, OutputStream out)
                   throws StreamTransformationException {
              try
                   DocumentBuilderFactory factory=DocumentBuilderFactory.newInstance();
                   DocumentBuilder builderel=factory.newDocumentBuilder();
                   /input document in form of XML/
                   Document docIn=builderel.parse(in);
                   /document after parsing/
                   Document docOut=builderel.newDocument();
                   TransformerFactory tf=TransformerFactory.newInstance();
                   Transformer transform=tf.newTransformer();
                   Element root,child,child1=null;
                   Node textChild;
                   NodeList l;
                   int i,n1,j,div,k;
                   String s[];
                   root=docOut.createElement("MT_Test4");
                   root.setAttribute("xmlns","urn:bp:xi:hr:edm:test:100");
                   l=docIn.getElementsByTagName("subname");
                   n1=l.getLength();
                   s=new String[n1];
                   for(i=0;i<n1;++i)
                             s<i>=l.item(i).getFirstChild().getNodeValue();
                   l=docIn.getElementsByTagName("filesub");
                   div=l.getLength();
                   j=n1/div;
                   for(i=0,k=0;i<j;++i)
                        child1=docOut.createElement("Header");
                        root.appendChild(child1);
                        child=docOut.createElement("FileName");
                        textChild=docOut.createTextNode(s[k]);
                        child.appendChild(textChild);
                        child1.appendChild(child);
                        child=docOut.createElement("FileName1");
                        textChild=docOut.createTextNode(s [ k + j ]);
                        child.appendChild(textChild);
                        child1.appendChild(child);
                        ++k;
                   docOut.appendChild(root);
                   transform.transform(new DOMSource(docOut), new StreamResult(out));     
              catch(Exception e)
                   e.printStackTrace();
         public void setParameter(Map arg0) {
         public static void main(String[] args) {
              try{
                   DOMParser1 genFormat=new DOMParser1();
                   FileInputStream in=new FileInputStream("C:/Apps/my dw/sdnq/apps.xml");
                   FileOutputStream out=new FileOutputStream("C:/Apps/my dw/sdnq/tgt1.xml");
                   genFormat.execute(in,out);
              catch(Exception e)
                   e.printStackTrace();
    source ->  apps.xml
    <?xml version="1.0" encoding="UTF-8" ?>
    - <ns0:Header xmlns:ns0="urn:bp:xi:hr:edm:test:100">
    - <FileName>
    - <filesub>
      <subname>a</subname>
      <subname>b</subname>
      <subname>c</subname>
      </filesub>
      </FileName>
    - <FileName>
    - <filesub>
      <subname>d</subname>
      <subname>e</subname>
      <subname>f</subname>
      </filesub>
      </FileName>
      </ns0:Header>
    target structure ->  tgt1.xml
    <?xml version="1.0" encoding="UTF-8" ?>
    - <MT_Test4 xmlns="urn:bp:xi:hr:edm:test:100">
    - <Header>
      <FileName>a</FileName>
      <FileName1>d</FileName1>
      </Header>
    - <Header>
      <FileName>b</FileName>
      <FileName1>e</FileName1>
      </Header>
    - <Header>
      <FileName>c</FileName>
      <FileName1>f</FileName1>
      </Header>
      </MT_Test4>
    Hope this helps
    one more thing  in this line "textChild=docOut.createTextNode(s k + j );"   somehow the the third braces one opening  before k and one closing after j is missing for unknown reasons. Please correct it when you actually run this code.
    regards
    Anupam
    Edited by: anupamsap on Mar 7, 2011 12:47 PM

  • DOM Parsing Exception in translator. Dequeuing is failing

    Hi,
    -> I am working on EDI HIPPA File Protocol.
    -> My b2b configuration is working. I am getting the payload xml in IP_IN_QUEUE.
    But ESB with AQAdaptor is failing giving the below Exception.
    -> ORABPEL-11211 DOM Parsing Exception in translator. DOM parsing exception in inbound XSD translator while parsing InputStream. Check the error stack and fix the cause of the error. Contact oracle support if error is not fixable. at oracle.tip.pc.services.translation.xlators.xsd.XSDTranslator.translateFromNative(XSDTranslator.java:202) at oracle.tip.adapter.aq.database.MessageReader.translateFromNative(MessageReader.java:1179) at oracle.tip.adapter.aq.database.MessageReader.readMessage(MessageReader.java:533) at oracle.tip.adapter.aq.inbound.AQActivationSpecDequeuer.run(AQActivationSpecDequeuer.java:189) at oracle.j2ee.connector.work.WorkWrapper.runTargetWork(WorkWrapper.java:242) at oracle.j2ee.connector.work.WorkWrapper.doWork(WorkWrapper.java:215) at oracle.j2ee.connector.work.WorkWrapper.run(WorkWrapper.java:190) at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:814) at java.lang.Thread.run(Thread.java:595) Caused by: oracle.xml.parser.v2.XMLParseException: Expected name instead of >. at oracle.xml.parser.v2.XMLError.flushErrors1(XMLError.java:320) at oracle.xml.parser.v2.XMLReader.scanNameChars(XMLReader.java:1151) at oracle.xml.parser.v2.XMLReader.scanQName(XMLReader.java:1928) at oracle.xml.parser.v2.NonValidatingParser.parseElement(NonValidatingParser.java:1276) at oracle.xml.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:336) at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:303) at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:291) at oracle.tip.pc.services.translation.xlators.xsd.XSDTranslator.translateFromNative(XSDTranslator.java:197)
    -> I have taken the payload xml from rejectedMessages folder from SOA HOME and written a DOM Parser program
    to parse that file.It is throwing org.xml.sax.SAXParseException.
    -> I validated this xml with xsd I provide both in Oracle B2b config and in ESB using Altova software, it is throwing errors saying the xml is not valid.
    -> So I understood that xml which is gettign generated is not the valid one.
    Could you please tell me if I have to make any changes.
    Thanks
    Praveena

    Hi Dheeraj,
    I did this, I have selected Oracle Integration B2B while generating the xsd, then saved the xsd and then saved ecs.
    I gave these ecs and xsd file in my Oracle B2B configruation for Document protocol page.
    Then also, I parsed the file which is generated.It is failing in parsing.
    I can see that set of empty tags <></> are getting generated before <Segment-SE> tag and after <Loop-2000> as shown below:
    </Loop-2100></Loop-2000>&lt&gt&lt/&gt<Segment-SE><Element-96>
    (I don't why I am able to see symbols for tags when I am editing this message but once I save the message it is not shown in the forum.actually empty tags are getting geneated.)
    I removed these empty tags and parsed it again, then it is parsed successfully.
    Could you please tell me what I need to do for not generating these extra empty tags.
    my xsd looks as below(pastign for this particular part:
    <xsd:element name="Transaction-835">
    <xsd:annotation>
    <xsd:documentation>Health Care Claim Payment/Advice</xsd:documentation>
    <xsd:documentation>This Draft Standard for Trial Use contains the format and establishes the data contents of the Health Care Claim Payment/Advice Transaction Set (835) for use within the context of the Electronic Data Interchange (EDI) environment. This transaction set can be used to make a payment, send an Explanation of Benefits (EOB) remittance advice, or make a payment and send an EOB remittance advice only from a health insurer to a health care provider either directly or via a financial institution.</xsd:documentation>
    </xsd:annotation>
    <xsd:complexType>
    <xsd:sequence>
    <xsd:element ref="Internal-Properties" minOccurs="0"/>
    <xsd:element ref="Segment-ST"/>
    <xsd:element ref="Segment-BPR"/>
    <xsd:element ref="Segment-TRN"/>
    <xsd:element ref="Segment-REF" minOccurs="0"/>
    <xsd:element ref="Segment-DTM" minOccurs="0"/>
    <xsd:choice maxOccurs="2" minOccurs="2">
    <xsd:element ref="Loop-1000A"/>
    <xsd:element ref="Loop-1000B"/>
    </xsd:choice>
    <xsd:element ref="Loop-2000" minOccurs="0" maxOccurs="unbounded"/>
    <xsd:element ref="Segment-SE"/>
    </xsd:sequence>
    <xsd:attribute name="Type" default="Transaction" type="xsd:string"/>
    <xsd:attribute name="XDataVersion" fixed="1.0" type="xsd:string"/>
    <xsd:attribute name="Standard" fixed="HIPAA" type="xsd:string"/>
    <xsd:attribute name="Version" default="V4010X091A1" type="xsd:string"/>
    <xsd:attribute name="GUID" default="" type="xsd:string"/>
    <xsd:attribute name="CreatedBy" type="xsd:string"/>
    <xsd:attribute name="CreatedDate" type="xsd:dateTime"/>
    </xsd:complexType>
    </xsd:element>
    Edited by: Praveena Paruchuru on Mar 10, 2009 6:33 AM
    Edited by: Praveena Paruchuru on Mar 10, 2009 6:49 AM

  • XML element tag problem

    Hi guys,
    I am facing a problem in parseing a XML file when the element is in <element/> tag format. Iam using "javax.xml.parsers.SAXParser" to parse the XML. Basically XML contains many fields that are mandatary in my XSD. my requirement is that if there is a SAXParseException, I should get the name of the element for which the error is comming.
    What I am doing is, I am storing the name of the element in startElement method, which I print it in the catch block of the error. This code is working fine for <element></element> type of tag. But when the element tag is <element/> this. it does not go in the startElement or endElement block. Hence I always get the name element which is previous to the error element.
    How can I get the element name in both form of the element tag. As I have no control over the XML, which is posted on my servlet.

    I'm not sure why you're having a problem - the SAXException tells you where in the input stream the error is, and SAX parsers may report a validation error at any time so long as it is before passing the invalid element to the content handler. So it's legal for the exception to occur immediately after the startDocument, and will not necessarily occur immediately after the callback for the preceding element.
    Eg, if the DTD says you have <!ELEMENT foo (a,b,c,d)> and you have <foo><a/><b/><x/><d/></foo>, then the parser may well report the error before the startElement() call for the foo element, as it is invalid. Such fail-fast parser validation means you can safely update a persistant resource on receipt of the events, rather than having to wait until the element is closed before you are sure it's valid.
    This works fine for <element/> tag. But now there is a problem with <element></element> tag.Post the code you have, show how you are mapping from the line no. in the exception to the source data, and state which parser you are using.
    Pete

  • Oracle XML DOM parser - attribute values are not printing on the screen ??

    Hi Everyone,
    I am just trying to use oracle DOM parser to paerse one of my xml file, java file can be compiled and run agianst a xml file, But I cannot see any attribute values printing on the screen..
    Appreciate if anyone can help, where I have gone wrong please?
    Below is the java file:
    // menna puthe DOMSample eka - duwanawa 19/12/2005
    import java.io.*;
    import java.net.*;
    import org.w3c.dom.*;
    import org.w3c.dom.Node;
    import oracle.xml.parser.v2.*;
    public class DOMSample {  //public class eka ***
    static public void main(String[] argv){  // main method eka ###
    try {
    if (argv.length != 1){
    // Must pass in the name of the XML file...
    System.err.println("Usage: java DOMSample filename");
    System.exit(1);
    // Get an instance of the parser
    DOMParser parser = new DOMParser();
    // Generate a URL from the filename.
    URL url = createURL(argv[0]);
    // Set various parser options: validation on,
    // warnings shown, error stream set to stderr.
    parser.setErrorStream(System.err);
    parser.showWarnings(true);
    // Parse the document.
    parser.parse(url);
    // Obtain the document.
    Document doc = parser.getDocument();
    // Print document elements
    System.out.print("The elements are: ");
    printElements(doc);
    // Print document element attributes
    System.out.println("The attributes of each element are: ");
    printElementAttributes(doc);
    catch (Exception e){
    System.out.println(e.toString());
    } // main method eka ###
    static void printElements(Document doc) {
    NodeList nl = doc.getElementsByTagName("*");
    Node n;
    for (int i=0; i<nl.getLength(); i++){
    n = nl.item(i);
    System.out.print(n.getNodeName() + " ");
    System.out.println();
    static void printElementAttributes(Document doc){
    NodeList nl = doc.getElementsByTagName("*");
    Element e;
    Node n;
    NamedNodeMap nnm;
    String attrname;
    String attrval;
    int i, len;
    len = nl.getLength();
    for (int j=0; j < len; j++){
    e = (Element)nl.item(j);
    System.out.println(e.getTagName() + ":");
    nnm = e.getAttributes();
    if (nnm != null){
    for (i=0; i<nnm.getLength(); i++){
    n = nnm.item(i);
    attrname = n.getNodeName();
    attrval = n.getNodeValue();
    System.out.print(" " + attrname + " = " + attrval);
    System.out.println();
    static URL createURL(String filename) {  // podi 3 Start
    URL url = null;
    try {
    url = new URL(filename);
    } catch (MalformedURLException ex) { /// BBBBBB
    try {
    File f = new File(filename);
    url = f.toURL();
    } catch (MalformedURLException e) {
    System.out.println("Cannot create URL for: " + filename);
    System.exit(0);
    } // BBBBBB
    return url;
    } // podi 3 End
    } //public class eka ***
    // End of program
    output comes as below:
    Isbn:
    Title:
    Price:
    Author:
    Message was edited by:
    chandanal

    Hi Chandanal,
    I edited your code slightly and I was able to get the correct output.
    I changed the following line:
    for (int j=0; j >< len; j++)to:
    for (int j=0; j < len; j++)I have included the complete source below:
    // menna puthe DOMSample eka - duwanawa 19/12/2005
    import java.io.*;
    import java.net.*;
    import org.w3c.dom.*;
    import org.w3c.dom.Node;
    import oracle.xml.parser.v2.*;
    public class DOMSample {
        //public class eka ***
        public static void main(String[] argv) {
            // main method eka ###
            try {
                if (argv.length != 1) {
                    // Must pass in the name of the XML file...
                    System.err.println("Usage: java DOMSample filename");
                    System.exit(1);
                // Get an instance of the parser
                DOMParser parser = new DOMParser();
                // Generate a URL from the filename.
                URL url = createURL(argv[0]);
                // Set various parser options: validation on,
                // warnings shown, error stream set to stderr.
                parser.setErrorStream(System.err);
                parser.showWarnings(true);
                // Parse the document.
                parser.parse(url);
                // Obtain the document.
                Document doc = parser.getDocument();
                // Print document elements
                System.out.print("The elements are: ");
                printElements(doc);
                // Print document element attributes
                System.out.println("The attributes of each element are: ");
                printElementAttributes(doc);
            } catch (Exception e) {
                System.out.println(e.toString());
        // main method eka ###
        static void printElements(Document doc) {
            NodeList nl = doc.getElementsByTagName("*");
            Node n;
            for (int i = 0; i < nl.getLength(); i++) {
                n = nl.item(i);
                System.out.print(n.getNodeName() + " ");
            System.out.println();
        static void printElementAttributes(Document doc) {
            NodeList nl = doc.getElementsByTagName("*");
            Element e;
            Node n;
            NamedNodeMap nnm;
            String attrname;
            String attrval;
            int i, len;
            len = nl.getLength();
            for (int j = 0; j < len; j++) {
                e = (Element)nl.item(j);
                System.out.println(e.getTagName() + ":");
                nnm = e.getAttributes();
                if (nnm != null) {
                    for (i = 0; i < nnm.getLength(); i++) {
                        n = nnm.item(i);
                        attrname = n.getNodeName();
                        attrval = n.getNodeValue();
                        System.out.print(" " + attrname + " = " + attrval);
                System.out.println();
        static URL createURL(String filename) {
            // podi 3 Start
            URL url = null;
            try {
                url = new URL(filename);
            } catch (MalformedURLException ex) {
                /// BBBBBB
                try {
                    File f = new File(filename);
                    url = f.toURL();
                } catch (MalformedURLException e) {
                    System.out.println("Cannot create URL for: " + filename);
                    System.exit(0);
            // BBBBBB
            return url;
        // podi 3 End
    } //public class eka ***-Blaise

  • XML Parsing Error: no element found In BI Publisher

    Hi Gurus,
    I tried to get XML output for a Data Model which was based on SQL queries.
    But I got the following error in Firefox
    XML Parsing Error: no element found
    Location: http://localhost:9704/xmlpserver/servlet/xdo
    Line Number 4, Column 1:
    In IE I got an other error:
    There is no end tag for DATA_SET
    Any ideas?
    Many thanks
    Laszlo

    Hi,
    I use 11g.
    I tried to create element link when I got this error.
    Now I am using groupink.
    Without using bind variable I got result (Cartesian product)
    However if i created and used bind variable I got the same error
    this is a dept data set:
    select     "DEPARTMENTS"."DEPARTMENT_ID" as DEPTNO,
         "DEPARTMENTS"."DEPARTMENT_NAME" as "DEPARTMENT_NAME",
         "DEPARTMENTS"."LOCATION_ID" as "LOCATION_ID",
         "DEPARTMENTS"."MANAGER_ID" as "MANAGER_ID"
    from     "HR"."DEPARTMENTS" "DEPARTMENTS"
    this is the emp data set:
    select     "EMPLOYEES"."COMMISSION_PCT" as "COMMISSION_PCT",
         "EMPLOYEES"."DEPARTMENT_ID" as "DEPARTMENT_ID",
         "EMPLOYEES"."EMAIL" as "EMAIL",
         "EMPLOYEES"."EMPLOYEE_ID" as "EMPLOYEE_ID",
         "EMPLOYEES"."FIRST_NAME" as "FIRST_NAME",
         "EMPLOYEES"."HIRE_DATE" as "HIRE_DATE",
         "EMPLOYEES"."JOB_ID" as "JOB_ID",
         "EMPLOYEES"."LAST_NAME" as "LAST_NAME",
         "EMPLOYEES"."MANAGER_ID" as "MANAGER_ID"
    from     "HR"."EMPLOYEES" "EMPLOYEES"
    WHERE "EMPLOYEES"."DEPARTMENT_ID" =:DEPTNO
    Thanks for any tip!
    Laszlo

  • Error While trying to Get XML element(tag) Values

    We are trying to get XML element (TAG) value from the XML pay load.
    Example.
    Getting XML String from a web service and then converting into XML payload.
    ora:parseEscapedXML(bpws:getVariableData('signOn_Out','signOnReturn'))
    From this XML payload we are trying to get an element (Tag) value.
    We are getting following error
    Error in evaluate <from> expression at line "130". The result is empty for the XPath expression : "/client:TririgaProcessResponse/client:User/client:LastName".
    oracle.xml.parser.v2.XMLElement@118dc2a
    {http://schemas.xmlsoap.org/ws/2003/03/business-process/}selectionFailure" has been thrown.
    - <selectionFailure xmlns="http://schemas.xmlsoap.org/ws/2003/03/business-process/">
    - <part name="summary">
    <summary>
    empty variable/expression result.
    xpath variable/expression expression "/client:TririgaProcessResponse/client:User/client:LastName" is empty at line 130, when attempting reading/copying it.
    Please make sure the variable/expression result "/client:TririgaProcessResponse/client:User/client:LastName" is not empty.
    </summary>
    </part>
    </selectionFailure>
    Here are signOnReturn and XML Payload XSD's
    <schema attributeFormDefault="unqualified"
         elementFormDefault="qualified"
         targetNamespace="http://xmlns.oracle.com/Web1"
         xmlns="http://www.w3.org/2001/XMLSchema">
         <element name="Web1ProcessRequest">
              <complexType>
                   <sequence>
                        <element name="userName" type="string"/>
    <element name="password" type="string"/>
                   </sequence>
              </complexType>
         </element>
         <element name="Web1ProcessResponse">
              <complexType>
                   <sequence>
                        <element name="result" type="string"/>
                   </sequence>
              </complexType>
         </element>
    </schema>
    <?xml version="1.0" encoding="windows-1252" ?>
    <schema attributeFormDefault="unqualified"
         elementFormDefault="qualified"
         targetNamespace="http://xmlns.oracle.com/Web"
         xmlns="http://www.w3.org/2001/XMLSchema">
         <element name="TProcessResponse">
              <complexType>
                   <sequence>
                        <element name="result" type="string"/>
    <element name="User">
    <complexType>
                   <sequence>
                        <element name="Id" type="string"/>
    <element name="CompanyId" type="string"/>
    <element name="SecurityToken" type="string"/>
    <element name="FirstName" type="string"/>
    <element name="LastName" type="string"/>
    </sequence>
    </complexType>
    </element>
                   </sequence>
              </complexType>
         </element>
    </schema>

    I am sure and can see the data in audit trail.
    [2006/12/12 09:17:36]
    Updated variable "signOn_Output"
    - <signOn_Output>
    - <part xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="payload">
    - <WebMethodsProcessResponse xmlns="http://xmlns.oracle.com/WebMethods">
    <Result xmlns="">
    Success
    </Result>
    - <User xmlns="">
    <Id>
    2694069
    </Id>
    <CompanyId>
    208133
    </CompanyId>
    <SecurityToken>
    1165936654605
    </SecurityToken>
    <FirstName>
    Jagan
    </FirstName>
    <LastName>
    Rao
    </LastName>
    </User>
    </WebMethodsProcessResponse>
    </part>
    </signOn_Output>
    Copy details to clipboard
    [2006/12/12 09:17:36]
    Updated variable "tririga"
    - <tririga>
    - <TririgaProcessResponse xmlns="http://xmlns.oracle.com/WebMethods">
    <Result xmlns="">
    Success
    </Result>
    - <User xmlns="">
    <Id>
    2694069
    </Id>
    <CompanyId>
    208133
    </CompanyId>
    <SecurityToken>
    1165936654605
    </SecurityToken>
    <FirstName>
    Jagan
    </FirstName>
    <LastName>
    Rao
    </LastName>
    </User>
    </TririgaProcessResponse>
    </tririga>
    Copy details to clipboard
    [2006/12/12 09:17:36]
    Updated variable "Variable_2"
    - <Variable_2>
    - <part xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="payload">
    - <TririgaProcessResponse xmlns="http://xmlns.oracle.com/WebMethods">
    <Result xmlns="">
    Success
    </Result>
    - <User xmlns="">
    <Id>
    2694069
    </Id>
    <CompanyId>
    208133
    </CompanyId>
    <SecurityToken>
    1165936654605
    </SecurityToken>
    <FirstName>
    Jagan
    </FirstName>
    <LastName>
    Rao
    </LastName>
    </User>
    </TririgaProcessResponse>
    </part>
    </Variable_2>
    Copy details to clipboard
    [2006/12/12 09:17:36]
    Error in evaluate <from> expression at line "130". The result is empty for the XPath expression : "/client:TririgaProcessResponse/client:User/client:LastName".
    oracle.xml.parser.v2.XMLElement@1c8768e
    Copy details to clipboard
    [2006/12/12 09:17:36]
    "{http://schemas.xmlsoap.org/ws/2003/03/business-process/}selectionFailure" has been thrown.
    - <selectionFailure xmlns="http://schemas.xmlsoap.org/ws/2003/03/business-process/">
    - <part name="summary">
    <summary>
    empty variable/expression result.
    xpath variable/expression expression "/client:TririgaProcessResponse/client:User/client:LastName" is empty at line 130, when attempting reading/copying it.
    Please make sure the variable/expression result "/client:TririgaProcessResponse/client:User/client:LastName" is not empty.
    </summary>
    </part>
    </selectionFailure>
    Copy details to clipboard

  • Parsing an xml file using xerces DOM  parser

    Hi
    I want to parse a simple xml file using DOM parser.
    The file is
    <Item>
         <SubItem>
              <title>SubItem0</title>
              <attr1>0</attr1>
              <attr2>0</attr2>
              <attr3>0</attr3>
         </SubItem>
         <SubItem>
              <title>SubItem1</title>
              <attr1>1</attr1>
              <attr2>0</attr2>
              <attr3>0</attr3>
         </SubItem>
         <SubItem>
              <title>SubItem2</title>
              <attr1>1</attr1>
              <attr2>1</attr2>
              <attr3>0</attr3>
              <SubItem>
                   <title>SubItem20</title>
                   <attr1>2</attr1>
                   <attr2>1</attr2>
                   <attr3>0</attr3>
              </SubItem>
              <SubItem>
                   <title>SubItem21</title>
                   <attr1>1</attr1>
                   <attr2>1</attr2>
                   <attr3>0</attr3>
              </SubItem>
         </SubItem>
    </Item>
    I just want to parse this file and want to store the values in desired datastructures,
    I am trying using DOM parser, since it gives a tree structure, which is ok in this case.
    public void init()
              InputReader ir     =new InputReader("Habsys");
              Document      doc     =ir.read("Habitat");
              System.out.println(doc);
              traverse(doc);
    private void traverse(Document idoc)
              NodeList lchildren=idoc.getElementsByTagName("SubItem");
              for(int i=0;i<lchildren.getLength();i++)
                   String lgstr=lchildren.item(i).getNodeName();
                   if(lgstr.equals("SubItem"))
                        traverse(lchildren.item(i));
    private void traverse (Node node) {
    int type = node.getNodeType();
    if (type == Node.ELEMENT_NODE)
    System.out.println ("Name :"+node.getNodeName());
    if(!node.hasChildNodes())
    System.out.println ("Value :"+node.getNodeValue());
    NodeList children = node.getChildNodes();
    if (children != null) {
    for (int i=0; i< children.getLength(); i++)
    traverse (children.item(i));
    But I am not getting required results, a lot of values I am getting as null
    Could anybody tell me how to retrieve the data from the xml file, I simply want to read data and store it in data structures. For eg, for tag Subitem with title as ' SubItem1' has attr1 as '1', attr2 as'0' and attr3 as '0'.
    Thanks
    Gaurav

    Check This Sample Code....
    public void amethod(){
    DocumentBuilderFactory dbf = null;
    DocumentBuilder docBuilder = null;
    Document doc = null;
    try{
         dbf = DocumentBuilderFactory.newInstance();
         db = dbf.newDocumentBuilder();
         doc = db.parse(New File("path/to/your/file"));
         Node root = doc.getDocumentElement();
         System.out.println("Root Node = " + root.getNodeName());
         readNode(root);
    }catch(FactoryConfigurationError fce){ fce.printStackTrace();
    }catch(ParserConfigurationException pce){  pce.printStackTrace();
    }catch(IOException ioe){  ioe.printStackTrace();
    }catch(SAXException saxe){  saxe.printStackTrace();
    private void readNode(Node node) {
    System.out.println("Current Node = " + node.getNodeName());
    readAttributes(node);
    readChildren(node);
    private void readAttributes(Node node) {
    if (!node.hasAttributes())
         return;
    System.out.println("Attributes:");
    NamedNodeMap attrNodes = node.getAttributes();
    for (int i=0; i<attrNodes.getLength(); i++) {
    Attr attr = (Attr)attrNodes.item(i);
    System.out.println(attr.getNodeName() + " => " + attr.getNodeValue());
    private void readChildren(Node node) {
    if (!node.hasChildNodes())
         return;
    System.out.println("Value/s:");
    NodeList childNodes = node.getChildNodes();
    for (int i=0; i<childNodes.getLength(); i++) {
    Node child = (Node)childNodes.item(i);
    if (child.getNodeType() == Node.ELEMENT_NODE) {
    readNode(child);
    continue;
    if (child.getNodeType() == Node.TEXT_NODE) {
    if (child.getNodeValue()!=null)
    System.out.println(child.getNodeValue());

  • Integration between B2B and ESB error (DOM Parsing Exception in translator)

    Hello,
    We have configured a circuit that has the objective of sending a message to B2B and then the ESB dequeues that message from the IP_IN_QUEUE.
    The problem is that for some reason, the ESB cannot read message using the AQ Adapter object.
    The error is the following:
    DOM Parsing Exception in translator. DOM parsing exception in inbound XSD translator while parsing InputStream. Check the error stack and fix the cause of the error. Contact oracle support if error is not fixable.
    The trace is the following:
    ORABPEL-11211 DOM Parsing Exception in translator. DOM parsing exception in inbound XSD translator while parsing InputStream. Check the error stack and fix the cause of the error. Contact oracle support if error is not fixable. at oracle.tip.pc.services.translation.xlators.xsd.XSDTranslator.translateFromNative(XSDTranslator.java:139) at oracle.tip.adapter.aq.database.MessageReader.translateFromNative(MessageReader.java:1179) at oracle.tip.adapter.aq.database.MessageReader.readMessage(MessageReader.java:533) at oracle.tip.adapter.aq.inbound.AQActivationSpecDequeuer.run(AQActivationSpecDequeuer.java:189) at oracle.j2ee.connector.work.WorkWrapper.runTargetWork(WorkWrapper.java:242) at oracle.j2ee.connector.work.WorkWrapper.doWork(WorkWrapper.java:215) at oracle.j2ee.connector.work.WorkWrapper.run(WorkWrapper.java:190) at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:819) at java.lang.Thread.run(Thread.java:595) Caused by: oracle.xml.parser.v2.XMLParseException: '=' missing in attribute. at oracle.xml.parser.v2.XMLError.flushErrors1(XMLError.java:320) at oracle.xml.parser.v2.NonValidatingParser.parseAttrValue(NonValidatingParser.java:1609) at oracle.xml.parser.v2.NonValidatingParser.parseAttr(NonValidatingParser.java:1514) at oracle.xml.parser.v2.NonValidatingParser.parseAttributes(NonValidatingParser.java:1447) at oracle.xml.parser.v2.NonValidatingParser.parseElement(NonValidatingParser.java:1286) at oracle.xml.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:336) at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:303) at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:291) at oracle.tip.pc.services.translation.xlators.xsd.XSDTranslator.translateFromNative(XSDTranslator.java:134) ... 8 more
    The Payload is the following:
    <?xml version="1.0" ?><OMG_O19 xmlns="urn:oracle:integration:b2b:C023D5B231EF45519AA3D9929B4990E1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" XDataVersion="2.0" Standard="HL7" Version="2.4" CreatedDate="2007-07-17T17:10:43" CreatedBy="ECXEngine_837" GUID="{D16D28B9-3821-4BCC-B4D9-0D92F8611BB5}"><Internal-Properties><Data-Structure Name="Message"><Lookup Name="MessageSendingApp">ALERT</Lookup><Lookup Name="MessageSendingAppUniversalID"></Lookup><Lookup Name="MessageSendingAppUniversalIDType"></Lookup><Lookup Name="MessageSendingFacility">CHVNG</Lookup><Lookup Name="MessageSendingFacilityUniversalID"></Lookup><Lookup Name="MessageSendingFacilityUniversalIDType"></Lookup><Lookup Name="MessageReceivingApp">RADIO</Lookup><Lookup Name="MessageReceivingAppUniversalID"></Lookup><Lookup Name="MessageReceivingAppUniversalIDType"></Lookup><Lookup Name="MessageReceivingFacility">CHVNG</Lookup><Lookup Name="MessageReceivingFacilityUniversalID"></Lookup><Lookup Name="MessageReceivingFacilityUniversalIDType"></Lookup><Lookup Name="MessageCode">OMG</Lookup><Lookup Name="TriggerEvent">O19</Lookup><Lookup Name="MessageStructure">OMG_O19</Lookup><Lookup Name="MessageVersion">2.4</Lookup><Lookup Name="InternatCodeID"></Lookup><Lookup Name="InternatCodeText"></Lookup><Lookup Name="InternatCodeSystem"></Lookup><Lookup Name="InternatCodeAlternateID"></Lookup><Lookup Name="InternatCodeAlternateText"></Lookup><Lookup Name="InternatCodeAlternateSystem"></Lookup><Lookup Name="InternationalVersionID"></Lookup><Lookup Name="InternationalVersionIDText"></Lookup><Lookup Name="InternationalVersionIDSystem"></Lookup><Lookup Name="InternationalVersionIDAlternateID"></Lookup><Lookup Name="InternationalVersionIDAlternateText"></Lookup><Lookup Name="InternationalVersionIDAlternateSystem"></Lookup><Lookup Name="Standard">HL7</Lookup><Property Name="MessageEncodingCharacters">^~\&amp;</Property><Property Name="MessageSendingApp">ALERT</Property><Property Name="MessageSendingAppUniversalID"></Property><Property Name="MessageSendingAppUniversalIDType"></Property><Property Name="MessageSendingFacility">CHVNG</Property><Property Name="MessageSendingFacilityUniversalID"></Property><Property Name="MessageSendingFacilityUniversalIDType"></Property><Property Name="MessageReceivingApp">RADIO</Property><Property Name="MessageReceivingAppUniversalID"></Property><Property Name="MessageReceivingAppUniversalIDType"></Property><Property Name="MessageReceivingFacility">CHVNG</Property><Property Name="MessageReceivingFacilityUniversalID"></Property><Property Name="MessageReceivingFacilityUniversalIDType"></Property><Property Name="MessageDate">20070705161247+0000</Property><Property Name="MessageDateTimePrecision"></Property><Property Name="MessageSecurity"></Property><Property Name="MessageCode">OMG</Property><Property Name="TriggerEvent">O19</Property><Property Name="MessageStructure">OMG_O19</Property><Property Name="MessageControlID">1709</Property><Property Name="ProcessingID">P</Property><Property Name="ProcessingMode"></Property><Property Name="MessageVersion">2.4</Property><Property Name="InternatCodeID"></Property><Property Name="InternatCodeText"></Property><Property Name="InternatCodeSystem"></Property><Property Name="InternatCodeAlternateID"></Property><Property Name="InternatCodeAlternateText"></Property><Property Name="InternatCodeAlternateSystem"></Property><Property Name="InternationalVersionID"></Property><Property Name="InternationalVersionIDText"></Property><Property Name="InternationalVersionIDSystem"></Property><Property Name="InternationalVersionIDAlternateID"></Property><Property Name="InternationalVersionIDAlternateText"></Property><Property Name="InternationalVersionIDAlternateSystem"></Property><Property Name="SequenceNumber"></Property><Property Name="ContinuationPointer"></Property><Property Name="AcceptAckType"></Property><Property Name="AppAckType"></Property><Property Name="CountryCode"></Property><Property Name="CharacterSet"></Property><Property Name="LanguageID"></Property><Property Name="LanguageText"></Property><Property Name="LanguageSystem"></Property><Property Name="LanguageAlternateID"></Property><Property Name="LanguageAlternateText"></Property><Property Name="LanguageAlternateSystem"></Property><Property Name="AlternateCharacterSetSchema"></Property><Property Name="ConformanceStatementID"></Property><Property Name="MessageProfileNamespaceID"></Property><Property Name="MessageProfileUniversalID"></Property><Property Name="MessageProfileUniversalIDType"></Property><Property Name="DecimalSeparator"></Property><Property Name="ElementDelimiter">0x7c</Property><Property Name="ReleaseCharacter">0x5c</Property><Property Name="RepeatingSeparator">0x7e</Property><Property Name="SegmentDelimiter">0xd</Property><Property Name="SubcomponentDelimiter">0x26</Property><Property Name="SubelementDelimiter">0x5e</Property></Data-Structure></Internal-Properties><MSH><MSH.1>|</MSH.1><MSH.2>^~\&amp;</MSH.2><MSH.3><HD.1>ALERT</HD.1></MSH.3><MSH.4><HD.1>CHVNG</HD.1></MSH.4><MSH.5><HD.1>RADIO</HD.1></MSH.5><MSH.6><HD.1>CHVNG</HD.1></MSH.6><MSH.7><TS.1>20070705161247+0000</TS.1></MSH.7><MSH.8 xsi:nil="true"></MSH.8><MSH.9><MSG.1>OMG</MSG.1><MSG.2>O19</MSG.2><MSG.3>OMG_O19</MSG.3></MSH.9><MSH.10>1709</MSH.10><MSH.11><PT.1>P</PT.1></MSH.11><MSH.12><VID.1>2.4</VID.1></MSH.12><MSH.13 xsi:nil="true"></MSH.13></MSH><Extra-
    PID><Extra-
    PID.1 xsi:nil="true"></Extra-
    PID.1><Extra-
    PID.2 xsi:nil="true"></Extra-
    PID.2><Extra-
    PID.3><Extra-
    PID.3.1>390971</Extra-
    PID.3.1><Extra-
    PID.3.2 xsi:nil="true"></Extra-
    PID.3.2><Extra-
    PID.3.3 xsi:nil="true"></Extra-
    PID.3.3><Extra-
    PID.3.4>CHVNG</Extra-
    PID.3.4><Extra-
    PID.3.5>NS</Extra-
    PID.3.5></Extra-
    PID.3><Extra-
    PID.4 xsi:nil="true"></Extra-
    PID.4><Extra-
    PID.5><Extra-
    PID.5.1>Santos</Extra-
    PID.5.1><Extra-
    PID.5.2>Paula</Extra-
    PID.5.2><Extra-
    PID.5.3>Cristina Silva Lopes</Extra-
    PID.5.3></Extra-
    PID.5><Extra-
    PID.6 xsi:nil="true"></Extra-
    PID.6><Extra-
    PID.7>19720117000000+0000</Extra-
    PID.7><Extra-
    PID.8 xsi:nil="true"></Extra-
    PID.8><Extra-
    PID.9 xsi:nil="true"></Extra-
    PID.9><Extra-
    PID.10 xsi:nil="true"></Extra-
    PID.10><Extra-
    PID.11><Extra-
    PID.11.1>R Bernardino Costa 358 Bl D Hab 04</Extra-
    PID.11.1><Extra-
    PID.11.2 xsi:nil="true"></Extra-
    PID.11.2><Extra-
    PID.11.3>Valadares</Extra-
    PID.11.3><Extra-
    PID.11.4 xsi:nil="true"></Extra-
    PID.11.4><Extra-
    PID.11.5>4405</Extra-
    PID.11.5></Extra-
    PID.11><Extra-
    PID.12 xsi:nil="true"></Extra-
    PID.12><Extra-
    PID.13 xsi:nil="true"></Extra-
    PID.13><Extra-
    PID.14 xsi:nil="true"></Extra-
    PID.14><Extra-
    PID.15 xsi:nil="true"></Extra-
    PID.15><Extra-
    PID.16 xsi:nil="true"></Extra-
    PID.16><Extra-
    PID.17 xsi:nil="true"></Extra-
    PID.17><Extra-
    PID.18>7011588</Extra-
    PID.18><Extra-
    PID.19 xsi:nil="true"></Extra-
    PID.19></Extra-
    PID><Extra-
    PV1><Extra-
    PV1.1 xsi:nil="true"></Extra-
    PV1.1><Extra-
    PV1.2>URG</Extra-
    PV1.2><Extra-
    PV1.3><Extra-
    PV1.3.1>1</Extra-
    PV1.3.1><Extra-
    PV1.3.2 xsi:nil="true"></Extra-
    PV1.3.2><Extra-
    PV1.3.3 xsi:nil="true"></Extra-
    PV1.3.3><Extra-
    PV1.3.4>CHVNG</Extra-
    PV1.3.4></Extra-
    PV1.3><Extra-
    PV1.4 xsi:nil="true"></Extra-
    PV1.4><Extra-
    PV1.5 xsi:nil="true"></Extra-
    PV1.5><Extra-
    PV1.6 xsi:nil="true"></Extra-
    PV1.6><Extra-
    PV1.7 xsi:nil="true"></Extra-
    PV1.7><Extra-
    PV1.8 xsi:nil="true"></Extra-
    PV1.8><Extra-
    PV1.9 xsi:nil="true"></Extra-
    PV1.9><Extra-
    PV1.10 xsi:nil="true"></Extra-
    PV1.10><Extra-
    PV1.11 xsi:nil="true"></Extra-
    PV1.11><Extra-
    PV1.12 xsi:nil="true"></Extra-
    PV1.12><Extra-
    PV1.13 xsi:nil="true"></Extra-
    PV1.13><Extra-
    PV1.14 xsi:nil="true"></Extra-
    PV1.14><Extra-
    PV1.15 xsi:nil="true"></Extra-
    PV1.15><Extra-
    PV1.16 xsi:nil="true"></Extra-
    PV1.16><Extra-
    PV1.17 xsi:nil="true"></Extra-
    PV1.17><Extra-
    PV1.18>URG</Extra-
    PV1.18><Extra-
    PV1.19><Extra-
    PV1.19.1>7088430</Extra-
    PV1.19.1><Extra-
    PV1.19.2 xsi:nil="true"></Extra-
    PV1.19.2><Extra-
    PV1.19.3 xsi:nil="true"></Extra-
    PV1.19.3><Extra-
    PV1.19.4>SONHO</Extra-
    PV1.19.4></Extra-
    PV1.19><Extra-
    PV1.20 xsi:nil="true"></Extra-
    PV1.20><Extra-
    PV1.21 xsi:nil="true"></Extra-
    PV1.21><Extra-
    PV1.22 xsi:nil="true"></Extra-
    PV1.22><Extra-
    PV1.23 xsi:nil="true"></Extra-
    PV1.23><Extra-
    PV1.24 xsi:nil="true"></Extra-
    PV1.24><Extra-
    PV1.25 xsi:nil="true"></Extra-
    PV1.25><Extra-
    PV1.26 xsi:nil="true"></Extra-
    PV1.26><Extra-
    PV1.27 xsi:nil="true"></Extra-
    PV1.27><Extra-
    PV1.28 xsi:nil="true"></Extra-
    PV1.28><Extra-
    PV1.29 xsi:nil="true"></Extra-
    PV1.29><Extra-
    PV1.30 xsi:nil="true"></Extra-
    PV1.30><Extra-
    PV1.31 xsi:nil="true"></Extra-
    PV1.31><Extra-
    PV1.32 xsi:nil="true"></Extra-
    PV1.32><Extra-
    PV1.33 xsi:nil="true"></Extra-
    PV1.33><Extra-
    PV1.34 xsi:nil="true"></Extra-
    PV1.34><Extra-
    PV1.35 xsi:nil="true"></Extra-
    PV1.35><Extra-
    PV1.36 xsi:nil="true"></Extra-
    PV1.36><Extra-
    PV1.37 xsi:nil="true"></Extra-
    PV1.37><Extra-
    PV1.38 xsi:nil="true"></Extra-
    PV1.38><Extra-
    PV1.39 xsi:nil="true"></Extra-
    PV1.39><Extra-
    PV1.40 xsi:nil="true"></Extra-
    PV1.40><Extra-
    PV1.41 xsi:nil="true"></Extra-
    PV1.41><Extra-
    PV1.42 xsi:nil="true"></Extra-
    PV1.42><Extra-
    PV1.43 xsi:nil="true"></Extra-
    PV1.43><Extra-
    PV1.44>20070705154838+0000</Extra-
    PV1.44><Extra-
    PV1.45 xsi:nil="true"></Extra-
    PV1.45><Extra-
    PV1.46 xsi:nil="true"></Extra-
    PV1.46><Extra-
    PV1.47 xsi:nil="true"></Extra-
    PV1.47><Extra-
    PV1.48 xsi:nil="true"></Extra-
    PV1.48><Extra-
    PV1.49 xsi:nil="true"></Extra-
    PV1.49><Extra-
    PV1.50 xsi:nil="true"></Extra-
    PV1.50><Extra-
    PV1.51>V</Extra-
    PV1.51><Extra-
    PV1.52 xsi:nil="true"></Extra-
    PV1.52></Extra-
    PV1><Extra-
    ORC><Extra-
    ORC.1>NW</Extra-
    ORC.1><Extra-
    ORC.2><Extra-
    ORC.2.1>19013</Extra-
    ORC.2.1><Extra-
    ORC.2.2>ALERT</Extra-
    ORC.2.2></Extra-
    ORC.2><Extra-
    ORC.3 xsi:nil="true"></Extra-
    ORC.3><Extra-
    ORC.4 xsi:nil="true"></Extra-
    ORC.4><Extra-
    ORC.5>NW</Extra-
    ORC.5><Extra-
    ORC.6 xsi:nil="true"></Extra-
    ORC.6><Extra-
    ORC.7 xsi:nil="true"></Extra-
    ORC.7><Extra-
    ORC.8 xsi:nil="true"></Extra-
    ORC.8><Extra-
    ORC.9 xsi:nil="true"></Extra-
    ORC.9><Extra-
    ORC.10 xsi:nil="true"></Extra-
    ORC.10><Extra-
    ORC.11 xsi:nil="true"></Extra-
    ORC.11><Extra-
    ORC.12><Extra-
    ORC.12.1>4292</Extra-
    ORC.12.1><Extra-
    ORC.12.2>Martinez</Extra-
    ORC.12.2><Extra-
    ORC.12.3>Cristina</Extra-
    ORC.12.3></Extra-
    ORC.12><Extra-
    ORC.13 xsi:nil="true"></Extra-
    ORC.13></Extra-
    ORC><Extra-
    OBR><Extra-
    OBR.1>1</Extra-
    OBR.1><Extra-
    OBR.2><Extra-
    OBR.2.1>19013</Extra-
    OBR.2.1><Extra-
    OBR.2.2>ALERT</Extra-
    OBR.2.2></Extra-
    OBR.2><Extra-
    OBR.3 xsi:nil="true"></Extra-
    OBR.3><Extra-
    OBR.4><Extra-
    OBR.4.1>10781</Extra-
    OBR.4.1><Extra-
    OBR.4.2>M<escape V="XE3"/>o direita, duas incid<escape V="XEA"/>ncias</Extra-
    OBR.4.2><Extra-
    OBR.4.3>CHVNG</Extra-
    OBR.4.3></Extra-
    OBR.4><Extra-
    OBR.5 xsi:nil="true"></Extra-
    OBR.5><Extra-
    OBR.6 xsi:nil="true"></Extra-
    OBR.6><Extra-
    OBR.7 xsi:nil="true"></Extra-
    OBR.7><Extra-
    OBR.8 xsi:nil="true"></Extra-
    OBR.8><Extra-
    OBR.9 xsi:nil="true"></Extra-
    OBR.9><Extra-
    OBR.10 xsi:nil="true"></Extra-
    OBR.10><Extra-
    OBR.11 xsi:nil="true"></Extra-
    OBR.11><Extra-
    OBR.12 xsi:nil="true"></Extra-
    OBR.12><Extra-
    OBR.13 xsi:nil="true"></Extra-
    OBR.13><Extra-
    OBR.14 xsi:nil="true"></Extra-
    OBR.14><Extra-
    OBR.15 xsi:nil="true"></Extra-
    OBR.15><Extra-
    OBR.16><Extra-
    OBR.16.1>4292</Extra-
    OBR.16.1><Extra-
    OBR.16.2>Martinez</Extra-
    OBR.16.2><Extra-
    OBR.16.3>Cristina</Extra-
    OBR.16.3></Extra-
    OBR.16><Extra-
    OBR.17 xsi:nil="true"></Extra-
    OBR.17><Extra-
    OBR.18 xsi:nil="true"></Extra-
    OBR.18><Extra-
    OBR.19 xsi:nil="true"></Extra-
    OBR.19><Extra-
    OBR.20 xsi:nil="true"></Extra-
    OBR.20><Extra-
    OBR.21 xsi:nil="true"></Extra-
    OBR.21><Extra-
    OBR.22 xsi:nil="true"></Extra-
    OBR.22><Extra-
    OBR.23 xsi:nil="true"></Extra-
    OBR.23><Extra-
    OBR.24 xsi:nil="true"></Extra-
    OBR.24><Extra-
    OBR.25 xsi:nil="true"></Extra-
    OBR.25><Extra-
    OBR.26 xsi:nil="true"></Extra-
    OBR.26><Extra-
    OBR.27><Extra-
    OBR.27.1 xsi:nil="true"></Extra-
    OBR.27.1><Extra-
    OBR.27.2 xsi:nil="true"></Extra-
    OBR.27.2><Extra-
    OBR.27.3 xsi:nil="true"></Extra-
    OBR.27.3><Extra-
    OBR.27.4>20070705161237+0000</Extra-
    OBR.27.4></Extra-
    OBR.27><Extra-
    OBR.28 xsi:nil="true"></Extra-
    OBR.28></Extra-
    OBR><Extra-
    NTE><Extra-
    NTE.1>1</Extra-
    NTE.1><Extra-
    NTE.2 xsi:nil="true"></Extra-
    NTE.2></Extra-
    NTE><Extra-
    DG1><Extra-
    DG1.1>1</Extra-
    DG1.1><Extra-
    DG1.2 xsi:nil="true"></Extra-
    DG1.2><Extra-
    DG1.3><Extra-
    DG1.3.1>9233</Extra-
    DG1.3.1><Extra-
    DG1.3.2>Contusao De Dedo Da Mao</Extra-
    DG1.3.2><Extra-
    DG1.3.3>ICD9</Extra-
    DG1.3.3></Extra-
    DG1.3><Extra-
    DG1.4 xsi:nil="true"></Extra-
    DG1.4><Extra-
    DG1.5 xsi:nil="true"></Extra-
    DG1.5><Extra-
    DG1.6>D</Extra-
    DG1.6></Extra-
    DG1></OMG_O19>
    I think that the problem should be because of the "Extra" (eg. <Extra-
    PID.1 xsi:nil="true">) word that B2B puts in every tag.
    The strange thing is that, this already worked until two days ago....
    What could it be?
    Thanks for your help.
    Best Regards,
    Nuno Fernandes

    Hello,
    We have configured a circuit that has the objective of sending a message to B2B and then the ESB dequeues that message from the IP_IN_QUEUE.
    The problem is that for some reason, the ESB cannot read message using the AQ Adapter object.
    The error is the following:
    DOM Parsing Exception in translator. DOM parsing exception in inbound XSD translator while parsing InputStream. Check the error stack and fix the cause of the error. Contact oracle support if error is not fixable.
    The trace is the following:
    ORABPEL-11211 DOM Parsing Exception in translator. DOM parsing exception in inbound XSD translator while parsing InputStream. Check the error stack and fix the cause of the error. Contact oracle support if error is not fixable. at oracle.tip.pc.services.translation.xlators.xsd.XSDTranslator.translateFromNative(XSDTranslator.java:139) at oracle.tip.adapter.aq.database.MessageReader.translateFromNative(MessageReader.java:1179) at oracle.tip.adapter.aq.database.MessageReader.readMessage(MessageReader.java:533) at oracle.tip.adapter.aq.inbound.AQActivationSpecDequeuer.run(AQActivationSpecDequeuer.java:189) at oracle.j2ee.connector.work.WorkWrapper.runTargetWork(WorkWrapper.java:242) at oracle.j2ee.connector.work.WorkWrapper.doWork(WorkWrapper.java:215) at oracle.j2ee.connector.work.WorkWrapper.run(WorkWrapper.java:190) at EDU.oswego.cs.dl.util.concurrent.PooledExecutor$Worker.run(PooledExecutor.java:819) at java.lang.Thread.run(Thread.java:595) Caused by: oracle.xml.parser.v2.XMLParseException: '=' missing in attribute. at oracle.xml.parser.v2.XMLError.flushErrors1(XMLError.java:320) at oracle.xml.parser.v2.NonValidatingParser.parseAttrValue(NonValidatingParser.java:1609) at oracle.xml.parser.v2.NonValidatingParser.parseAttr(NonValidatingParser.java:1514) at oracle.xml.parser.v2.NonValidatingParser.parseAttributes(NonValidatingParser.java:1447) at oracle.xml.parser.v2.NonValidatingParser.parseElement(NonValidatingParser.java:1286) at oracle.xml.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:336) at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:303) at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:291) at oracle.tip.pc.services.translation.xlators.xsd.XSDTranslator.translateFromNative(XSDTranslator.java:134) ... 8 more
    The Payload is the following:
    <?xml version="1.0" ?><OMG_O19 xmlns="urn:oracle:integration:b2b:C023D5B231EF45519AA3D9929B4990E1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" XDataVersion="2.0" Standard="HL7" Version="2.4" CreatedDate="2007-07-17T17:10:43" CreatedBy="ECXEngine_837" GUID="{D16D28B9-3821-4BCC-B4D9-0D92F8611BB5}"><Internal-Properties><Data-Structure Name="Message"><Lookup Name="MessageSendingApp">ALERT</Lookup><Lookup Name="MessageSendingAppUniversalID"></Lookup><Lookup Name="MessageSendingAppUniversalIDType"></Lookup><Lookup Name="MessageSendingFacility">CHVNG</Lookup><Lookup Name="MessageSendingFacilityUniversalID"></Lookup><Lookup Name="MessageSendingFacilityUniversalIDType"></Lookup><Lookup Name="MessageReceivingApp">RADIO</Lookup><Lookup Name="MessageReceivingAppUniversalID"></Lookup><Lookup Name="MessageReceivingAppUniversalIDType"></Lookup><Lookup Name="MessageReceivingFacility">CHVNG</Lookup><Lookup Name="MessageReceivingFacilityUniversalID"></Lookup><Lookup Name="MessageReceivingFacilityUniversalIDType"></Lookup><Lookup Name="MessageCode">OMG</Lookup><Lookup Name="TriggerEvent">O19</Lookup><Lookup Name="MessageStructure">OMG_O19</Lookup><Lookup Name="MessageVersion">2.4</Lookup><Lookup Name="InternatCodeID"></Lookup><Lookup Name="InternatCodeText"></Lookup><Lookup Name="InternatCodeSystem"></Lookup><Lookup Name="InternatCodeAlternateID"></Lookup><Lookup Name="InternatCodeAlternateText"></Lookup><Lookup Name="InternatCodeAlternateSystem"></Lookup><Lookup Name="InternationalVersionID"></Lookup><Lookup Name="InternationalVersionIDText"></Lookup><Lookup Name="InternationalVersionIDSystem"></Lookup><Lookup Name="InternationalVersionIDAlternateID"></Lookup><Lookup Name="InternationalVersionIDAlternateText"></Lookup><Lookup Name="InternationalVersionIDAlternateSystem"></Lookup><Lookup Name="Standard">HL7</Lookup><Property Name="MessageEncodingCharacters">^~\&amp;</Property><Property Name="MessageSendingApp">ALERT</Property><Property Name="MessageSendingAppUniversalID"></Property><Property Name="MessageSendingAppUniversalIDType"></Property><Property Name="MessageSendingFacility">CHVNG</Property><Property Name="MessageSendingFacilityUniversalID"></Property><Property Name="MessageSendingFacilityUniversalIDType"></Property><Property Name="MessageReceivingApp">RADIO</Property><Property Name="MessageReceivingAppUniversalID"></Property><Property Name="MessageReceivingAppUniversalIDType"></Property><Property Name="MessageReceivingFacility">CHVNG</Property><Property Name="MessageReceivingFacilityUniversalID"></Property><Property Name="MessageReceivingFacilityUniversalIDType"></Property><Property Name="MessageDate">20070705161247+0000</Property><Property Name="MessageDateTimePrecision"></Property><Property Name="MessageSecurity"></Property><Property Name="MessageCode">OMG</Property><Property Name="TriggerEvent">O19</Property><Property Name="MessageStructure">OMG_O19</Property><Property Name="MessageControlID">1709</Property><Property Name="ProcessingID">P</Property><Property Name="ProcessingMode"></Property><Property Name="MessageVersion">2.4</Property><Property Name="InternatCodeID"></Property><Property Name="InternatCodeText"></Property><Property Name="InternatCodeSystem"></Property><Property Name="InternatCodeAlternateID"></Property><Property Name="InternatCodeAlternateText"></Property><Property Name="InternatCodeAlternateSystem"></Property><Property Name="InternationalVersionID"></Property><Property Name="InternationalVersionIDText"></Property><Property Name="InternationalVersionIDSystem"></Property><Property Name="InternationalVersionIDAlternateID"></Property><Property Name="InternationalVersionIDAlternateText"></Property><Property Name="InternationalVersionIDAlternateSystem"></Property><Property Name="SequenceNumber"></Property><Property Name="ContinuationPointer"></Property><Property Name="AcceptAckType"></Property><Property Name="AppAckType"></Property><Property Name="CountryCode"></Property><Property Name="CharacterSet"></Property><Property Name="LanguageID"></Property><Property Name="LanguageText"></Property><Property Name="LanguageSystem"></Property><Property Name="LanguageAlternateID"></Property><Property Name="LanguageAlternateText"></Property><Property Name="LanguageAlternateSystem"></Property><Property Name="AlternateCharacterSetSchema"></Property><Property Name="ConformanceStatementID"></Property><Property Name="MessageProfileNamespaceID"></Property><Property Name="MessageProfileUniversalID"></Property><Property Name="MessageProfileUniversalIDType"></Property><Property Name="DecimalSeparator"></Property><Property Name="ElementDelimiter">0x7c</Property><Property Name="ReleaseCharacter">0x5c</Property><Property Name="RepeatingSeparator">0x7e</Property><Property Name="SegmentDelimiter">0xd</Property><Property Name="SubcomponentDelimiter">0x26</Property><Property Name="SubelementDelimiter">0x5e</Property></Data-Structure></Internal-Properties><MSH><MSH.1>|</MSH.1><MSH.2>^~\&amp;</MSH.2><MSH.3><HD.1>ALERT</HD.1></MSH.3><MSH.4><HD.1>CHVNG</HD.1></MSH.4><MSH.5><HD.1>RADIO</HD.1></MSH.5><MSH.6><HD.1>CHVNG</HD.1></MSH.6><MSH.7><TS.1>20070705161247+0000</TS.1></MSH.7><MSH.8 xsi:nil="true"></MSH.8><MSH.9><MSG.1>OMG</MSG.1><MSG.2>O19</MSG.2><MSG.3>OMG_O19</MSG.3></MSH.9><MSH.10>1709</MSH.10><MSH.11><PT.1>P</PT.1></MSH.11><MSH.12><VID.1>2.4</VID.1></MSH.12><MSH.13 xsi:nil="true"></MSH.13></MSH><Extra-
    PID><Extra-
    PID.1 xsi:nil="true"></Extra-
    PID.1><Extra-
    PID.2 xsi:nil="true"></Extra-
    PID.2><Extra-
    PID.3><Extra-
    PID.3.1>390971</Extra-
    PID.3.1><Extra-
    PID.3.2 xsi:nil="true"></Extra-
    PID.3.2><Extra-
    PID.3.3 xsi:nil="true"></Extra-
    PID.3.3><Extra-
    PID.3.4>CHVNG</Extra-
    PID.3.4><Extra-
    PID.3.5>NS</Extra-
    PID.3.5></Extra-
    PID.3><Extra-
    PID.4 xsi:nil="true"></Extra-
    PID.4><Extra-
    PID.5><Extra-
    PID.5.1>Santos</Extra-
    PID.5.1><Extra-
    PID.5.2>Paula</Extra-
    PID.5.2><Extra-
    PID.5.3>Cristina Silva Lopes</Extra-
    PID.5.3></Extra-
    PID.5><Extra-
    PID.6 xsi:nil="true"></Extra-
    PID.6><Extra-
    PID.7>19720117000000+0000</Extra-
    PID.7><Extra-
    PID.8 xsi:nil="true"></Extra-
    PID.8><Extra-
    PID.9 xsi:nil="true"></Extra-
    PID.9><Extra-
    PID.10 xsi:nil="true"></Extra-
    PID.10><Extra-
    PID.11><Extra-
    PID.11.1>R Bernardino Costa 358 Bl D Hab 04</Extra-
    PID.11.1><Extra-
    PID.11.2 xsi:nil="true"></Extra-
    PID.11.2><Extra-
    PID.11.3>Valadares</Extra-
    PID.11.3><Extra-
    PID.11.4 xsi:nil="true"></Extra-
    PID.11.4><Extra-
    PID.11.5>4405</Extra-
    PID.11.5></Extra-
    PID.11><Extra-
    PID.12 xsi:nil="true"></Extra-
    PID.12><Extra-
    PID.13 xsi:nil="true"></Extra-
    PID.13><Extra-
    PID.14 xsi:nil="true"></Extra-
    PID.14><Extra-
    PID.15 xsi:nil="true"></Extra-
    PID.15><Extra-
    PID.16 xsi:nil="true"></Extra-
    PID.16><Extra-
    PID.17 xsi:nil="true"></Extra-
    PID.17><Extra-
    PID.18>7011588</Extra-
    PID.18><Extra-
    PID.19 xsi:nil="true"></Extra-
    PID.19></Extra-
    PID><Extra-
    PV1><Extra-
    PV1.1 xsi:nil="true"></Extra-
    PV1.1><Extra-
    PV1.2>URG</Extra-
    PV1.2><Extra-
    PV1.3><Extra-
    PV1.3.1>1</Extra-
    PV1.3.1><Extra-
    PV1.3.2 xsi:nil="true"></Extra-
    PV1.3.2><Extra-
    PV1.3.3 xsi:nil="true"></Extra-
    PV1.3.3><Extra-
    PV1.3.4>CHVNG</Extra-
    PV1.3.4></Extra-
    PV1.3><Extra-
    PV1.4 xsi:nil="true"></Extra-
    PV1.4><Extra-
    PV1.5 xsi:nil="true"></Extra-
    PV1.5><Extra-
    PV1.6 xsi:nil="true"></Extra-
    PV1.6><Extra-
    PV1.7 xsi:nil="true"></Extra-
    PV1.7><Extra-
    PV1.8 xsi:nil="true"></Extra-
    PV1.8><Extra-
    PV1.9 xsi:nil="true"></Extra-
    PV1.9><Extra-
    PV1.10 xsi:nil="true"></Extra-
    PV1.10><Extra-
    PV1.11 xsi:nil="true"></Extra-
    PV1.11><Extra-
    PV1.12 xsi:nil="true"></Extra-
    PV1.12><Extra-
    PV1.13 xsi:nil="true"></Extra-
    PV1.13><Extra-
    PV1.14 xsi:nil="true"></Extra-
    PV1.14><Extra-
    PV1.15 xsi:nil="true"></Extra-
    PV1.15><Extra-
    PV1.16 xsi:nil="true"></Extra-
    PV1.16><Extra-
    PV1.17 xsi:nil="true"></Extra-
    PV1.17><Extra-
    PV1.18>URG</Extra-
    PV1.18><Extra-
    PV1.19><Extra-
    PV1.19.1>7088430</Extra-
    PV1.19.1><Extra-
    PV1.19.2 xsi:nil="true"></Extra-
    PV1.19.2><Extra-
    PV1.19.3 xsi:nil="true"></Extra-
    PV1.19.3><Extra-
    PV1.19.4>SONHO</Extra-
    PV1.19.4></Extra-
    PV1.19><Extra-
    PV1.20 xsi:nil="true"></Extra-
    PV1.20><Extra-
    PV1.21 xsi:nil="true"></Extra-
    PV1.21><Extra-
    PV1.22 xsi:nil="true"></Extra-
    PV1.22><Extra-
    PV1.23 xsi:nil="true"></Extra-
    PV1.23><Extra-
    PV1.24 xsi:nil="true"></Extra-
    PV1.24><Extra-
    PV1.25 xsi:nil="true"></Extra-
    PV1.25><Extra-
    PV1.26 xsi:nil="true"></Extra-
    PV1.26><Extra-
    PV1.27 xsi:nil="true"></Extra-
    PV1.27><Extra-
    PV1.28 xsi:nil="true"></Extra-
    PV1.28><Extra-
    PV1.29 xsi:nil="true"></Extra-
    PV1.29><Extra-
    PV1.30 xsi:nil="true"></Extra-
    PV1.30><Extra-
    PV1.31 xsi:nil="true"></Extra-
    PV1.31><Extra-
    PV1.32 xsi:nil="true"></Extra-
    PV1.32><Extra-
    PV1.33 xsi:nil="true"></Extra-
    PV1.33><Extra-
    PV1.34 xsi:nil="true"></Extra-
    PV1.34><Extra-
    PV1.35 xsi:nil="true"></Extra-
    PV1.35><Extra-
    PV1.36 xsi:nil="true"></Extra-
    PV1.36><Extra-
    PV1.37 xsi:nil="true"></Extra-
    PV1.37><Extra-
    PV1.38 xsi:nil="true"></Extra-
    PV1.38><Extra-
    PV1.39 xsi:nil="true"></Extra-
    PV1.39><Extra-
    PV1.40 xsi:nil="true"></Extra-
    PV1.40><Extra-
    PV1.41 xsi:nil="true"></Extra-
    PV1.41><Extra-
    PV1.42 xsi:nil="true"></Extra-
    PV1.42><Extra-
    PV1.43 xsi:nil="true"></Extra-
    PV1.43><Extra-
    PV1.44>20070705154838+0000</Extra-
    PV1.44><Extra-
    PV1.45 xsi:nil="true"></Extra-
    PV1.45><Extra-
    PV1.46 xsi:nil="true"></Extra-
    PV1.46><Extra-
    PV1.47 xsi:nil="true"></Extra-
    PV1.47><Extra-
    PV1.48 xsi:nil="true"></Extra-
    PV1.48><Extra-
    PV1.49 xsi:nil="true"></Extra-
    PV1.49><Extra-
    PV1.50 xsi:nil="true"></Extra-
    PV1.50><Extra-
    PV1.51>V</Extra-
    PV1.51><Extra-
    PV1.52 xsi:nil="true"></Extra-
    PV1.52></Extra-
    PV1><Extra-
    ORC><Extra-
    ORC.1>NW</Extra-
    ORC.1><Extra-
    ORC.2><Extra-
    ORC.2.1>19013</Extra-
    ORC.2.1><Extra-
    ORC.2.2>ALERT</Extra-
    ORC.2.2></Extra-
    ORC.2><Extra-
    ORC.3 xsi:nil="true"></Extra-
    ORC.3><Extra-
    ORC.4 xsi:nil="true"></Extra-
    ORC.4><Extra-
    ORC.5>NW</Extra-
    ORC.5><Extra-
    ORC.6 xsi:nil="true"></Extra-
    ORC.6><Extra-
    ORC.7 xsi:nil="true"></Extra-
    ORC.7><Extra-
    ORC.8 xsi:nil="true"></Extra-
    ORC.8><Extra-
    ORC.9 xsi:nil="true"></Extra-
    ORC.9><Extra-
    ORC.10 xsi:nil="true"></Extra-
    ORC.10><Extra-
    ORC.11 xsi:nil="true"></Extra-
    ORC.11><Extra-
    ORC.12><Extra-
    ORC.12.1>4292</Extra-
    ORC.12.1><Extra-
    ORC.12.2>Martinez</Extra-
    ORC.12.2><Extra-
    ORC.12.3>Cristina</Extra-
    ORC.12.3></Extra-
    ORC.12><Extra-
    ORC.13 xsi:nil="true"></Extra-
    ORC.13></Extra-
    ORC><Extra-
    OBR><Extra-
    OBR.1>1</Extra-
    OBR.1><Extra-
    OBR.2><Extra-
    OBR.2.1>19013</Extra-
    OBR.2.1><Extra-
    OBR.2.2>ALERT</Extra-
    OBR.2.2></Extra-
    OBR.2><Extra-
    OBR.3 xsi:nil="true"></Extra-
    OBR.3><Extra-
    OBR.4><Extra-
    OBR.4.1>10781</Extra-
    OBR.4.1><Extra-
    OBR.4.2>M<escape V="XE3"/>o direita, duas incid<escape V="XEA"/>ncias</Extra-
    OBR.4.2><Extra-
    OBR.4.3>CHVNG</Extra-
    OBR.4.3></Extra-
    OBR.4><Extra-
    OBR.5 xsi:nil="true"></Extra-
    OBR.5><Extra-
    OBR.6 xsi:nil="true"></Extra-
    OBR.6><Extra-
    OBR.7 xsi:nil="true"></Extra-
    OBR.7><Extra-
    OBR.8 xsi:nil="true"></Extra-
    OBR.8><Extra-
    OBR.9 xsi:nil="true"></Extra-
    OBR.9><Extra-
    OBR.10 xsi:nil="true"></Extra-
    OBR.10><Extra-
    OBR.11 xsi:nil="true"></Extra-
    OBR.11><Extra-
    OBR.12 xsi:nil="true"></Extra-
    OBR.12><Extra-
    OBR.13 xsi:nil="true"></Extra-
    OBR.13><Extra-
    OBR.14 xsi:nil="true"></Extra-
    OBR.14><Extra-
    OBR.15 xsi:nil="true"></Extra-
    OBR.15><Extra-
    OBR.16><Extra-
    OBR.16.1>4292</Extra-
    OBR.16.1><Extra-
    OBR.16.2>Martinez</Extra-
    OBR.16.2><Extra-
    OBR.16.3>Cristina</Extra-
    OBR.16.3></Extra-
    OBR.16><Extra-
    OBR.17 xsi:nil="true"></Extra-
    OBR.17><Extra-
    OBR.18 xsi:nil="true"></Extra-
    OBR.18><Extra-
    OBR.19 xsi:nil="true"></Extra-
    OBR.19><Extra-
    OBR.20 xsi:nil="true"></Extra-
    OBR.20><Extra-
    OBR.21 xsi:nil="true"></Extra-
    OBR.21><Extra-
    OBR.22 xsi:nil="true"></Extra-
    OBR.22><Extra-
    OBR.23 xsi:nil="true"></Extra-
    OBR.23><Extra-
    OBR.24 xsi:nil="true"></Extra-
    OBR.24><Extra-
    OBR.25 xsi:nil="true"></Extra-
    OBR.25><Extra-
    OBR.26 xsi:nil="true"></Extra-
    OBR.26><Extra-
    OBR.27><Extra-
    OBR.27.1 xsi:nil="true"></Extra-
    OBR.27.1><Extra-
    OBR.27.2 xsi:nil="true"></Extra-
    OBR.27.2><Extra-
    OBR.27.3 xsi:nil="true"></Extra-
    OBR.27.3><Extra-
    OBR.27.4>20070705161237+0000</Extra-
    OBR.27.4></Extra-
    OBR.27><Extra-
    OBR.28 xsi:nil="true"></Extra-
    OBR.28></Extra-
    OBR><Extra-
    NTE><Extra-
    NTE.1>1</Extra-
    NTE.1><Extra-
    NTE.2 xsi:nil="true"></Extra-
    NTE.2></Extra-
    NTE><Extra-
    DG1><Extra-
    DG1.1>1</Extra-
    DG1.1><Extra-
    DG1.2 xsi:nil="true"></Extra-
    DG1.2><Extra-
    DG1.3><Extra-
    DG1.3.1>9233</Extra-
    DG1.3.1><Extra-
    DG1.3.2>Contusao De Dedo Da Mao</Extra-
    DG1.3.2><Extra-
    DG1.3.3>ICD9</Extra-
    DG1.3.3></Extra-
    DG1.3><Extra-
    DG1.4 xsi:nil="true"></Extra-
    DG1.4><Extra-
    DG1.5 xsi:nil="true"></Extra-
    DG1.5><Extra-
    DG1.6>D</Extra-
    DG1.6></Extra-
    DG1></OMG_O19>
    I think that the problem should be because of the "Extra" (eg. <Extra-
    PID.1 xsi:nil="true">) word that B2B puts in every tag.
    The strange thing is that, this already worked until two days ago....
    What could it be?
    Thanks for your help.
    Best Regards,
    Nuno Fernandes

  • XML DOM Parsing getAttributes() in J2SE 5.0 vs. J2SE 1.4

    I am experiencing the following problem, with the Node.getAttributes() function although the following code runs fine under Java 1.4, and getAttributes() returns the actual string attribute values:
                File xmlFile = new File(fileName);
                DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
                DocumentBuilder builder = factory.newDocumentBuilder();
                Document doc = builder.parse(xmlFile);
                // Begin analyzing XML
                Element root = doc.getDocumentElement();
                // Enumerate all children
                NodeList children = root.getChildNodes();
                    Node rootNode = null;
                    NodeList nodeList = children;
                    for (int R = 0; R < nodeList.getLength() ; R++)
                        if (nodeList.item(R).getNodeType() == Node.ELEMENT_NODE)
                            rootNode = nodeList.item(R);
                            System.out.println("> " + rootNode.getNodeName() + " - " + rootNode.getAttributes().toString());
                 In J2SE 5.0 the Node.getAttributes() returns the following:
    [email protected]d of returning then the actual attribute string (like in Java 1.4)!
    If it helps at all I am using DOM parser (as noticed above, org.w3c.dom)
    My assumption is that J2SE 5.0 returns an attribute map that is encoded differently then Java 1.4
    Thank you for your time & appreciate any help...

    The getAttributes method returns a NamedNodeMap.
    Iterate over the NamedNodeMap to get attribute values.
    Instead of rootNode.getAttributes().toString();
    NamedNodeMap map=rootNode.getAttributes().toString();
    for(int i=0; i<map.getLength(); i++){
    Node node=map.item(i);
    if(node.getNodeType()==Node.ATTRIBUTE_NODE)
    System.out.println("Attribute Node "+node.getNodeName()+ "has value "+ node.getNodeValue());
    }

  • Parsing an XML using DOM parser in Java in Recursive fashion

    I need to parse an XML using DOM parser in Java. New tags can be added to the XML in future. Code should be written in such a way that even with new tags added there should not be any code change. I felt that parsing the XML recursively can solve this problem. Can any one please share sample Java code that parses XML recursively. Thanks in Advance.

    Actually, if you are planning to use DOM then you will be doing that task after you parse the data. But anyway, have you read any tutorials or books about how to process XML in Java? If not, my suggestion would be to start by doing that. You cannot learn that by fishing on forums. Try this one for example:
    http://www.cafeconleche.org/books/xmljava/chapters/index.html

  • Parsing xml using DOM parser in java

    hi there!!!
    i don have much idea about parsing xml.. i have an xml file which consists of details regarding indentation and spacing standards of C lang.. i need to read the file using DOM parser in java n store each of the attributes n elements in some data structure in java..
    need help as soon as possible!!!

    DOM is the easiest way to parse XML document, google for JDOM example it is very easy to implement.
    you need to know what is attribute, what is text content and what is Value in XML then easily you can parse your document with dom (watch for space[text#] in your XML document when you parse it).
    you get root node then nodelist of childs for root then go further inside, it is easy believe me.

  • DOM Parsing problems... (newbie in trouble)

    I am trying to get a DOM Parser contruct a DOM Object from an XML file... I am having trouble getting the code validate against my XML Schema: <p>
    <?xml version="1.0" encoding="UTF-8"?> <
    <!-- edited with XML Spy v4.4 U (http://www.xmlspy.com) by Fedro E. Ponce de Leon Luengas (ASI Consulores, S.A. de C.V.) -->
    <xs:schema targetNamespace="http://palaciohierro.com.mx/mde/expe" xmlns="http://palaciohierro.com.mx/mde/expe" xmlns:xs="http://www.w3.org/2001/XMLSchema">
    <xs:element name="existencia-peticion" type="epType">
    <xs:annotation>
    <xs:documentation>Peticion de existencias para la Mesa de Eventos Web</xs:documentation>
    </xs:annotation>
    </xs:element>
    <xs:complexType name="epType">
    <xs:annotation>
    <xs:documentation>peticion de existencia</xs:documentation>
    </xs:annotation>
    <xs:sequence>
    <xs:element name="articulo" type="articuloType" maxOccurs="unbounded"/>
    </xs:sequence>
    </xs:complexType>
    <xs:complexType name="articuloType">
    <xs:annotation>
    <xs:documentation>articulo</xs:documentation>
    </xs:annotation>
    <xs:attribute name="id_articulo" type="IdentifierType" use="required"/>
    <xs:attribute name="sku" type="skuType" use="required"/>
    </xs:complexType>
    <xs:simpleType name="IdentifierType">
    <xs:annotation>
    <xs:documentation>identificador</xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:long">
    <xs:minInclusive value="0"/>
    <xs:maxInclusive value="999999999999999999"/>
    <xs:totalDigits value="22"/>
    <xs:fractionDigits value="0"/>
    </xs:restriction>
    </xs:simpleType>
    <xs:simpleType name="skuType">
    <xs:annotation>
    <xs:documentation>sku</xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
    <xs:minLength value="11"/>
    <xs:maxLength value="20"/>
    <xs:pattern value="\d{11,20}"/>
    </xs:restriction>
    </xs:simpleType>
    </xs:schema>
    taking this sample XML file:
    <?xml version="1.0" encoding="UTF-8"?>
    <!--Sample XML file generated by XML Spy v4.4 U (http://www.xmlspy.com)-->
    <expe:existencia-peticion xmlns:expe="http://palaciohierro.com.mx/mde/expe" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://palaciohierro.com.mx/mde/expe
    C:\oracle\Oracle9iDS\jdev\mywork\testCompra\MesaEventos\src\ph\mesaeventos\schema\existencia-peticion.xsd">
    <articulo id_articulo="450" sku="12245110021"/>
    <articulo id_articulo="15" sku="45421213223"/>
    <articulo id_articulo="12" sku="121131231858"/>
    <articulo id_articulo="74" sku="4101031234545"/>
    <articulo id_articulo="871" sku="022324563212"/>
    </expe:existencia-peticion>
    with the following code:
    public Document getDOM( String existenciapeticionXML ) throws Exception
    // Obtain parser instance and parse the document
    DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
    factory.setValidating( true );
    factory.setNamespaceAware( true );
    DocumentBuilder builder = factory.newDocumentBuilder();
    byte buf[] = existenciapeticionXML.getBytes();
    ByteArrayInputStream stream = new ByteArrayInputStream( buf );
    Document doc = builder.parse( stream );
    return doc;
    I am getting the following Exception:
    oracle.xml.parser.v2.XMLParseException: Element 'expe:existencia-peticion' used but not declared.
    void oracle.xml.parser.v2.XMLError.flushErrors()
    XMLError.java:145
    void oracle.xml.parser.v2.NonValidatingParser.parseDocument()
    NonValidatingParser.java:263
    void oracle.xml.parser.v2.XMLParser.parse(org.xml.sax.InputSource)
    XMLParser.java:141
    org.w3c.dom.Document oracle.xml.jaxp.JXDocumentBuilder.parse(org.xml.sax.InputSource)
    JXDocumentBuilder.java:96
    org.w3c.dom.Document javax.xml.parsers.DocumentBuilder.parse(java.io.InputStream)
    DocumentBuilder.java:119
    org.w3c.dom.Document ph.mesaeventos.mesa.xml.ExistenciaPeticionDOM.getDOM(java.lang.String)
    ExistenciaPeticionDOM.java:26
    void ph.mesaeventos.mesa.xml.Test.main(java.lang.String[])
    Test.java:38
    What am I doing wrong? I am clueless... please help!
    Thanks,

    I finally managed to make it work.... well quite!
    Having an XML Doc like this:
    <?xml version="1.0"?>
    <existencia-peticion xmlns = "http://palaciohierro.com.mx/mde/expe">
    <articulo id_articulo="10" sku="00000000010"></articulo>
    <articulo id_articulo="11" sku="00000000011"></articulo>
    <articulo id_articulo="12" sku="00000000012"></articulo>
    <articulo id_articulo="13" sku="00000000013"></articulo>
    </existencia-peticion>
    with an schema like:
    <?xml version="1.0" encoding="UTF-8"?>
    <schema targetNamespace="http://palaciohierro.com.mx/mde/expe"
    xmlns="http://www.w3.org/2001/XMLSchema"
    xmlns:expe="http://palaciohierro.com.mx/mde/expe"
    elementFormDefault="qualified">
    <annotation>
    <documentation xml:lang="es">
    Esquema de peticion de existencias para la Mesa de Eventos Web
    Copyright 2002 palaciodehierro.com.mx. Todos los derechos reservados.
    </documentation>
    </annotation>
    <element name="existencia-peticion" type="expe:epType">
    <unique name="id_articulo">
    <selector xpath="expe:articulo"/>
    <field xpath="@id_articulo"/>
    </unique>
    <unique name="sku">
    <selector xpath="expe:articulo"/>
    <field xpath="@sku"/>
    </unique>
    </element>
    <complexType name="epType">
    <annotation>
    <documentation>peticion de existencias</documentation>
    </annotation>
    <sequence>
    <element name="articulo" type="expe:articuloType" maxOccurs="unbounded"/>
    </sequence>
    </complexType>
    <complexType name="articuloType">
    <annotation>
    <documentation>articulo</documentation>
    </annotation>
    <attribute name="id_articulo" type="expe:IdentifierType" use="required"/>
    <attribute name="sku" type="expe:skuType" use="required"/>
    </complexType>
    <simpleType name="IdentifierType">
    <annotation>
    <documentation>identificador</documentation>
    </annotation>
    <restriction base="long">
    <minInclusive value="0"/>
    <maxInclusive value="999999999999999999"/>
    <totalDigits value="18"/>
    <fractionDigits value="0"/>
    </restriction>
    </simpleType>
    <simpleType name="skuType">
    <annotation>
    <documentation>sku</documentation>
    </annotation>
    <restriction base="string">
    <minLength value="11"/>
    <maxLength value="20"/>
    <pattern value="\d{11,20}"/>
    </restriction>
    </simpleType>
    </schema>
    and with the following class:
    public class XMLValidator
    // Instancia singleton
    private static XMLValidator validator = new XMLValidator();
    * Constructor privado
    private XMLValidator()
    * Mitodo para acceder a la instancia Singleton de XMLValidator
    * @regresa <b>XMLValidator</b> La instancia de esta clase
    public static XMLValidator getValidator()
    return validator;
    public boolean validaEsquema( String docXML, String esquema ) throws Exception
    // Establece el URL correcto para el documento de esquema
    XSDBuilder builder = new XSDBuilder();
    URL url = createURL( esquema );
    // Construye el objecto del Schema XML
    try
    XMLSchema schemadoc = (XMLSchema)builder.build( url );
    // Valida el documento XML procesandolo contra el esquema
    return validate( docXML, schemadoc );
    catch( XMLParseException e )
    throw new Exception( "Error al analizar el documento XML: " + e.getMessage() );
    catch( Exception e )
    throw new Exception( "No es posible validar con el esquema: " + e.getMessage() );
    private static boolean validate(String docXML, XMLSchema schemadoc) throws Exception
    boolean isValid = false;
    // Crea un objeto Parser DOM de XML
    DOMParser dp = new DOMParser();
    // Establece el objeto Schema XML para la validacion
    dp.setXMLSchema( schemadoc );
    dp.setValidationMode( XMLParser.SCHEMA_VALIDATION );
    dp.setPreserveWhitespace( true );
    // Establece la salida de errores
    dp.setErrorStream( System.out );
    // Recupera los datos del documento XML en un objeto InputStream
    byte[] docbytes = docXML.getBytes();
    ByteArrayInputStream in = new ByteArrayInputStream( docbytes );
    // Parsea el documento y validalo contra el esquema
    try
    dp.parse( in );
    isValid = true;
    catch( Exception e )
    // Devuelve el documento XML DOM construido durante el parseo
    return isValid;
    I am able to validate when invoking with the XML and schemas in the parameters...
    Problem is that I have to include the attribute xmlns = "http://palaciohierro.com.mx/mde/expe" in my XML doc.
    What I really need is to be able to validate de XML doc against a stablished schema, when the XML doc does not include the
    xmlns attribute.

  • DOM Parsing Exception in translator

    Hi
    We are hitting one issue in B2B/SOA 11g.
    BPEL instance is not getting created in 11g. Messages are picked from B2B queue and BPEL is failing while dequeing.
    It says that
    DOM Parsing Exception in translator. DOM parsing exception in inbound XSD translator while parsing InputStream. Please make sure that the xml data is valid.
    Is it due to large size of the message. I have seen the message size and it is more than 3 MB.
    Pls help
    Thanks
    Simarjeet

    Hi Anuj
    I have analysed the issue in detail. B2B is not generating the payload for one of the message so dequeue is failing and message is rejected.
    Say in one EDI file, we have 6 messages then B2B is able to create 6 separate messages while debatching but one of the message payload is empty. Error in log is
    DOM parsing exception in inbound XSD translator while parsing InputStream.
    Please make sure that the xml data is valid.
    DOM Parsing Exception in translator.
    DOM parsing exception in inbound XSD translator while parsing InputStream.
    Please make sure that the xml data is valid.
         at oracle.tip.adapter.aq.v2.database.MessageConverter.translateMessageBytes(MessageConverter.java:510)
         at oracle.tip.adapter.aq.v2.database.MessageConverter.getSTRUCTPayload(MessageConverter.java:404)
         at oracle.tip.adapter.aq.v2.database.MessageConverter.getPayload(MessageConverter.java:139)
         at oracle.tip.adapter.aq.v2.database.XMLRecordMessageConverter.getRecord(XMLRecordMessageConverter.java:88)
         at oracle.tip.adapter.aq.v2.database.AbstractDequeueAgent.getInputRecord(AbstractDequeueAgent.java:236)
         at oracle.tip.adapter.aq.v2.database.AbstractDequeueAgent.run(AbstractDequeueAgent.java:101)
         at oracle.integration.platform.blocks.executor.WorkManagerExecutor$1.run(WorkManagerExecutor.java:105)
         at weblogic.work.j2ee.J2EEWorkManager$WorkWithListener.run(J2EEWorkManager.java:183)
         at weblogic.work.DaemonWorkThread.run(DaemonWorkThread.java:30)
    Caused by: ORABPEL-11211
    DOM Parsing Exception in translator.
    DOM parsing exception in inbound XSD translator while parsing InputStream.
    Please make sure that the xml data is valid.
         at oracle.tip.pc.services.translation.xlators.xsd.XSDTranslator.translateFromNative(XSDTranslator.java:607)
         at oracle.tip.adapter.aq.v2.database.MessageConverter.translateMessageBytes(MessageConverter.java:506)
         ... 8 more
    Caused by: oracle.xml.parser.v2.XMLParseException: Start of root element expected.
         at oracle.xml.parser.v2.XMLError.flushErrors1(XMLError.java:323)
         at oracle.xml.parser.v2.NonValidatingParser.parseRootElement(NonValidatingParser.java:380)
         at oracle.xml.parser.v2.NonValidatingParser.parseDocument(NonValidatingParser.java:321)
         at oracle.xml.parser.v2.XMLParser.parse(XMLParser.java:226)
         at oracle.tip.pc.services.translation.xlators.xsd.XSDTranslator.translateFromNative(XSDTranslator.java:601)
         ... 9 more
    I have also tested the file using various modes unix/pc and ansi/utf-8 encoding. Is this issue related with performance tuning, tablespace etc?

Maybe you are looking for

  • Alv Grid to Excel Sheet Downloading problem for Bank account Number(CHAR18)

    Hi every one,              I am downloading  Alv grid to excel using local file---> spreadsheet but,  the bank account no is populating as like ''11+E213". When press F2 in that column then only its showing the correct value. If i do download directl

  • Maintain Vendor for the excise invoice Message no. 4F185

    I am doing stock transfer PLANT to PLANT. ME21N, VL10D, VF01 and J1IIN it was save properly. After that I make MIGO. That time Error show "Maintain Vendor for the excise invoice Message no. 4F185" MIGO time I am changing Indicator for material type F

  • Regarding Iterm Proposal Creation

    Hello , i got one error message while  creating the item proposal in VA51 "Company was not supplied in Function Module interface"  and when i double click on this i showing one error message number "Message no. FI320" please  give any solution to sol

  • Scheduled TMS_ # TMS_TP_IMPORT  background jobs fail with error code 0232

    Is anyone else having the problem we've just encountered since upgrading to ECC 6.0 and CRM 2007, where once setting up the automatic import ALL background jobs, to have all of the Transport Change Requests imported into the Q-Prod testing systems au

  • EAS doesnt work when LDAP server is changed

    hi all, My Ldap server didn't work and so we had to replace it with another server.Then we placed the new ip address in the css.xml file for planning and essbase and then they started wroking fine.But when i am tring to login into EAS using an extern