CDATA problems with special characters
We have a 3rd party application that is returning the results within a CDATA string. I need to be able to get one of the tags in there (strQuoteNo) and then pass it for use in another request message but am having problems even getting at the tag.
I've searched all over and following the https://www.soapui.org/docs/functional-testing/working-with-cdata.html guide I have passed the whole CDATA string to a property.
declare namespace ns1='';
declare namespace rpc='http://www.w3.org/2003/05/soap-rpc';
declare namespace soap='http://www.w3.org/2003/05/soap-envelope';
declare namespace saxon='http://saxon.sf.net/' ;
//ns1:rootCreateQuoteResponse/text()
The result is:
<?xml version="1.0" encoding="UTF-8" standalone="yes"?><CreateQuoteResponse xmlns="webservices.quotation.company.com"><strQuoteNo>1234567</strQuoteNo><lngNoOfLives>13</lngNoOfLives><dblTotalBenefit>309033</dblTotalBenefit><dblFreeCoverLimit>65000</dblFreeCoverLimit><dteArd>2018-05-01</dteArd><DoclIst/><CommissionLevel><lngCommissionUnitVID>240</lngCommissionUnitVID><dblCommissionRate>12</dblCommissionRate><lngPremiumFrequencyVID>42</lngPremiumFrequencyVID><dblAnnualPremium>2696.14</dblAnnualPremium><dblModalPremium>224.6783</dblModalPremium><dblUnitRate>3.096</dblUnitRate></CommissionLevel></CreateQuoteResponse>
I think the problem is that this sting contains special characters as whatever I try next either results in 'null' or an error when trying to pass it to a new property.
Can anyone help advise here? Using the basic SoapUI rather than Pro, the idea is to then pass the quote number in to the next request message to issue the quote, which is also of CDATA format:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Header/>
<soapenv:Body>
<rootIssueQuoteRequest><![CDATA[<IssueQuoteRequest xmlns="webservices.quotation.company.com"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<Header>
<strQuoteNo>1234567</strQuoteNo>
<strUserId>ISSUEQUOTEUSER</strUserId>
</Header>
</IssueQuoteRequest>]]></rootIssueQuoteRequest>
</soapenv:Body>
</soapenv:Envelope>