xdmp:pretty-print

xdmp:pretty-print(
   $xquery as xs:string
) as xs:string

Summary

Returns a well-formatted XQuery module.

Parameters
xquery An XQuery module to be reformatted.

Example

xdmp:pretty-print("for $x in 1 to 10 return $x")
=> "for $x in 1 to 10
    return $x"
Powered by MarkLogic Server | Terms of Use | Privacy Policy