diff --git a/op-guide/history-read.md b/op-guide/history-read.md index d737a3a1f603b..d984392bc5341 100644 --- a/op-guide/history-read.md +++ b/op-guide/history-read.md @@ -20,7 +20,7 @@ The `tidb_snapshot` system variable is introduced to support reading history dat - The variable is valid in the `Session` scope. - Its value can be modified using the `Set` statement. - The data type for the variable is text. -- The variable is to record time in the following format: “2016-10-08 16:45:26.999”. Generally, the time can be set to seconds like in “2016-10-08 16:45:26”. +- The variable accepts TSO (Timestamp Oracle) and datetime. TSO is a globally unique time service, which is obtained from PD. The acceptable datetime format is "2016-10-08 16:45:26.999". Generally, the datetime can be set using second precision, for example "2016-10-08 16:45:26". - When the variable is set, TiDB creates a Snapshot using its value as the timestamp, just for the data structure and there is no any overhead. After that, all the `Select` operations will read data from this Snapshot. > **Note:** Because the timestamp in TiDB transactions is allocated by Placement Driver (PD), the version of the stored data is also marked based on the timestamp allocated by PD. When a Snapshot is created, the version number is based on the value of the `tidb_snapshot` variable. If there is a large difference between the local time of the TiDB server and the PD server, use the time of the PD server. diff --git a/sql/tidb-specific.md b/sql/tidb-specific.md index 9478c7af4cc08..d69702b75180b 100644 --- a/sql/tidb-specific.md +++ b/sql/tidb-specific.md @@ -20,7 +20,7 @@ If you need to set the global variable, run: - Scope: SESSION - Default value: "" -- This variable is used to set the time point at which the data is read by the session. For example, when you set the variable to "2017-11-11 20:20:20", the current session reads the data of this moment. +- This variable is used to set the time point at which the data is read by the session. For example, when you set the variable to "2017-11-11 20:20:20" or a TSO number like "400036290571534337", the current session reads the data of this moment. ### tidb_import_data