Skip to content
Developer Edition runs on one host and does not require a product license file. Need multi-host deployment or performance testing at scale? Explore Enterprise Edition

SHOW TTLS command

The SHOW TTLS command returns information about the time-to-live (TTL) settings of a specific graph.

To specify the graph, use either of the following methods:

  • Add a USE clause before this command to set the working graph.
  • Use SESSION SET to set the graph for the current session in advance.

If both methods are used, the one specified in the USE clause takes precedence. If neither is used, an error occurs.

The following table describes the returned information:

Column Description
type The type of graph element on which the TTL duration is set. Currently, only edge types are supported.
name The name of the edge type on which the TTL duration is set.
ttl_property The property of the edge type based on which the TTL duration is set.
ttl_duration The TTL duration set on the edges.

Note

An operation involving a non-default schema or an object in it requires access to the schema, either implicitly or through an explicit USAGE grant, as well as the privilege required for the operation. The schema access check and the privilege check for the requested operation are independent; satisfying one does not satisfy the other. Schema access control does not apply to temporary graphs or built-in procedures and functions. For more information, see Schema access control.

Syntax

show_ttls_command
SHOW TTLS

show_ttls_command ::=
    'SHOW' 'TTLS'

Examples

The following examples are based on the example dataset.

Show the TTL settings of a graph

USE movie SHOW TTLS

The preceding example returns information about the TTL duration that is set in CREATE TTL.

Return:

+------+-------+--------------+----------------------+
| type | name  | ttl_property | ttl_duration         |
+------+-------+--------------+----------------------+
| Edge | Watch | ttl_test     | P16DT18H12M4.005006S |
+------+-------+--------------+----------------------+