<?xml version="1.0" encoding="UTF-8"?><api:function-page xml:base="/apidoc/8.0/temporal.setUseLsqt.xml" generated="2015-10-07T16:36:00.016766-07:00" mode="javascript" xmlns:api="http://marklogic.com/rundmc/api"><api:function-name>temporal.setUseLsqt</api:function-name><api:suggest>temporal.setuselsqt</api:suggest><api:suggest>temporal</api:suggest><api:suggest>setuselsqt</api:suggest><api:function-link mode="xquery" fullname="temporal:set-use-lsqt">/apidoc/8.0/temporal:set-use-lsqt.xml</api:function-link><api:function mode="javascript" name="setUseLsqt" type="builtin" lib="temporal" category="Temporal" hidden="false" bucket="MarkLogic Built-In Functions" prefix="temporal" namespace="http://marklogic.com/xdmp/temporal" fullname="temporal.setUseLsqt"><api:summary>
  This function enables or disables the use of LSQT (Last Stable Query Time) 
  on the named collection.
  When enabled (true), a document is created in the database to hold the LSQT.  
  This document is identified by the collection name with an .lsqt suffix. 
  <p xmlns="http://www.w3.org/1999/xhtml">
   You must have LSQT enabled on the temporal collection in order to use the 
  <a href="./temporal:statement-set-system-time"><code>temporal:statement-set-system-time</code></a> 
  function to manually set the system start time when inserting a document 
  into that collection.
  </p>
  <p xmlns="http://www.w3.org/1999/xhtml">
  For details on how to use LSQT, see  
 <a href="/guide/temporal/managing#id_75536">Last Stable Query Time (LSQT) and Application-controlled System Time</a> in the <em>Temporal Developer's Guide</em>
  </p>
  </api:summary><api:params><api:param name="temporal-collection" type="xs:string"><api:param-description>
     The name of the temporal collection.
    </api:param-description><api:param-name>temporal-collection</api:param-name><api:param-type>String</api:param-type></api:param><api:param name="on" type="xs:boolean"><api:param-description>
	    Set to <code xmlns="http://www.w3.org/1999/xhtml">fn:true()</code> to enable LSQT on the collection 
	    or <code xmlns="http://www.w3.org/1999/xhtml">fn:false()</code>
     (the default) to disable LSQT.
    </api:param-description><api:param-name>on</api:param-name><api:param-type>Boolean</api:param-type></api:param></api:params><api:return>null</api:return><api:example class="javascript"><pre xml:space="preserve" xmlns="http://www.w3.org/1999/xhtml">
declareUpdate();
var temporal = require("/MarkLogic/temporal.xqy");
temporal.setUseLsqt("kool", true);

//  Set the temporal collection, "kool", to use LSQT. A document, named
//  "kool.lsqt", that contains the latest LSQT is created in the database.
//  Requires the specified temporal collection to exist. Use 
//  temporal.collectionCreate to create the temporal collection. 
</pre></api:example></api:function></api:function-page>