
cts:valid-document-patch-path( $string as xs:string, [$map as map:map?] ) as xs:boolean
 Parses path expressions and resolves namespaces using the $map parameter.
 Returns true if the argument is permissible as a path for
 document PATCH.
  cts:valid-document-patch-path("/foo/bar[@baz = '1']")
  => true
  xquery version "1.0-ml";
  let $namespaces := map:map()
  let $_ := map:put($namespaces, "ns1", "http://example.org/myns")
  return cts:valid-document-patch-path("/ns1:foo/ns1:bar[@baz = '1']",$namespaces)
  => true
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.