
dls:document-retention-rules( $uri as xs:string ) as element(dls:retention-rule)*
This function returns a sequence of dls:retentionRule element nodes. This allows users to determine why a version of a document is being retained.
| Parameters | |
|---|---|
| uri | The URI of the document. The URI must identify a numbered version of a managed document or an error is thrown. | 
dls-user role is required to run 
    this function, or the privilege:http://marklogic.com/xdmp/privileges/dls-user
    
  xquery version "1.0-ml";
  import module namespace dls = "http://marklogic.com/xdmp/dls" 
      at "/MarkLogic/dls.xqy";
  dls:document-retention-rules("/foo/bar/baz.xml")
  (: Returns all of the retention rules that apply to the 'baz.xml' document. :)