SYS_TIMESTAMP_PHYSICAL

Use the SYS_TIMESTAMP_PHYSICAL script function to retrieve the current date and time at the time of processing, in YYYY-MM-DD HH:MM:SS format. The script function lets you specify a time zone.

Syntax

SYS_TIMESTAMP_PHYSICAL ([Time Zone|UTC])

Parameters

  • SYS_TIME_PHYSICAL
    Returns the current time

  • Time Zone or UTC
    (Optional) Specifies the time zone for the date
    Format: script literal or script variable
    Allowed values:

    • Name of a Time Zone object
      For more information, see Time Zone (TZ).
      Format: script literal or script variable
    • UTC
      (Default) Returns the time in UTC (Coordinated Universal Time)

Example

The following example determines the current date and time in Sydney. The script function uses a Time Zone object called TZ.SYD, which is configured for Australian Eastern Standard Time. The retrieved timestamp is printed in the activation report.

:SET &NOW# = SYS_TIMESTAMP_PHYSICAL("TZ.SYD")
:
PRINT &NOW#

See also: