on 09-29-2011 12:05 PM
Hi all,
I have a PI scenario and I can find a solution.
The scenario is a ABAP PROXY that consume a WS, this is no problem, the problem is that the web service returns a string parameter, and inside the string parameter there is a XML structure.
My doubt is, how can mapping it to get the response in a structured data type instead of a string??
Thanks a lot
Raú
PI version is 7.1
The XML has a fixed structure.
Id like do it without JAVA mapping.
Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
If the element which contains the XML always the same, you can use a simple XSLT mapping.
Something like:
<?xml version="1.0" encoding="UTF-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">
<xsl:output indent="no" method="xml" encoding="UTF-8"/>
<!-- copy payload -->
<xsl:value-of select="//string"/>
</xsl:template>
</xsl:stylesheet>
You can use a second mapping step to trasnform the result of this mapping to the ABAP proxy message structure.
Hi ,
Is the return type is an XML structure? Then use java mapping using DOM parser to extract the string from response. Then the mapping program can generate the required target structure from the string.
you can if possible let the forum members know, the response xml message and the structure of target XML as per your requirement. Finally also the version of PI you are working is also important as java mapping procedure is different for PI7.0 and PI 7.1.
___________________________________________________________________________________________
As Stefan has pointed out without java mapping it will be almost impossible to extract the target XML from String. Still you can try out with XSLT mapping, but I don't think that will be easy task to do. Java mapping is the correct procedure to solve your problem. Finally forum members will be able to assist you if you provide complete source and target XML structure alog with sample string response. you can reuse java mapping code for multiple interfaces within same SWCV. The part or module which will be calling the common code with different input parameters will vary accross interfaces depending on your need.
_________________________________________________________________________________________________
regards
Anupam
Edited by: anupamsap on Sep 29, 2011 1:55 PM
Edited by: anupamsap on Sep 29, 2011 2:21 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
85 | |
10 | |
10 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.