TIMESTAMP{(fractional-seconds)}

The TIMESTAMP keyword is used in a free-form definition to indicate that the item has type timestamp.

The optional parameter specifies the number of fractional seconds. If the parameter is not specified, the number of fractional seconds defaults to 6.

It must be the first keyword.

The following example shows several timestamps, with different numbers of fractional seconds.

  DCL-S TS0 TIMESTAMP(0);    // YYYY-MM-DD-hh-mm-ss
  DCL-S TS1 TIMESTAMP(1);    // YYYY-MM-DD-hh-mm-ss.f
  DCL-S TS6A TIMESTAMP;      // YYYY-MM-DD-hh-mm-ss.ffffff
  DCL-S TS6B TIMESTAMP(6);   // YYYY-MM-DD-hh-mm-ss.ffffff
  DCL-S TS12 TIMESTAMP(12);  // YYYY-MM-DD-hh-mm-ss.ffffffffffff