Xml deserialization and namespace issue.
I have an xml file something like:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<NS1:NodeA xmlns:NS1="FooSpace">
<NS1:NodeB>
<NS1:NodeC>
<NS1:ElementA>text</NS1:ElementA>
</NS1:NodeC>
<NS1:NodeD>
<Attributes>
<Name>xxx</Name>
<Value>yyy</Value>
</Attributes>
<Attributes>
<Name>www</Name>
<Value>zzz</Value>
</Attributes>
</NS1:NodeD>
</NS1:NodeB>
</NS1:NodeA>
I can parse every thing upto the contents of NodeD. For the classes which expose elements (NodeA to NodeD), I decorate the properties as follows:
[XmlElement("property_name", Namespace = "FooSpace")]
The Attributes class has properties without the Namespace key.
Anyone know what I am missing?
Thanks!
I am glad to know you solved this problem and thanks for sharing the solution.
It will be very beneficial for other community members who have the similar questions.
We are trying to better understand customer views on social support experience, so your participation in this interview project would be greatly appreciated if you have time. Thanks for helping make community forums a great place.
Click
HERE to participate the survey.
Similar Messages
-
I´m using XML Publisher 5.5 with Template Builder. I have created an RTF document that works perfect with XML Publisher. I now want work more complicated with my template using XSL. I have through Template Builder created an XSL-FO style sheet.
I open the xsl-doc in XMLSPY, assinging an xml-doc and try to preview expecting the result to be the same as using Template Builder but the layout gets all messed up and I get an error that says that the namespace xmlns:xdofo="http://xmlns.oracle.com/oxp/fo/extensions" is invalid.
The complete start tag:
<xsl:stylesheet version="2.0"
xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
xmlns:fo="http://www.w3.org/1999/XSL/Format"
xmlns:ora="http://www.oracle.com/XSL/Transform/java/"
xmlns:xdofo="http://xmlns.oracle.com/oxp/fo/extensions"
xmlns:xdoxslt="http://www.oracle.com/XSL/Transform/java/oracle.apps.xdo.template.rtf.XSLTFunctions"
xmlns:xdoxliff="urn:oasis:names:tc:xliff:document:1.1">
Does anybody know where I should point my namespace or what I´m doing wrong?
Regards,
DanielI know what I can do in RTF and maybe it´s enough:
1. Ensure you are using both tabs of the help text, you can start in Status Bar and continue with Help Key.
2. You can also use multiple fields one after another.
3. If you fill all of that and need more space I would consider moving the function out into its own XSL template and register it as a sub template and reference it from your main template. This is especially useful if you are going to need the same function across multiple templates.
My problem was why I can´t use XSL-FO - XML in XMLSPY, have´nt anybody tried to go out of the WORD-RTF and code som XSL? Maybe it´s not possible and I have to use WORD-RTF.
/Daniel -
XML, Oracle and Namespaces
Do any of the current XML parsers support namespaces?
If not how can the idea of external DTD or schema be used
Will Oracle be supporting schemas
nullmartin Roberts (guest) wrote:
: Do any of the current XML parsers support namespaces?
: If not how can the idea of external DTD or schema be used
: Will Oracle be supporting schemas
Our current parsers support namespaces and will support schemas
once things settle down in that WG.
Oracle XML Team
http://technet.oracle.com
Oracle Technology Network
null -
Issue with parsing an xml document and namespaces
I am having an issue when parsing an xml document that includes a namespace.
Here is my xml:
<?xml version="1.0" encoding="utf-8"?>
<StatusFile xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" TxCnt="247" TxTotal="5756845.31" SourceId="3" xmlns="http://www.test.com/cig/payments/optimizer/status/2004/10/">
<Tx PmtId="350031" Amt="16739" TxSts="09" CustSts="04" ChkNum="10605770" />
<Tx PmtId="350990" Amt="31698.66" TxSts="09" CustSts="04" ChkNum="10605821" />
<Tx PmtId="354992" Amt="201320.08" TxSts="09" CustSts="04" />
<Tx PmtId="349277" Amt="6675.17" TxSts="09" CustSts="04" ChkNum="10605822" />
<Tx PmtId="354979" Amt="66949.75" TxSts="09" CustSts="04" ChkNum="10605823" />
<Tx PmtId="349341" Amt="63258.49" TxSts="09" CustSts="04" ChkNum="10605824" />
<Tx PmtId="350025" Amt="5866.04" TxSts="09" CustSts="04" ChkNum="10605830" />
<Tx PmtId="350024" Amt="15671.8" TxSts="09" CustSts="04" ChkNum="10605831" />
<Tx PmtId="346822" Amt="9880.64" TxSts="09" CustSts="04" />
<Tx PmtId="350023" Amt="1360" TxSts="09" CustSts="04" />
<Tx PmtId="349802" Amt="131267" TxSts="09" CustSts="04" ChkNum="10605832" />
<Tx PmtId="343573" Amt="14532.76" TxSts="09" CustSts="04" ChkNum="10605833" />
<Tx PmtId="352675" Amt="4436" TxSts="09" CustSts="04" />
<Tx PmtId="350022" Amt="1260" TxSts="09" CustSts="04" ChkNum="10605834" />
<Tx PmtId="349714" Amt="80778" TxSts="09" CustSts="04" ChkNum="10605835" />
<Tx PmtId="352676" Amt="10136" TxSts="09" CustSts="04" ChkNum="10605836" />
<Tx PmtId="352679" Amt="25511.69" TxSts="09" CustSts="04" ChkNum="10605837" />
<Tx PmtId="346502" Amt="12842.69" TxSts="10" CustSts="05" />
<Tx PmtId="346503" Amt="4232.61" TxSts="09" CustSts="04" ChkNum="10605838" />
</StatusFile>
Here is my current code base:
CREATE OR REPLACE PROCEDURE ParseXML(xml VARCHAR2) IS
myParser xmlparser.parser := xmlparser.newparser;
myDoc xmldom.DOMNode;
myNodes xmldom.DOMNodeList;
myElement xmldom.DOMElement;
trec NDE_CIG_STATUS_TRANSACTIONS%ROWTYPE;
BEGIN
xmlparser.parseBuffer(myParser,xml);
myDoc := xmldom.makeNode(xmlparser.getDocument(myParser));
myNodes := xslprocessor.selectNodes(myDoc,'//Tx');
FOR i IN 0..xmldom.getLength(myNodes)-1 LOOP
myElement := xmldom.makeElement(xmldom.item(buyOrders,i));
trec.pmt_id := xmldom.getAttribute(curBuy,'PmtId');
INSERT INTO NDE_CIG_STATUS_TRANSACTIONS(PMT_ID) VALUES (trec.pmt_id);
END LOOP;
COMMIT;
END ParseXML;
If I remove the namespace, everything works just fine. The issue is that I cannot remove the namespace.
Anyone have any suggestions on how I can get the xslprocessor.selectNodes to recognize my namespace?
Thanks,
Mark MoranEveryone,
Well after lots of hours spent reading web pages and blogs, etc... I was able to re-write my procedure and get it to work with different calls.
Here is my updated code.
PROCEDURE PARSE_STATUS_XML(P_FILE_NAME IN VARCHAR2, P_XML_FILE IN CLOB) IS
V_PARSER XMLPARSER.PARSER := XMLPARSER.NEWPARSER;
V_DOCUMENT XMLDOM.DOMDOCUMENT;
V_NODES XMLDOM.DOMNODELIST;
V_ELEMENT XMLDOM.DOMELEMENT;
V_TBL_RECORD NDE_CIG_STATUS_TRANSACTIONS%ROWTYPE;
BEGIN
XMLPARSER.PARSECLOB(V_PARSER, P_XML_FILE);
V_DOCUMENT := XMLPARSER.GETDOCUMENT(V_PARSER);
V_ELEMENT := XMLDOM.GETDOCUMENTELEMENT(V_DOCUMENT);
V_NODES := XMLDOM.GETELEMENTSBYTAGNAME(V_ELEMENT,'Tx','http://www.test.com/cig/payments/optimizer/status/2004/10/');
FOR I IN 0..XMLDOM.GETLENGTH(V_NODES)-1 LOOP
V_ELEMENT := XMLDOM.MAKEELEMENT(XMLDOM.ITEM(V_NODES,I));
V_TBL_RECORD.PMT_ID := XMLDOM.GETATTRIBUTE(V_ELEMENT,'PmtId');
V_TBL_RECORD.PMT_AMT := XMLDOM.GETATTRIBUTE(V_ELEMENT,'Amt');
V_TBL_RECORD.E_STATUS_CODE := XMLDOM.GETATTRIBUTE(V_ELEMENT,'TxSts');
V_TBL_RECORD.E_REASON_CODE := XMLDOM.GETATTRIBUTE(V_ELEMENT,'StsRsn');
V_TBL_RECORD.E_CUSTOMER_STATUS_CODE := XMLDOM.GETATTRIBUTE(V_ELEMENT,'CustSts');
V_TBL_RECORD.UPS_TRACKING_NBR := XMLDOM.GETATTRIBUTE(V_ELEMENT,'UpsTrcNum');
V_TBL_RECORD.FED_REFERENCE_NBR := XMLDOM.GETATTRIBUTE(V_ELEMENT,'FedRefNum');
V_TBL_RECORD.FIDB_TRACKING_NBR := XMLDOM.GETATTRIBUTE(V_ELEMENT,'FIDbtTrcNum');
V_TBL_RECORD.CHECK_NBR := XMLDOM.GETATTRIBUTE(V_ELEMENT,'ChkNum');
INSERT INTO NDE_CIG_STATUS_TRANSACTIONS(
CREATE_DATE,
XML_FILE_NAME,
PMT_ID,
PMT_AMT,
E_STATUS_CODE,
E_REASON_CODE,
E_CUSTOMER_STATUS_CODE,
UPS_TRACKING_NBR,
FED_REFERENCE_NBR,
FIDB_TRACKING_NBR,
CHECK_NBR
VALUES (
SYSDATE,
P_FILE_NAME,
V_TBL_RECORD.PMT_ID,
V_TBL_RECORD.PMT_AMT,
V_TBL_RECORD.E_STATUS_CODE,
V_TBL_RECORD.E_REASON_CODE,
V_TBL_RECORD.E_CUSTOMER_STATUS_CODE,
V_TBL_RECORD.UPS_TRACKING_NBR,
V_TBL_RECORD.FED_REFERENCE_NBR,
V_TBL_RECORD.FIDB_TRACKING_NBR,
V_TBL_RECORD.CHECK_NBR
END LOOP;
COMMIT;
EXCEPTION
WHEN OTHERS THEN
RAISE;
END PARSE_STATUS_XML;
Mark -
XSLT Mapping and Namespace Issues
I have been reading through similar threads on this topic, but have not found the right combination for my problem. I am doing an XSLT map and it works fine in Stylus Studio. When I take it to PI, I get a "Prefix 'ns0' is not mapped to a namespace" error. I have a namespace that is within the XSD files I received from my partner (http://www.ups.com/XMLSchema/EBR/Billing/v1). I also have the namespace I made in PI for the source (http://graybar.com/upsbilling/) and a different namespace in PI for the destination (http://graybar.com/cold/invoice/).
<u><b>XSLT:</b></u>
<?xml version='1.0' encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:ns0="http://www.ups.com/XMLSchema/EBR/Billing/v1" xmlns:ns1="http://graybar.com/cold/invoice/">
<xsl:template match="/">
<ns1:ColdInvoiceData>
<Header>
<RecordID>HDR</RecordID>
<InvoiceDate>
<xsl:value-of select="ns0:UPS_EBR_BILL/ns0:InvoiceDetails/ns0:Invoice/ns0:InvoiceDateCCYYMMDD"/>
</InvoiceDate>
<u><b>Source XML</b></u>
<?xml version="1.0" encoding="ISO-8859-1" ?>
<UPS_EBR_BILL xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.ups.com/XMLSchema/EBR/Billing/v1" xsi:schemaLocation="http://www.ups.com/XMLSchema/EBR/Billing/v1 Billing_XML_Schema.xsd">
<XMLBillFileVersion>1.0.1</XMLBillFileVersion>
<Recipient>
When I change the XSLT namespace from http://www.ups.com/XMLSchema/EBR/Billing/v1 to http://graybar.com/upsbilling/, the TransfromerException in PI goes away, but none of my referenced mappings work either (just my text hardcodes).
Can someone tell me why this works in Stylus Studio, but not in PI? Do I have too many namespaces?
Message was edited by:
Keith Wendel (to uncomment xsl:stylesheet line)> <ns1:ColdInvoiceData xmlns:ns1="http://graybar.com/cold/invoice/">
This change did not affect anything. Still works in Stylus Studio though.
Did you mean to show any changes at the <xsl:value-of select> line? I did not notice anything there.
Can anyone explain what "not mapped to a namespace" means? I have the declaration of ns0 at the top, so I don't see what else needs to be mapped. Do I have to have my PI namespace where I store the partner's XSDs set as "http://www.ups.com/XMLSchema..." (partner's namespace)? -
Embedding HTML in XML CDATA and encoding issues
Hi all,
I'm embedding HTML code in a CDATA section. My problem is that, depending on the document, the HTML can be encoded in many formats. I borrowed a piece of code that sniffs that format so i can create String in the "right" encoding (or at least the one that was guessed).
- If I directly injected those in the CDATA section, i guess they'd be encoded in UTF-8 and some character would be misinterpreted?
- What if i would transcode the HTML from the sniffed format to utf-8?
-Are there any issues woth doing this?
Sorry if this is a dumb question but I'm quite new to that kind of encoding issues.
BTW i'm using DOM.
Thanks
lexoI don't know if it's a dumb question. I just don't understand it at all. Encoding issues only arise when you write data from a Java program to an external location, or when you read data from an external location into a Java program. And none of the activities you mentioned there have anything to do with that.
When you write your XML to an external file, or wherever you write it to, it gets encoded at that moment. The whole thing. Elements, attributes, CDATA sections, the whole thing. Doesn't matter what's in it, the whole thing gets encoded in whatever charset was chosen.
Does that help? -
JSP Documents (JSP pages in XML format) and Namespaces
I have 1 set of XSLT stylesheets that takes XML and outputs JSP documents.
This 1 set of XSLT supports numerous clients (customers).
I have a new customer that uses a new namespace, let's call it "xyz".
This namespace is the TLD for xyz custom tags.
So, it would look something like this in the resulting jsp:root tag --> xmlns:xyz = "/xyzTagLib".
Where /xyzTagLib has a corresponding entry in web.xml that points to the xyz.tld that is delivered in WEB-INF/TLD.
However, most customers do not have the xyz application installed.
Thus, I added the exclude-namespace-prefixes="xyz" in the xsl:stylesheet tag to conditionally add the xmlns:xyz only if an xyz tag exists. However, this does not add it to the jsp:root tag, but only to each individual xyz tag in the resulting document.
However, the resulting JSP does not work in the runtime environment because it does not recognize the xyz tags.
Is there a known bug with jsp documents declaring namespaces "in line" instead of at the jsp:root level? Is there a way around this?
Thanks,
BrianHi Tridib,
the XML content is stored in the .xml file. You'll have to access it in a way that doesn't cause the XML-to-HTML transformation to take a peek at the format. You could probably do this by accessing the repository in question via WebDAV. If you're on a later SP, you should be able to go to /irj/go/km/docs/ in your browser to access the repository via WebDAV. Otherwise, take a look in the details pane of the folder that contains the .xml file in question. Under properties, there'll be a URL to access the folder via WebDAV. -
XML deserialize and decrypting encoding problem. Please help me
This is my first topic here, so at first I'd like to say "Hi" everyone and apologise for my bad english ;)
I have just finished my new application about signing/checking and encrypting/decrypting XML files. I use Apache XML Security packages to do this.
Everything works fine, instead of one...
I'm Polish and sometimes I have to encrypt or decrypt XML which includes polish letters like: 'ą' , 'ę', 'ł' and some others... If I encrypt such file, it succeeds. The problem is when I try to decrypt such an encrypted file. I recieve an error like :
"[Fatal Error] :2:7: An invalid XML character (Unicode: 0x19) was found in the element content o
f the document.
gov.mf.common.exceptions.SenderException: E_SENDER_DECRYPTION
at gov.mf.common.xml.encryption.EncryptTool.decrypt(Unknown Source)
at gov.mf.CERBER.TestCBR.main(Unknown Source)
Caused by: org.apache.xml.security.encryption.XMLEncryptionException: An invalid XML character
(Unicode: 0x19) was found in the element content of the document.
Original Exception was org.xml.sax.SAXParseException: An invalid XML character (Unicode: 0x19)
was found in the element content of the document.
at org.apache.xml.security.encryption.XMLCipher$Serializer.deserialize(Unknown Source)
at org.apache.xml.security.encryption.XMLCipher.decryptElement(Unknown Source)
at org.apache.xml.security.encryption.XMLCipher.doFinal(Unknown Source)
... 2 more
What's wrong? My XML document is UTF-8 encoded, with or without BOM. I wrote in in Notepad++ or any other editior which has UTF-8 encoding.
I'm parsing my XML with DOM. There is an interesting line in an error above like: " at org.apache.xml.security.encryption.XMLCipher$Serializer.deserialize(Unknown Source)" , do you know that?
Everything is fine when I try to encrypt/decrypt '�' or 'ń', but things go wrong with 'ą', 'ę', 'ł' and others... I also managed to encrypt and decrypt 'ł' but unfortunately, after decryption 'ł' turns into 'B'. It obviously an encoding problem, but how to fix it?
I would be really thankfull if some of You guys would help me.
Looking forward fo any answers.
Matthew
Message was edited by:
matthew_plHi once again.
I still don't havy any solution to my problem. I used Apache XML Security examples to encrypt/decrypt my XML document with Polish charaters but I also recieve the same error. What's wrong?
Here is some code:
----- Parsing XML do Document ------
DocumentBuilderFactory factory = DocumentBuilderFactory.newInstance();
//Bardzo wazna linijka - bless TEK ;)
factory.setNamespaceAware(true);
DocumentBuilder builder;
builder = factory.newDocumentBuilder();
File f = new File(Const.FILE_IN_PATH + File.separator + Const.FILE_IN);
org.w3c.dom.Document doc = builder.parse(f);
---------- Encrypting & Decrypting XML document (whole class) -------------
import java.io.*;
import java.security.*;
import javax.crypto.SecretKey;
import javax.crypto.SecretKeyFactory;
import javax.crypto.spec.DESedeKeySpec;
import org.w3c.dom.Document;
import org.w3c.dom.Element;
import org.apache.xml.security.keys.KeyInfo;
import org.apache.xml.security.utils.EncryptionConstants;
import org.apache.xml.security.encryption.XMLCipher;
import org.apache.xml.security.encryption.EncryptedData;
import org.apache.xml.security.encryption.EncryptedKey;
public class EncryptTool
private PublicKey publicKey;
private PrivateKey privateKey;
static
org.apache.xml.security.Init.init();
public EncryptTool()
publicKey = KeyStores.getCerberPublicKey();
privateKey = KeyStores.getCerberPrivateKey();
public Document encrypt(Document doc, String sufix)
try
byte[] passPhrase = "24 Bytes per DESede key!".getBytes("UTF-8");
DESedeKeySpec keySpec = new DESedeKeySpec(passPhrase);
SecretKeyFactory keyFactory = SecretKeyFactory.getInstance("DESede");
SecretKey secretKey = keyFactory.generateSecret(keySpec);
XMLCipher keyCipher = XMLCipher.getInstance(XMLCipher.RSA_v1dot5);
keyCipher.init(XMLCipher.WRAP_MODE, publicKey);
EncryptedKey encryptedKey = keyCipher.encryptKey(doc, secretKey);
Element elementToEncrypt = (Element) doc.getDocumentElement();
System.out.println("Szyrfuję: " + elementToEncrypt.getTextContent());
XMLCipher xmlCipher = XMLCipher.getInstance(XMLCipher.TRIPLEDES);
xmlCipher.init(XMLCipher.ENCRYPT_MODE, secretKey);
EncryptedData encryptedDataElement = xmlCipher.getEncryptedData();
KeyInfo keyInfo = new KeyInfo(doc);
keyInfo.add(encryptedKey);
encryptedDataElement.setKeyInfo(keyInfo);
boolean encryptContentsOnly = true;
xmlCipher.doFinal(doc, elementToEncrypt, encryptContentsOnly);
// output the resulting document
String [] parts = Const.FILE_IN.split("\\.");
String saveAs = Const.FILE_OUT_PATH + File.separator + parts[0] + sufix + "." + parts[1];
OutputStream os = new FileOutputStream(saveAs);
XMLUtil.sameXMLtoFile(doc, os);
} catch (Exception ex)
throw new TestCBRException("E_CERBER_ENCRYPTION", ex);
return doc;
public void decrypt(Document doc, String sufix) throws SenderException
try
String namespaceURI = EncryptionConstants.EncryptionSpecNS;
String localName = EncryptionConstants._TAG_ENCRYPTEDDATA;
int ile = doc.getElementsByTagNameNS(namespaceURI, localName).getLength();
if (ile == 0) throw new SenderException("E_SENDER_DECRYPTION_NEEDED");
for(int i=0; i < ile; i++)
Element encryptedDataElement = (Element) doc.getElementsByTagNameNS(namespaceURI, localName).item(0);
XMLCipher xmlCipher = XMLCipher.getInstance();
xmlCipher.init(XMLCipher.DECRYPT_MODE, null);
xmlCipher.setKEK(privateKey);
xmlCipher.doFinal(doc, encryptedDataElement);
String [] parts = Const.FILE_IN.split("\\.");
String saveAs = Const.FILE_OUT_PATH + parts[0] + sufix + "." + parts[1];
OutputStream os = new FileOutputStream(saveAs);
XMLUtil.saveXMLtoFile(doc, os);
} catch (SenderException ex) {
throw ex;
} catch (Exception ex) {
throw new SenderException("E_SENDER_DECRYPTION", ex);
Please help me. I'm going into madness what's wrong with it... -
I am trying to send an XML event to BPM. The XML's root node has a namespace associated
with it (for example, <bea:Employee>) where "bea" is defined as a namespace in
the top of the document. It looks like BPM does not support namespaces in start
nodes or event nodes. Is there any way to indicate in my workflow that the incoming
document will use a namespace?Doug
As you have pointed out Namespaces are not supported at this point
Tony
"Doug Haas" <[email protected]> wrote in message
news:3c90b4a3$[email protected]..
>
I am trying to send an XML event to BPM. The XML's root node has anamespace associated
with it (for example, <bea:Employee>) where "bea" is defined as anamespace in
the top of the document. It looks like BPM does not support namespaces instart
nodes or event nodes. Is there any way to indicate in my workflow thatthe incoming
document will use a namespace? -
XML Parser for PL/SQL and related issues
I need to have further information about some of the following
issues and XML features and make a determination useful for
evaluation and recommendation:
ISSUES
1) Is there a maximum size for an XML document to provide data
for PL/SQL(or SQL) across tables, provided that no CLOB are used?
2) How about from Oracle to an XML document ?
3) Is there a ratio between XML document size and main memory and
SGA size. What are Oracle's recommendations /
4) Can the Oracle Application Server run on a DHCP NT server when
using XML parsing ? Is it NT Service Pack 3 and 4 compatible ?
5) How parsers can interact with one another or related tools ?
For example, how the XML parser for c/c++ could be useful when
using Pro*C/C++ (programmer 2000) or OCI interfaces ? In other
words, what is the business logic in using these tools ?
nullAnthony D. Noriega (guest) wrote:
: I need to have further information about some of the following
: issues and XML features and make a determination useful for
: evaluation and recommendation:
: ISSUES
: 1) Is there a maximum size for an XML document to provide data
: for PL/SQL(or SQL) across tables, provided that no CLOB are
used?
The limit should be what can be inserted into an object view.
: 2) How about from Oracle to an XML document ?
The limit should be what can be retrieved from an object view.
: 3) Is there a ratio between XML document size and main memory
:and SGA size. What are Oracle's recommendations /
Not directly due to the relationship between XML metadata and
data not being constrained.
: 4) Can the Oracle Application Server run on a DHCP NT server
: when using XML parsing ?
If it can run a JavaVM with the correct permissions there are no
other special requirements.
:Is it NT Service Pack 3 and 4 compatible ?
No special requirements here.
: 5) How parsers can interact with one another or related tools ?
: For example, how the XML parser for c/c++ could be useful when
: using Pro*C/C++ (programmer 2000) or OCI interfaces ? In
other
: words, what is the business logic in using these tools ?
Not really sure of your question. The XML components are useful
in any application where I am processing documents or data with
an XML structure. The choice to use XML can be based on quite a
range of requirements due to its declarative syntax and open
standards. If you give me a specific application, I can perhaps
be more helpful.
Oracle XML Team
http://technet.oracle.com
Oracle Technology Network
null -
Deleting Message Type name and namespace tag from XML payload
Hi Gurus,
Need help. My payload looks like this
<?xml version="1.0" encoding="utf-8" ?>
- <ns1:MT_O_sss xmlns:ns1="http://sap.com/xi/tm">
- <Job>
<Field name="xxxx" value="" />
<Field name="xxx" value="" />
<Field name="xxx" value="" />
</Job>
</ns1:MT_O_sss>
But The soap webservice is expecting it in
<?xml version="1.0" encoding="utf-8" ?>
- <Job>
<Field name="xxxx" value="" />
<Field name="xxx" value="" />
<Field name="xxx" value="" />
</Job>
I have to remove the message type name and namespace tag.
So how can I achieve this. I am sending this payload using a Receiver Soap Adapter. Please help. I am kind of stuck.hi,
you have to simply add one module in your communication channel
that is XMLAnonymizerBean
you can refer below for help:
Remove namespace prefix or change XML encoding with the XMLAnonymizerBean
http://help.sap.com/saphelp_nw04/helpdata/en/2e/bf37423cf7ab04e10000000a1550b0/frameset.htm
hope it helps.
regards,
ujjwal kumar -
Soap sender adpater issue missing sender interface and namespace in the msg
Hi Expert,
I got a problem when try to using soap sender adapter.
Here is the sceanrio:
Http web service client call ---PI soap sender adapter -some routing data-business system inbound.
Sytem information:
SAP_ABA 700 0019 SAPKA70019 Cross-Application Component
SAP_BASIS 700 0019 SAPKB70019 SAP Basis Component
PI_BASIS 2005_1_700 0019 SAPKIPYJ7J PI_BASIS 2005_1_700
ST-PI 2008_1_700 0001 SAPKITLRD1 SAP Solution Tools Plug-In
SAP_BW 700 0021 SAPKW70021 SAP NetWeaver BI 7.0
ST-A/PI 01L_BCO700 0000 - Servicetools for other App./Netweaver 04
Here is my problem. I use soapui trigger a test msg to PI system. But in the sxmb_moni, only sender service is there.
The sender interface and sender namespace is missing. And the msg has error called: :INTERFACE_REGISTRATION_ERROR.
Which means I do not have a inbound interface to process the msg.
But I suppose to redirect the msg to business system.
Here is the configuration:
reciever determination: soap sender service, soap outbound interface, soap interface namespace --> reciever business sytem.
Interface ditermination: soap sender service, soap interface --> receiver interface, receiver namespace.
Sender agreement: soap service, soap itnerface --- soap communication channel
receiver agreement, soap service---> receiver sevice, receiver interface, reciever namespace and reciever cummunication channel
define of soap sender adapter:
soap sernder, with use encoded header and use query string checked and qos as exactly once.
Anyone has any idea here? Many thanks! And most strange thing is yesterday it works and today it failed.
Please kindly help here.
Thanks a lot,
LeonHi guys,
thanks for the input.
Hi Sven,
I have input default interface and namespace.
Hi sivasakthi,
Regarding mistype, it may happen, I will do it again right away.
And the URL is generated by the wsdl toolkit in the directory.
I marked use encoded header and query string in the communication channel.
I will generate the wsdl again and test it again.
Regarding URL(endpoint of web service):
http://hostname:50000/XISOAPAdapter/MessageServlet?channel=:AGSSAL_SOAP:AGSSAL_SOAP_CC&version=3.0&Sender.Service=AGSSAL_SOAP&Interface=urn:a1s_saplivelinkcontent.service.sap.com^MI_O_AS_DELIVERNOTIFY_SOAP
Again thanks for you guys help.
Best regards,
Leon -
XML Unnesting and In Memory issue
I have a source table in oracle that contains a column (Nclob) that have XML messages and my target is BW data souce
I build my job like that
Source Table------Quey1 (to convert to varchar)-------------Query2(Unnest XML using extract_xml)-----------------BW Target
I successfully running the job with small test data in source (About 100,000 records) takes about 30 minutes
But when I running with the actual table contains about 140000000 it takes so long time my be more than 12 hours and never ending and it is affect the job server so I decide to kill the job
I checked the log I found that the job running in im memory mode instead of peagable because it is nested schema
I need help to enhance this job and let running successfullyDo you mean that I need to remove Query transform that do extract_xml from the column and instead of it use XML_Pipeline?
I tried but I found XML_pipeline only accept files not database -
Issues with XML Content and Actions to import RRA in FPN (EP7 SPS13)
Hi,
I am having trouble using the import functionality of XML Content and Actions to transport Remote Role Assignments between Consumer Portals. Whenever I want to upload an XML file containing RRA for Roles and Groups that were already assigned to eachother, the import fails and nothing is updated. The error I get:
UMException. Data could not commit to Role: gp:/[full ID of portal role]
Anyone with experience in how to use this?
Kind regards,
Christian Staalbyhi,
@Maksim :
When user launch an URL like http://myserver:port/irj/portal/ import/*filename=C:\test.xml, he is requested to provide username and password; as this link is a shortcut for the upload xml page, there is a check of authorization and only portal admin that have authorization and permission on this page/iview will be able to upload xml file through the URL. Hope this clarify.
@Kumar :
thank you for your answer. What a pity to not be able to pass parameter through standard portal page/iview particularly knowing that we can pass paramater through many kinds of iviews (transactional iview, url iview, VC iview...). I explored some option on file com.sap.portal.ivs.init.par but this was unsuccessful. However, thanks to this [link bellow|http://wiki.sdn.sap.com/wiki/display/Snippets/ComponenttouploadXMLfilewithPCD+objects], I was able to upload through URL the XML file.
The problem is that I can upload only XML file that are stored in the server not in the local user computer. My requirement is to be able to upload local XML file stored on user's computer.
If someone could provide and idea/solution, I would be very grateful.
Cheers -
I have an issue involving JSP documents (i.e. JSP pages that are
well-formed XML documents). I am using namespaces on children elements
of the <jsp:root> element, because my JSP page generates XML with
namespaces. The simple fragment below illustrates this:
<jsp:root xmlns:jsp="http://java.sun.com/JSP/Page"
version="1.2">
<d:document xmlns:d="http://example.org/xml/document">
<d:head>
<d:title>Example</d:title>
</d:head>
<d:body>
Some Text.
</d:body>
</d:document>
</jsp:root>
This example works with Tomcat 4 and Tomcat 5, but fails with WL
8.1. I get an error like this:
/example/my.jsp(20): no corresponding open tag for tag extension
close: //[ ; Line: 20]
probably occurred due to an error in /example/my.jsp line 20:
</d:document>
This seems to be a bug in the WebLogic JSP implementation. It should
be possible to generate XML documents containing namespaces. The JSP
1.2 spec is actually silent on this, but it says (JSP.5.2.2):
"the root is where namespace attributes of taglibs will be inserted.
All tag libraries used within the JSP document are represented in the
root element through additional xmlns attributes."
This to me implies that namespace declarations occurring elsewhere in
the document are not interpreted as tag libs and therefore should be
handled like regular tags.
Any help is appreciated.
-Erik
"Erik Bruchez" <[email protected]> wrote in message
news:[email protected]...
> Thanks Nagesh,
>
> In passing, looking at the latest JSP 2.0 spec, I found out that there
> may be an additional issue in the future, as the 2.0 spec allows for
> tag libraries namespace declarations everywhere in the document. How
> are you going to be able to generate XML documents with namespaces if
> every namespace is necessarily bound to a tag library? The spec does
> not seem to address this at all. I have emailed my feedback to the
> JSR, but it would be interesting to have the opinion of WebLogic
> developers on this.
>
> -Erik
As far as i can remember, this doesn't restrict the namespaces in themselves
i.e not attached to any taglibs. Given a namespace which is not resolved as
a taglib, it will be considered a standard namespace no? .. Am i missing
something. Also which section and which PFD version of the spec are you
looking at? It would be great if you can give a little more detail about the
issue so it can be fixed in the spec if possible..
I would also be interested in knowing how you are using the Jsp documents
(in xml format) in general. (since I'm trying to get an insight into the
various ways in which jsp Docs are being used by customers)
Nagesh
>
> Nagesh Susarla <[email protected]> wrote in message
news:<[email protected]>...
> > Hi Erik,
> >
> > Indeed this does look like a bug in the wls jsp container. Attributes
> > with ':' in them are not being lexed correctly. I've opened CR111972 to
> > track this issue, so please contact [email protected] for necessary
patches.
> >
> > thanks
> > Nagesh
> >
> > Erik Bruchez wrote:
> > > I have an issue involving JSP documents (i.e. JSP pages that are
> > > well-formed XML documents). I am using namespaces on children elements
> > > of the <jsp:root> element, because my JSP page generates XML with
> > > namespaces. The simple fragment below illustrates this:
> > >
> > > <jsp:root xmlns:jsp="http://java.sun.com/JSP/Page"
> > > version="1.2">
> > > <d:document xmlns:d="http://example.org/xml/document">
> > > <d:head>
> > > <d:title>Example</d:title>
> > > </d:head>
> > > <d:body>
> > > Some Text.
> > > </d:body>
> > > </d:document>
> > > </jsp:root>
> > >
> > > This example works with Tomcat 4 and Tomcat 5, but fails with WL
> > > 8.1. I get an error like this:
> > >
> > > /example/my.jsp(20): no corresponding open tag for tag extension
> > > close: //[ ; Line: 20]
> > > probably occurred due to an error in /example/my.jsp line 20:
> > > </d:document>
> > >
> > > This seems to be a bug in the WebLogic JSP implementation. It should
> > > be possible to generate XML documents containing namespaces. The JSP
> > > 1.2 spec is actually silent on this, but it says (JSP.5.2.2):
> > >
> > > "the root is where namespace attributes of taglibs will be inserted.
> > > All tag libraries used within the JSP document are represented in the
> > > root element through additional xmlns attributes."
> > >
> > > This to me implies that namespace declarations occurring elsewhere in
> > > the document are not interpreted as tag libs and therefore should be
> > > handled like regular tags.
> > >
> > > Any help is appreciated.
> > >
> > > -Erik
Maybe you are looking for
-
This is my first time asking a question. I'm guessing at what I need to do. I don't see steps to follow and so...here goes! I have used the original iPad, the second gen, and now bought the 3rd gen. I have had no trouble in downloading all my apps
-
Photoshop file will not save as jpg
I took a series of portraits from a session last week. We downloaded the images as jpgs and edited them in Photoshop. Then we converted the photoshop files into jpgs. All but two converted. Those two images had nothing different done with them. Same
-
Can I Change The Equalizer For All 3,000+ tunes in iTunes At Once?
I just discovered the equalizer option and I am hoping that there is a command to change the tunes all at once. HELPPPPPPPPPPPPPPPP!!!!!!!!!!! Dell Windows XP
-
All, I am trying to configure IPv6 IPSec (with tunnel protection mode) on a tunnel interface within a VRF, not the global routing table. I have searched google and found the following post in which a user is discussing a very similar situation. Nea
-
Gurus, I am confused here and do not know if this is the right place to post this question. I have built an XLF file in XCelsius which has 7-8 LiveOffice Connections which are getting data from the latest instances of my scheduled WebI Reports. The