The following table offers examples of the various date and time functions:
Procedure Result dt_systime2025-11-29 17:14:54 dt_systime -gmt t2025-11-29 16:14:54 dt_systime -format "%Y-%m-%d %H:%M:%S %Z"2025-11-29 17:14:54 +0100 dt_sysdate2025-11-29 dt_sysdate -format "%b %d, %Y"Nov 29, 2025 dt_sysdate -format "%b %e, %Y"Nov 29, 2025 dt_ansi_to_pretty11/29/25 dt_ansi_to_list2025 11 29 17 14 54 dt_julian_to_ansi 24519152001-01-05 dt_month_names{January} {February} {March} {April} {May} {June} {July} {August} {September} {October} {November} {December} dt_month_abbrev{Jan} {Feb} {Mar} {Apr} {May} {Jun} {Jul} {Aug} {Sep} {Oct} {Nov} {Dec} dt_valid_time_p "bad date"0 dt_valid_time_p "2001-01-05"1 dt_valid_time_p "2001-01-05 12:00 pm"1 dt_interval_check "2001-01-01" "2001-02-01"2678400 dt_interval_check "2001-02-01" "2001-02-01"0 dt_interval_check "2001-02-01" "2001-01-01"-2678400
Notes
- Any timezone-specific information will be based on the host configuration where the server is running.
- Without a supplied date or time argument, all procedures return results based on the current server time.
- The format argument used by
dt_sysdateanddt_systimeaccepts any of the formatting codes supported by the Tclclock formatprocedure, which is used for the underlying processing. See current documentation at http:///www.tcl.tk/man/. - All procedures that take date or time as an input argument are capable of
accepting these inputs in any format capable of being parsed by
clock scan. This includes virtually all ordinary date and time formats, including am/pm and timezone qualifiers.