on 07-30-2009 10:16 AM
Hi,
I have the following block of XML returned from a web service when tested using SOAP UI:
<roomaddress>1 Esther Court
Richardson Street
Room 2 Flat 01B
Newcastle upon Tyne
NE1 2AG</roomaddress>
The data is returned with line breaks which I would like to use to format the data in the onward processing (ABAP proxy).
I've defined the element <roomaddress> as type string but this shows the data in the following format (line breaks have been replaced with spaces) in SAP PI:
<roomaddress>FRR01A1 Esther Campbell Court Richardson Road Room 1 Flat 01A Newcastle upon Tyne NE2 4AG</roomaddress>
What must I do to retain the line breaks? - the documentation for this field states it is a multiline string but unfortunately the WSDL doesn't describe the data to the level of this field hence I'm unsure how to handle.
Thanks,
Alan
Hi,
Try this
<roomaddress xml:spac = 'preserve'>
Regards
Suraj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
this is an example of hw line breaks are used and normalized by parsers. So I guess you need to adjust the WSDL or alternatively the XSD of your destination message type to use \n
Example:
<?xml version="1.0"?> \n
<Test> \n
<para xml:space="preserve">This is a \n
simple paragraph. What \n
do you think of it?</para> \n
</Test> \n
Cheers,
Kai
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
96 | |
11 | |
11 | |
10 | |
9 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.