dls.documentVersionUri( document-uri as String, version as Number ) as String
This function returns the URI of the specified version of the document located at the specified URI. The specified version of the document may, or may not, actually exist.
Parameters | |
---|---|
document-uri | The URI of the latest version of the document. |
version | The version of the document for which to return the URI. |
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-version-uri("/foo/bar/baz.xml", 2) => /foo/bar/baz.xml_versions/2-baz.xml
const dls = require('/MarkLogic/dls'); dls.documentVersionUri('/foo/bar/baz.xml', 2)
Stack Overflow: Get the most useful answers to questions from the MarkLogic community, or ask your own question.