You have an extra space. "<space>Anti Money ...



Sent from my iPad (excuse the terseness)
David A Lee
[email protected]<mailto:[email protected]>
812-630-7622


On Aug 9, 2013, at 10:39 AM, "Singh, Gurbeer" 
<[email protected]<mailto:[email protected]>> wrote:


We have a requirement in which we are asked to replace node value text [AML 
should be replace by MS & Anti money Laundering should be replace by Morgan 
Stanley], XML can contain multiple AML  , all AML should be replace. It’s not 
necessary AML will be in some specific element, I am also giving one sample 
structure

I am trying this approach, I am restricting myself for element ba, but in below 
sample  “Anti Money Laundering” is available in region element also.

If I am applying below query in versions element I am not getting any output, 
any thought


let $query:=
cts:and-query((cts:directory-query("/History/", "infinity"),
cts:element-value-query(xs:QName("ba")," Anti Money Laundering","exact")))
for $uri in cts:uris((), (), $query)
return
fn:doc($uri)




Our XML structure is
<versions>
<version id=”1”>
<title> Title 1</title>
<region>Global</region>
<bas>
<ba id=”AML”>Anti Money Laundering</ba>
<ba  id=”CD”>Compliance division</ba>
</bas>
…
..
<updatedby>abc</updatedby>
<updatedon>some date</updatedon>
</version>
<version id=”1”>
<title> AML </title>
<region> Anti Money Laundering </region>
<bas>
<ba id=”AML”>Anti Money Laundering</ba>
<ba  id=”CD”>Compliance division</ba>
</bas>
…
..
<updatedby>abc</updatedby>
<updatedon>some date</updatedon>
</version>
….
…
<version id=”4”>
<version id=”1”>
<title> Title 1</title>
<region>Global</region>
<bas>
<ba  id=”CD”>Compliance division</ba>
</bas>
…
..
<updatedby>abc</updatedby>
<updatedon>some date</updatedon>
</version>

</version>

</versions>


________________________________

NOTICE: Morgan Stanley is not acting as a municipal advisor and the opinions or 
views contained herein are not intended to be, and do not constitute, advice 
within the meaning of Section 975 of the Dodd-Frank Wall Street Reform and 
Consumer Protection Act. If you have received this communication in error, 
please destroy all electronic and paper copies and notify the sender 
immediately. Mistransmission is not intended to waive confidentiality or 
privilege. Morgan Stanley reserves the right, to the extent permitted under 
applicable law, to monitor electronic communications. This message is subject 
to terms available at the following link: 
http://www.morganstanley.com/disclaimers If you cannot access these links, 
please notify us by reply message and we will send the contents to you. By 
messaging with Morgan Stanley you consent to the foregoing.

_______________________________________________
General mailing list
[email protected]<mailto:[email protected]>
http://developer.marklogic.com/mailman/listinfo/general
_______________________________________________
General mailing list
[email protected]
http://developer.marklogic.com/mailman/listinfo/general

Reply via email to