Previous Topic Next topic Print topic


TIMESTAMP

ANSI DB2 SQL/DS XDB
  X   X

The TIMESTAMP function is used to generate a timestamp. The format appears below:

TIMESTAMP(expres1 [, expres2])

If only one argument is specified, expres1 can be a timestamp or a valid string representation of a timestamp. If two arguments are specified, expres1 must be a date or date string, and expres2 must be a time or time string. If any argument that can be null is null, the result is null.

For example:

UPDATE task
SET audit_time = TIMESTAMP(startdate, starttime)
Previous Topic Next topic Print topic