[MarkLogic Dev General] general serialization of cts

Paul M pjmaip at yahoo.com
Thu Sep 24 13:28:40 PDT 2009


let $dc as element() := <fff>123</fff>
let $dc-q := <outside-tag>{xdmp:quote($c)}</outside-tag>
let $dc-qt := $dc-q/text()
let $dc-uq  as element():= xdmp:unquote($dc-qt,"","format-xml")/node()

let $cts-e  as cts:query := cts:word-query("tilt", ("lang=en"), 1)
let $cts-e-q := <outside-tag>{xdmp:quote($cts-e)}</outside-tag>
let $cts-e-qt := $cts-e-q/text()
let $dc-uq  as cts:query:= xdmp:unquote($cts-e-qt,"","format-xml")/node() cast as cts:query (:this does not work:)


return $cts-e-q

The $dc-uq stmt does not work. Cast exception. I am attempting to create general method to serialize any cts:query without using lib parser. Even possible? xdmp:quote works on any item,correct?




      
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://xqzone.marklogic.com/pipermail/general/attachments/20090924/fe101b9d/attachment.html


More information about the General mailing list