I think something like this will help:
<Item>{attribute Name {<a><![CDATA[zz]]></a>}}</Item>
Eric
Eric Bloch
Director, Community
MarkLogic Corporation
desk +1 650 655 2390 | mobile +1 650 339 0376
email [email protected]<mailto:[email protected]>
web developer.marklogic.com<http://developer.marklogic.com>
twitter @eedeebee
On Jul 26, 2013, at 6:55 AM, Mariano Grau Calín
<[email protected]<mailto:[email protected]>> wrote:
This code inserts the CDATA as a literal. I need insert CDATA as a node.
Un saludo,
Mariano Grau
mgrau @ grupojoly.com<http://grupojoly.com>
Dpto. Sistemas
Grupo Joly
________________________________
De: [email protected]<mailto:[email protected]>
[mailto:[email protected]<http://cognizant.com>]
Enviado el: viernes, 26 de julio de 2013 10:12
Para: [email protected]<mailto:[email protected]>;
Mariano Grau Calín
Asunto: RE: Diferences between 0.9-ml and 1.0-ml
Hi Mariano
Try this.
xquery version "1.0-ml";
xdmp:node-insert-child(doc('/resources/lists/editions.xml')/Root, <Item
Name="<![CDATA[zz]]>"/>)
Regards,
Asit Nautiyal
From:
[email protected]<mailto:[email protected]>
[mailto:[email protected]<mailto:[email protected]>]
On Behalf Of Mariano Grau Calín
Sent: Friday, July 26, 2013 1:07 PM
To: [email protected]<mailto:[email protected]>
Subject: [MarkLogic Dev General] Diferences between 0.9-ml and 1.0-ml
Hi,
I have a xquery code in 0.9-ml that works fine. However, i can not find how to
write in 1.0
xquery version '0.9-ml'
xdmp:node-insert-child(doc('/resources/lists/editions.xml')/Root, <Item
Name={<![CDATA[zz]]>}/>)
Ok
xquery version '1.0-ml';
xdmp:node-insert-child(doc('/resources/lists/editions.xml')/Root, <Item
Name={<![CDATA[zz]]>}/>)
[1.0-ml] XDMP-UNEXPECTED: (err:XPST0003) Unexpected token syntax error,
unexpected Junk_, expecting TagQName_
Regards,
Mariano Grau
mgrau @ grupojoly.com<http://grupojoly.com>
Dpto. Sistemas
Grupo Joly
This e-mail and any files transmitted with it are for the sole use of the
intended recipient(s) and may contain confidential and privileged information.
If you are not the intended recipient(s), please reply to the sender and
destroy all copies of the original message. Any unauthorized review, use,
disclosure, dissemination, forwarding, printing or copying of this email,
and/or any action taken in reliance on the contents of this e-mail is strictly
prohibited and may be unlawful. _______________________________________________
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