temporal.statementGetSystemTime() as null
This function gets the system start time on temporal documents that are inserted or deleted in the same statement as this function. If this function is not called along with a temporal document insert or delete, nothing will be affected.
declareUpdate(); var temporal = require("/MarkLogic/temporal.xqy"); var root = {"tempdoc": {"content": "content here"} }; var options = {metadata: {validStart: "1601-01-01T13:59:00Z", validEnd: "9999-12-31T11:59:59Z"} }; temporal.documentInsert("kool", "doc.json", root, options); temporal.statementGetSystemTime();