Issue with XML encoding

Hi,
I am querying an SAP instance for data, and I am getting back the data in an XML document...to which I need apply XSL transformation.
The instance is an German one... so I am getting a few strange characters because of which, the parser is uanble to apply the transformation.
I wrote a small java program to get more info on this particular character causing the problem, it turns out to be an ISOControl character. The properties (got by using the Character class API) are as below.
1. Character 1:
The getDirectionality is:0
The getNumericValue is:21
The getType is:2
The isDefined is:true
The isISOControl is:false
The isMirrored is:false
The isSpaceChar is:false
The isUnicodeIdentifierPart is:true
The isUnicodeIdentifierStart is:true
The isWhitespace is:false
2. character 2:
The getDirectionality is:9
The getNumericValue is:-1
The getType is:15
The isDefined is:true
The isISOControl is:true
The isMirrored is:false
The isSpaceChar is:false
The isUnicodeIdentifierPart is:true
The isUnicodeIdentifierStart is:false
The isWhitespace is:false
These characters appear to be white space in normal text editors...
This is how I am applying the transformation
TransformerFactory tFactory = TransformerFactory.newInstance();
Transformer transformer =
tFactory.newTransformer(
new javax.xml.transform.stream.StreamSource
(XSLURI)
StringReader sr = new StringReader(xmlToApply);
StringWriter sw = new StringWriter();
transformer.transform(
new javax.xml.transform.stream.StreamSource(sr),
new javax.xml.transform.stream.StreamResult(sw)
return sw.toString();
I have tried to use "UTF-8", "ISO-8859-1" and other encodings, but in vain. Appreciate any pointers on this...

Also the postings are from 2 different perspectives... this is to address the issue that I am facing with XML parsing and how to eliminate that using XML apis...
My other posting about a possible work around (encoding) for the problem creating string...

Similar Messages

  • Issues with Japanese encoding using Mail

    Since recently (I would say since I updated to 10.6), I have an issue with Japanese-encoded (ISO 2022-JP) mails on my English MacOS.
    I have no problem to read, edit and write answers to any mails.
    However with some ISO JP-2022-JP encoded messages (sent with Thunderbird 2.0.0.23 (Windows/20090812) btw) I have the following misbehaviour:
    - if I send the message and let the encoding to "automatic", Mail sends the mail in UTF-8, which I do not want since most of Japanese computer do not understand UTF-8 by default (and the receiver gets panicked: "I can not read your mail T_T !")
    - if I set the encoding to "ISO JP-2022-JP", I can not send nor save the message (see [1] at the end of the post). One should note that the error message when saving is really misleading (and yes my hard-drive has a lot of space left) and it should be fixed by Apple.
    - if I dig a bit deeper, I can in effect find some characters in the original message which prevent Mail to send my mail. It however does not make any sense since:
    - those char were in the original message properly encoded in ISO JP-2022-JP
    - those char are always very common ones
    The only solution I have found so far is to delete the original message in my mail, which is very frustrating...
    A sample of such mail can be found at (I removed personal info. and the mail is about a drinking party):
    - http://files.me.com/trouve.antoine/73w3w9
    Help would be very appreciated.
    Thank you very much.
    Antoine
    [1] I get the following error messages:
    -> try to save:
    *This message can’t be saved to the Drafts mailbox.*
    The message contains one or more attachments that
    are too large to be saved in the Drafts mailbox. Try
    deleting some attachments.
    ->try to send
    *Invalid Text Encoding*
    Some characters in your message could not be
    converted to the “Japanese (ISO 2022-JP)” text
    encoding. Choose a different encoding from the
    “Text Encoding” menu.

    You can find out about the different versions here, for example:
    http://en.wikipedia.org/wiki/ISO/IEC_2022
    Thank you. I feel a bit stupid for not having looked in Wikipedia at first...
    I sometime wonder how could such basic problem like charset not being solved after more than 40 years of computer science...
    Here is a note that addresses that problem, but I don't think it works with 10.6. Might be worth a > try:
    http://discussions.apple.com/thread.jspa?threadID=121808&tstart=60
    Thank for the link.
    It seems to still work: new japanese mails are now sent in "ISO 2022-JP-2".
    However, for messages with the header explicitly specifying "ISO 2022-JP" (which should be "ISO 2022-JP-2" on my mac) it has no influence.
    The only ways I see to solve this issue would be:
    i) to force "ISO 2022-JP-2" for all mails (a bit too extreme)
    ii) to force the use of "ISO 2022-JP-2" instead of "ISO 2022-JP", but I do not think such precise configuration is possible
    This mess appears to be due to Thunderbird which seems to mix "ISO 2022-JP-2" and "ISO 2022-JP", but I do not have any working Thunderbird to test now...

  • 10g Reports issue with XML Data Source

    Hi,
    Has anybody ever encountered an issue with Oracle 10g report using an XML as the data source? What happens is, some of the values in the XML are printed to the wrong column.
    One of the elements in our XML file is a complex type with 10 elements under it. The first 5 are picked up properly, but the last 6 are not. Elements #6 to #9 has a minimum occurence of 0. What happens is when element #6 is present, but #7 is, the value for element #7 is passed on to element #6.
    The XSD and XSL files are both valid since the reports were working when we were still using 9i. There is no hidden logic in the report which might cause this issue to come up, i.e., the report just picks up the values from the XML and prints it to the appropriate columns.
    Any help will be greatly appreciated.

    XSD used
    <?xml version="1.0" encoding="UTF-8"?>
    <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
            <!-- trade instructions detail & trailer -->
            <xs:element name="TradeDetail">
                    <xs:complexType>
                            <xs:sequence>
                                    <xs:element ref="TradeType"/>
                                    <xs:element ref="TradeID"/>
                                    <xs:element ref="TradeDate"/>
                                    <xs:element ref="FundID"/>
                                    <xs:element ref="FundName"/>
                                    <xs:element ref="DollarValue" minOccurs="0"/>
                                    <xs:element ref="UnitValue" minOccurs="0"/>
                                    <xs:element ref="PercentageValue" minOccurs="0"/>
                                    <xs:element ref="OriginalTradeID" minOccurs="0"/>
                                    <xs:element ref="CancellationFlag"/>
                            </xs:sequence>
                    </xs:complexType>
            </xs:element>
            <xs:element name="Instruction">
                    <xs:complexType>
                            <xs:sequence minOccurs="0">
                                    <xs:element ref="TradeDetail" maxOccurs="unbounded"/>
                            </xs:sequence>
                    </xs:complexType>
            </xs:element>
            <!-- overall trade instruction message -->
            <xs:element name="InterchangeHeader">
                    <xs:complexType>
                            <xs:sequence>
                                    <xs:element ref="Instruction"/>
                            </xs:sequence>
                    </xs:complexType>
            </xs:element>
            <!-- definition of simple elements -->
            <xs:element name="FundID" type="xs:string"/>
            <xs:element name="TradeType" type="xs:string"/>
            <xs:element name="TradeID" type="xs:string"/>
            <xs:element name="TradeDate" type="xs:string"/>
            <xs:element name="FundName" type="xs:string"/>
            <xs:element name="DollarValue" type="xs:decimal"/>
            <xs:element name="UnitValue" type="xs:decimal"/>
            <xs:element name="PercentageValue" type="xs:decimal"/>
            <xs:element name="OriginalTradeID" type="xs:string"/>
            <xs:element name="CancellationFlag" type="xs:string"/>
    </xs:schema>
    XML used
    <?xml version = '1.0' encoding = 'UTF-8'?>
    <InterchangeHeader xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="TradeInstruction.xsd">
       <Instruction>
          <TradeDetail>
             <TradeType>Purchase</TradeType>
             <TradeID>M000038290</TradeID>
             <TradeDate>20061201</TradeDate>
             <FundID>ARO0011AU</FundID>
             <FundName>ABN Fund</FundName>
             <DollarValue>2111.53</DollarValue>
             <CancellationFlag>N</CancellationFlag>
          </TradeDetail>
          <TradeDetail>
             <TradeType>Redemption</TradeType>
             <TradeID>M000038292</TradeID>
             <TradeDate>20061201</TradeDate>
             <FundID>ARO0011AU</FundID>
             <FundName>AMRO Equity Fund</FundName>
             <UnitValue>104881.270200</UnitValue>
             <CancellationFlag>N</CancellationFlag>
          </TradeDetail>
          <TradeDetail>
             <TradeType>ISPurchase</TradeType>
             <TradeID>M000038312</TradeID>
             <TradeDate>20061201</TradeDate>
             <FundID>MLC0011AU</FundID>
             <FundName>Cash Fund</FundName>
             <OriginalTradeID>M000038311</OriginalTradeID>
             <CancellationFlag>N</CancellationFlag>
          </TradeDetail>
       </Instruction>
    </InterchangeHeader>
    XSLT used
    <?xml version="1.0" encoding="UTF-8"?>
    <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
            <xsl:output method="xml" version="1.0" encoding="UTF-8" indent="yes"/>
            <xsl:template match="/">
                    <InterchangeHeader>
                            <xsl:for-each select="InterchangeHeader/Instruction/TradeDetail">
                            <xsl:sort select="FundName"/>
                            <xsl:sort select="TradeDate"/>
                                    <TradeDetail>
                                            <TradeType><xsl:value-of select="TradeType"/></TradeType>
                                            <TradeID><xsl:value-of select="TradeID"/></TradeID>
                                            <TradeDate><xsl:value-of select="TradeDate"/></TradeDate>
                                            <FundID><xsl:value-of select="FundID"/></FundID>
                                            <FundName><xsl:value-of select="FundName"/></FundName>
                                            <DollarValue><xsl:value-of select="DollarValue"/></DollarValue>
                                            <UnitValue><xsl:value-of select="UnitValue"/></UnitValue>
                                            <PercentageValue><xsl:value-of select="PercentageValue"/></PercentageValue>
                                            <OriginalTradeID><xsl:value-of select="OriginalTradeID"/></OriginalTradeID>
                                            <CancellationFlag><xsl:value-of select="CancellationFlag"/></CancellationFlag>
                                    </TradeDetail>
                            </xsl:for-each>
                    </InterchangeHeader>
            </xsl:template>
    </xsl:stylesheet>

  • J2SE adapter PI 7.1 issue with XML to flat conversion and namespace length

    Dear reader,
    We are facing an issue with J2SE Adapter PI7.1 for a number of flows.
    The flow requirements:
    [1] Namespace length for interfaces is up to 100 characters
    [2] The XML message must be converted to Flat on the adapter channel
    Our PI system is at patch level 7 and we implement J2SE adapter on patch level 7 as well.
    We found that the J2SE adapter on patch level 7 does not support long namespaces [1] (as it should since this is an PI 7.1 j2SE adapter) but no issues where found with the XML to flat conversion [2].
    Experimenting with J2SE adapter on patch level 6 we found the long namespaces [1] are supported however an issue is found with the XML to flat conversion [2] as stated in SAP note 1335527.
    An SAP Customer Message is raised on this issue however your input is highly appricated!
    With Kind Regards,
    Harald Kastelijn
    Edited by: Harald Kastelijn on Mar 6, 2010 9:17 AM
    Edited by: Harald Kastelijn on Mar 6, 2010 9:19 AM

    We found that the J2SE adapter on patch level 7 does not support long namespaces [1] (as it should since this is an PI 7.1
    j2SE adapter) but no issues where found with the XML to flat conversion [2]
    I think the restriction of namespace length still remains in design time (IR).....the same however has been extended in configuration and runtime...this SAP note has some information: https://service.sap.com/sap/support/notes/870809

  • Issue with XML bursting program

    Hi All,
    We have a Oracle concurrent program which generates PDF output using XML data and RTF template. This output is sent as attachment to a designated user using XML bursting.
    The issue that we are facing is, the mail is sent to the recipients correctly when the program is run from my login. But when the same is run from anyone else’s login, the bursting program fails.
    Suppose the receiver’s email id is [email protected], the error faced is
    [oracle.apps.xdo.batch.DeliveryHelper][EXCEPTION] javax.mail.internet.AddressException: Illegal character in domain in string ``[email protected]@xyz.com''
    On examining the XML bursting program log file for successful and error runs, I could see the below property in the log file-
    For successful run: [SMTP_TO_RECIPIENTS:String] [[email protected]]
    Whereas for unsuccessful run: [SMTP_TO_RECIPIENTS:String] [[email protected]@xyz.com]
    Any pointers in this regard are highly appreciated.
    Regards,
    Kiranmayi.

    Thanks for your quick response.
    I believe the HP printer is an old one and I did have a couple of issues with it while using XML Publisher.However we've overcome those issues.
    We have installed xpdf and have been using the pdf2ps utility.We have PASTA set up and printing works fine when Bursting is not used.
    Is there some change I have to make to the configuration file/Bursting Control file to be able to use this pdf2ps utility to print to this Printer?
    Nevertheless I will also try using ipp on one of our newer printers...
    Thanks,
    Lavina

  • Issue with XML report printing on R12 instance

    Hi,
    I'm facing issue with printing xml reports on R12 instance and followed the note (How To Print XML Publisher PDF Reports Via The Concurrent Manager:metalink id:338990.1) and configured the pasta printer,still printer output is showing the junk charcters.
    Please let me know how to resolve the issue?.

    Hi Hussien,
    We are on 12.1.1 / 11g with AL32UTF8 character set, we have custom reports developed in BI publisher and some some migrated reported from earlier version.
    Both BI publisher based custom like PO/Invoice/Cheque Print & seeded reports like "Active users/responsibilites" are being generated successfuly in pdf output. when copied to desktop and printed it prints properly. But when trying to direct output to printer from concurrent request it is printng junk.
    I checked pasta configuration, all required ghostscripts tools are on the AIX box, am I missing anything in R12?
    Regards

  • Having issue with XML in CDATA tag

    Currently I am having a major issue that I've been dealing with for the last four days unsuccessfully.  I run a search against our data provider (lets say the term searched on is 'foobar').  We get back an XML document on our server along with a list of objects that has the start index of where the hit terms are found and the length from the start of the index (our data provider calculates all of this for us).  We then take that XML document in its exact state as it's given to us from our data provider and wrap it in a CDATA tag and put it into another XML document and pass that to our FLEX app.  The document looks something like this coming back from the server (we're using REST).  This is not the true original document as it was shortened for readability.
    <?xml version="1.0" encoding="UTF-8"?>
    <Document>
    <ID>123456</ID>
    <HITTERMS>
    <HITTERM index="45" length="6" />
    <HITTERM index="105" length="6" />
    <HITTERM index="260" length="6" />
    </HITTERMS>
    <DocumentXML><![CDATA[<?xml version="1.0" encoding="UTF-8"?>
    <DOC DOCUMENT_ID="123456" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <METADATA>
    <ID>123456</ID>
    <LANGUAGE>ENGLISH</LANGUAGE>
    <SOURCEDATA>1/1/2009</SOURCEDATA>
    <SOURCE>AP</SOURCE>
    </METADATA>
    <ARTICLE>
    <TITLE>Some title with foobar</TITLE>
    <TEXT>
    There would be just standard text.
    Some breaks for example like the start of new paragraphs, but otherwise all the foobar text would be condensed like this.
    </TEXT>
    </ARTICLE>
    </DOC>]]></DocumentXML>
    </Document>
    I've confirmed the XML coming from the server looks exactly as it does above. The issue is for some reason whenever I try to get the text out of '<DocumentXML>' it formats the code in a way that won't work for me since it throws off the offsets of the hit terms and changes the original document.  Whenever I do a .toString() on the XML it puts breaks before each '<' and after each '>' so it spaces everything out inside the CDATA tag.  Now the XML looks like this when turned into a string:
    <?xml version="1.0" encoding="UTF-8"?>
    <Document>
    <ID>123456</ID>
    <HITTERMS>
    <HITTERM index="45" length="6" />
    <HITTERM index="105" length="6" />
    <HITTERM index="260" length="6" />
    </HITTERMS>
    <DocumentXML><![CDATA[
    <?xml version="1.0" encoding="UTF-8"?>
    <DOC DOCUMENT_ID="123456" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <METADATA>
    <ID>123456</ID>
    <LANGUAGE>ENGLISH</LANGUAGE>
    <SOURCEDATA>1/1/2009</SOURCEDATA>
    <SOURCE>AP</SOURCE>
    </METADATA>
    <ARTICLE>
    <TITLE>Some title with foobar</TITLE>
    <TEXT>
    There would be just standard text.
    Some breaks for example like the start of new paragraphs, but otherwise all the foobar text would be condensed like this.
    </TEXT>
    </ARTICLE>
    </DOC>
    ]]>
    </DocumentXML>
    </Document>
    I need to be able to keep the original document as-is in the first example so I can calculate where the hit terms are so that I can highlight them and there are things further down the road that I'm going to need to be able to do so a simple search and replace will not get the job done unfortunately.  Has anyone ever encountered this before or have any idea possibly how to fix this.  Thanks in advance to anyone who can help with this.

    Didn't work.  Now it spaces out all of the XML, not just the document wrapped in the CDATA tag.  Looks like this now:
    <?xml version="1.0" encoding="UTF-8"?>
    <Document>
    <ID>123456</ID>
    <HITTERMS>
    <HITTERM index="45" length="6" />
    <HITTERM index="105" length="6" />
    <HITTERM index="260" length="6" />
    </HITTERMS>
    <DocumentXML>
    <![CDATA[<?xml version="1.0" encoding="UTF-8"?>
    <DOC DOCUMENT_ID="123456" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
    <METADATA>
    <ID>123456</ID>
    <LANGUAGE>ENGLISH</LANGUAGE>
    <SOURCEDATA>1/1/2009</SOURCEDATA>
    <SOURCE>AP</SOURCE>
    </METADATA>
    <ARTICLE>
    <TITLE>Some title with foobar</TITLE>
    <TEXT>
    There would be just standard text.
    Some breaks for example like the start of new paragraphs, but otherwise all the foobar text would be condensed like this.
    </TEXT>
    </ARTICLE>
    </DOC>
    ]]>
    </DocumentXML>
    </Document>

  • Issue with XML PDF and AdobeDesigner!

    Hello!<br />I have a PDF Document!<br />With Acrobat Proffesional Reader i can File -> Export Form Data (Hope this is right in english)<br /><br />A new XML File will be generated<br /><br />The conten of the File<br /><br /><?xml version="1.0" encoding="UTF-8" ?> <br />- <ichicsr lang=""><br />- <ichicsrmessageheader =""><br /><messagetype ="" /> <br /><mailrcpt ="">[email protected]</mailrcpt> <br /><mailbody ="">Test</mailbody> <br /><br />To this Point all works fine...<br /><br />but when i Load up the PDF File in AdobeDesigner, and save it up. (I do no changes at this Point, only Save the file.) and close<br /><br />And then i export second time the xml data with Acrobat Proffesional Reader <br /><br />the conten looks like this:<br /><br /><?xml version="1.0" encoding="UTF-8" ?> <br />- <ichicsr lang=""><br />- <ichicsrmessageheader lang=""><br /><messagetype lang="" /> <br /><mailrcpt lang="">[email protected]</mailrcpt> <br /><mailbody lang="">Test</mailbody> <br /><br />everywhere is written lang?!?!?!?!<br />WHY??? How can I eliminate this effect?!<br /><br />HELP and sorry for my bad english!

    Your XML processor should just ignore the tags it doesn't understand -
    no problem.
    It sounds as if you are trying to create a very simplified XML parser
    that looks for text patterns. I advise against this. There are many
    tools designed to parse XML and which will take care of the special
    issues. A simple text approach will collapse the first time someone
    types an ampersand "&" in their text...
    Aandi Inston

  • Issue with XML output

    Hi All,
    We have a XML report output which is sent to users email as a word and pdf attachment. I see that the word attachment which is being sent to the user has RTF extension. I tried to modify the file extension to docx and test it to see if that works. The email comes up with the docx extension but when I try to open the attachment it asks for encoding and no matter which encoding I choose the o/p doesn't display properly.
    Does anyone have an idea of how to overcome this issue so that I might be able to send the user the word o/p with docx or doc extension instead of RTF.
    Any suggestions are highly appreciated.
    Thanks!!

    Hi,
    Might be worth logging a SR on this.
    Regards,
    Gareth
    Blog: http://garethroberts.blogspot.com/

  • Issue with XML display.

    Hi,
    We have generated IDocs for Invoices and also dispatched it using RSEOUT00 program via an XML port. IDoc is getting generated and is being placed in the application server successfully. But, when we download XML to the local drive and open, it does not display due to error in the header of the XML, which is currently '<?xml version = "1.0"?>'.
    We identified that this issue is due to missing character set encoding in the XML header and correct header format should be '<?xml version="1.0" encoding="ISO-8859-1" ?>'
    Can you please tell me how to incorporate this character set in the XML header by a particular setting in the configuration of the IDoc set up so that, our idocs are correctly converted into XMLs with this character set?
    Vishy.

    Use feature Find and Replace with abap syntax for example

  • Linear workflow issues with Media Encoder CC 2014

    I'm using After Effects CC 2014 and doesn't seem to be the option anymore to export via AE to H264. There used to be a button in the preferences to enable outdated codecs... not there anymore with CC 2014. So... I added my renders into Media Encoder. The problem is that it is not calculating my project working in Linear Workflow so all my renders are very dark & wrong colors.
    Anyone find a work around for this? is there a button in Media Encoder that I need to switch on for linear workflow?

    I've been validating in QT, but per your comment I opened up in VLC player as well. VLC player does playback the correct color. I attached SS of same lossless rendered video from AE open in AE, QT, VLC, and then the rendered H264 in QT & VLC  from AME in one screen shot. You can see that the H264 file from AME is always just a little bit off when opened in QT or Preview mode (OSX) or uploaded to Vimeo. The rendered H264 file is just the lossless file being encoded into H264 via AME.
    That's great that VLC player will playback the correct color, but when uploading to Vimeo, the color shifts as well during playback. I've never had this issue when rendering to H264 directly from AE before. I'm a little new to AME so I'm not sure if there is a setting I am missing or is there a limitation to the H264 codec where I've never noticed the slight color shift? Is there anyway to get a H264 file that will play back via Vimeo/QT without the color shift?

  • Issue with XML namespace and Message structure

    Hi All,
    I am using Oracle SOA Suite 11.1.1.4. I have SOA web service application one-way messaging wherein I keep receiving messages from the third party. The issue I am facing is with the XML namespaces which conflicts with the third party's message structure. The details are as below.
    Our Web-service WSDL*
    <schema attributeFormDefault="unqualified" elementFormDefault="qualified"
    targetNamespace="http://amb.com/cad/RealTimeService"
    xmlns:cad="http://amb.com/cad/RealTimeService"
    xmlns:avl="http://schemas.com/asiapac/cad/datamodel/avl/1.0.0"
    xmlns:evn="http://schemas.com/asiapac/cad/datamodel/event/1.0.0"
    xmlns:uni="http://schemas.com/asiapac/cad/datamodel/unit/1.0.0"
    xmlns:dvt="http://schemas.com/asiapac/cad/datamodel/divert/1.0.0"
    xmlns:sui="http://schemas.com/asiapac/cad/datamodel/suppinfo/1.0.0"
    xmlns="http://www.w3.org/2001/XMLSchema">
    <import namespace="http://schemas.com/cad/datamodel/avl/1.0.0"
    schemaLocation="AvlCadSchema.xsd"/>
    <import namespace="http://schemas.com/cad/datamodel/unit/1.0.0"
    schemaLocation="UnitCadSchema.xsd"/>
    <import namespace="http://schemas.com/cad/datamodel/event/1.0.0"
    schemaLocation="EventCadSchema.xsd"/>
    <import namespace="http://schemas.com/cad/datamodel/divert/1.0.0"
    schemaLocation="HewsCadSchema.xsd"/>
    <import namespace="http://schemas.com/cad/datamodel/suppinfo/1.0.0"
    schemaLocation="SupplementalInformationCadSchema.xsd"/>
    <element name="AvlAuxData" type="avl:AvlAuxData" nillable="true"/>
    <element name="AgencyEvent" type="evn:AgencyEvent"/>
    <element name="Diversion" type="dvt:HospitalDiversionMessage"/>
    <element name="SupplementalInformation" type="sui:SupplementalInformation"/>
    <element name="UnitDetail" type="uni:UnitDetail"/>
    </schema>
    Using SOAP UI tool a HospitalDiversionMessage Request for the above WSDL will look like*
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:real="http://amb.com/cad/RealTimeService" xmlns:ns="http://schemas.com/cad/datamodel/divert/1.0.0">
    <soapenv:Header/>
    <soapenv:Body>
    <*real*:Diversion>
    <ns:Action>?</ns:Action>
    <ns:Open>?</ns:Open>
    <!--Optional:-->
    <ns:Location>?</ns:Location>
    <ns:Type>?</ns:Type>
    <ns:SubType>?</ns:SubType>
    <!--Optional:-->
    <ns:ExpiryTimestamp>?</ns:ExpiryTimestamp>
    <!--Optional:-->
    <ns:Comment>?</ns:Comment>
    <!--Optional:-->
    <ns:ItemNumber>?</ns:ItemNumber>
    <!--Optional:-->
    <ns:Notifications>?</ns:Notifications>
    <ns:CreatedTerminal>?</ns:CreatedTerminal>
    <ns:CreatedTimestamp>?</ns:CreatedTimestamp>
    <!--Optional:-->
    <ns:ClosedBy>?</ns:ClosedBy>
    <!--Optional:-->
    <ns:ClosedComments>?</ns:ClosedComments>
    <!--Optional:-->
    <ns:ClosedTerminal>?</ns:ClosedTerminal>
    <!--Optional:-->
    <ns:ClosedTimestamp>?</ns:ClosedTimestamp>
    </real:Diversion>
    </soapenv:Body>
    </soapenv:Envelope>
    Now the third party sends a HospitalDiversionMessage in this format_
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns0="http://amb.com/cad/RealTimeService" xmlns:ns="http://schemas.com/cad/datamodel/divert/1.0.0">
    <soapenv:Header/>
    <soapenv:Body>
    <ns0:Diversion>
    <ns0:Action>?</ns0:Action>
    <ns0:Open>?</ns0:Open>
    <!--Optional:-->
    <ns0:Location>?</ns0:Location>
    <ns0:Type>?</ns0:Type>
    <ns0:SubType>?</ns0:SubType>
    <!--Optional:-->
    <ns0:ExpiryTimestamp>?</ns0:ExpiryTimestamp>
    <!--Optional:-->
    <ns0:Comment>?</ns0:Comment>
    <!--Optional:-->
    <ns0:ItemNumber>?</ns0:ItemNumber>
    <!--Optional:-->
    <ns0:Notifications>?</ns0:Notifications>
    <ns0:CreatedTerminal>?</ns0:CreatedTerminal>
    <ns0:CreatedTimestamp>?</ns0:CreatedTimestamp>
    <!--Optional:-->
    <ns0:ClosedBy>?</ns0:ClosedBy>
    <!--Optional:-->
    <ns0:ClosedComments>?</ns0:ClosedComments>
    <!--Optional:-->
    <ns0:ClosedTerminal>?</ns0:ClosedTerminal>
    <!--Optional:-->
    <ns0:ClosedTimestamp>?</ns0:ClosedTimestamp>
    </ns0:Diversion>
    </soapenv:Body>
    </soapenv:Envelope>
    Questions*
    1) I cannot figure out how the SOAPUI tool or SOA substitutes "real" as the namespace prefix for the WSDL based HospitalDiversionMessage and what I need to do at my end to match the message structure as per what the third party needs.
    2) I need ns0 namespace prefix to whole of Diversion xml element. Currently it is "real" at top Diversion element and "ns" for its children
    Please suggest, I can attach the other imported XSD if need be.
    Thanks
    Edited by: user5108636 on Jun 13, 2011 6:55 PM
    Edited by: user5108636 on Jun 13, 2011 6:57 PM
    Edited by: user5108636 on Jun 13, 2011 7:02 PM

    Questions
    1) I cannot figure out how the SOAPUI tool or SOA substitutes "real" as the namespace prefix for the WSDL based HospitalDiversionMessage and what I need to do at my end to match the message structure as per what the third party needs.The xml namespace suffixes like real and ns0 are just references used by the XML Parsers. For that matter the "real" can be xyz as well.
    You dont need to make any changes as long as the xml namespace suffixes refer to the same namespace.
    If you see the first soapUI xml and the third party xml have the same namespace references and hence it is not a problem:
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:real="*http://amb.com/cad/RealTimeService*" xmlns:ns="http://schemas.com/cad/datamodel/divert/1.0.0">
    <soapenv:Header/>
    <soapenv:Body>
    <*real*:Diversion>
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns0="*http://amb.com/cad/RealTimeService*" xmlns:ns="http://schemas.com/cad/datamodel/divert/1.0.0">
    <soapenv:Header/>
    <soapenv:Body>
    <*ns0*:Diversion>
    2) I need ns0 namespace prefix to whole of Diversion xml element. Currently it is "real" at top Diversion element and "ns" for its childrenBased on this, logically both the xmls represent the same xml message. And hence you dont need to make any changes.
    Please refer to the basics of xml namespaces using the following links:
    http://en.wikipedia.org/wiki/XML_namespace
    http://zvon.org/comp/r/tut-Namespace.html#Pages~Introduction
    Let us know if you still need clarification.
    Hope this helps.
    Thanks,
    Patrick

  • Issue with XML parsing

    Hey guys,
    Issue goes like this : I've got an XML which has a name space reference as shown below :
    <root>
         <node1>
            <*ns*:node2>test_data</ns:node2>
        </node1>
    </root>
    -- I'm using the functions in the XSL processor package to access the data under node2 :
      l_db_n :=
             DBMS_XSLPROCESSOR.selectSingleNode(l_n,
                                            'node1'                                       
             DBMS_XSLPROCESSOR.valueof (l_db_n,
                                        'node2/text()' ,
                                       l_node_value , 'xmlns:ns2="http://some-url.com"');the code fails if I include the namespace reference as shown above, can someone tell me where I'm going wrong ?
    Or if this is not the way to specify a namespace reference, pls let me know how to do it, help much appreciated.
    Thanks
    Edited by: user11382544 on Dec 17, 2009 11:47 PM

    Here's an example of extracting data from XML that has namespaces in it...
    SQL> ed
    Wrote file afiedt.buf
      1  WITH t as (select XMLTYPE('
      2  <RECSET xmlns:aa="http://www.w3.org">
      3    <aa:REC>
      4      <aa:COUNTRY>1</aa:COUNTRY>
      5      <aa:POINT>1800</aa:POINT>
      6      <aa:USER_INFO>
      7        <aa:USER_ID>1</aa:USER_ID>
      8        <aa:TARGET>28</aa:TARGET>
      9        <aa:STATE>6</aa:STATE>
    10        <aa:TASK>12</aa:TASK>
    11      </aa:USER_INFO>
    12      <aa:USER_INFO>
    13        <aa:USER_ID>5</aa:USER_ID>
    14        <aa:TARGET>19</aa:TARGET>
    15        <aa:STATE>1</aa:STATE>
    16        <aa:TASK>90</aa:TASK>
    17      </aa:USER_INFO>
    18    </aa:REC>
    19    <aa:REC>
    20      <aa:COUNTRY>2</aa:COUNTRY>
    21      <aa:POINT>2400</aa:POINT>
    22      <aa:USER_INFO>
    23        <aa:USER_ID>3</aa:USER_ID>
    24        <aa:TARGET>14</aa:TARGET>
    25        <aa:STATE>7</aa:STATE>
    26        <aa:TASK>5</aa:TASK>
    27      </aa:USER_INFO>
    28    </aa:REC>
    29  </RECSET>') as xml from dual)
    30  -- END OF TEST DATA
    31  select x.country, x.point, y.user_id, y.target, y.state, y.task
    32  from t
    33      ,XMLTABLE(XMLNAMESPACES('http://www.w3.org' as "aa"),
    34                '/RECSET/aa:REC'
    35                PASSING t.xml
    36                COLUMNS country NUMBER PATH '/aa:REC/aa:COUNTRY'
    37                       ,point   NUMBER PATH '/aa:REC/aa:POINT'
    38                       ,user_info XMLTYPE PATH '/aa:REC/*'
    39               ) x
    40      ,XMLTABLE(XMLNAMESPACES('http://www.w3.org' as "aa"),
    41                '/aa:USER_INFO'
    42                PASSING x.user_info
    43                COLUMNS user_id NUMBER PATH '/aa:USER_INFO/aa:USER_ID'
    44                       ,target  NUMBER PATH '/aa:USER_INFO/aa:TARGET'
    45                       ,state   NUMBER PATH '/aa:USER_INFO/aa:STATE'
    46                       ,task    NUMBER PATH '/aa:USER_INFO/aa:TASK'
    47*              ) y
    SQL> /
       COUNTRY      POINT    USER_ID     TARGET      STATE       TASK
             1       1800          1         28          6         12
             1       1800          5         19          1         90
             2       2400          3         14          7          5
    SQL>

  • SAP PI 7.31 / Sender SOAP Channel Issue with XML tag Main/@versionMajor has incorrect value 000; expected value is 003

    Hi PI Experts,
    We are on SAP PI 7.31 SP 10.
    We are in the process of integrating ARIBA P2P solution using SOAP Adapter as sender to connect Ariba with our PI system.
    We have configured all required components in ESR and ID(Most of them are content provided by Ariba).When we try to post a message into PI using SOAP UI we are ending with below error.

    http://<host name> : <port name> /XISOAPAdapter/MessageServlet?channel= <party name> : <service name> : <channel name>
    For the above issue we had configured SOAP Sender channel as above,and the URL we are using to hit PI is as above screenshot.
    We have followed the note on this topic with out any luck.
    1378872
    We are not sure where is problem.As the issue is not reaching to PI not able to see the messages in SXMB_MONI.
    and in the SXMB_ADM PI has been configured as Integration Server.
    I had even tried to change the message protocol as XI3.0 in SOAP sender channel and noluck.
    I have tried to ximessage=true query also in URL and noticed that not working.This is clear that the message we are trying to send from Ariba is not compatible with XI3.0 protocol,Ariba is not having any option to change at their end as it is a cloud application and many customers have been using same with out any issues.
    We have tried maintain the Java System properties in NWA as XPI.Adapter.Version.Major = 3 but no luck.
    Can some one provide us the solution to get rid of this issue?

  • Issue with XML nodes while Import

    Hi I am trying to import R3 data to MDM via XI. In my XML that generated from XI, has a separate nodes for main table and Qualifier Lookup tables. What happens is, in Import Manager, when a Qualifier Lookup table has only one record for a main table record, then those qualifier lookup table fields are displayed as main table elements. In that case my import MAP won't work for that Qualifier table. Any thoughts/advices?.
    Thanks
    Job.
    Edited by: Job C Daniel on Dec 21, 2007 8:00 AM

    Hi Amol,
      Thanks for your reply. My import map was created based on xml from XI( may be I should have used xsd?). I am using Products (partly customized from standard) repository. I have couple of issues.
    1. In the import manager when I opened the xml from XI, in source hiarchy tree table I see main table node and other QL(Qualifier Lookup) nodes for example Location Data and Sales Data. XI generates one XML for a record. Sometimes Sales Data QL node disappears (in import manager) because it has only one sales data record for that main table record and sales fields are populated as elements of main table node. This inconsistency is going to have problem on my Sales Data QL Map.
    2. Likewise, I do not see Material Number (Main table "Key") in Sales Data or Location Data (QL) nodes in IM. But I need that in order to load qualifier fields.
    Your help on this is appreciated.
    Thanks
    Job.

Maybe you are looking for