timestampValueWithPattern()

The function DateTimeLib.timestampValueWithPattern returns a TIMESTAMP value that reflects a string constant or literal and (optionally) is built based on a timestamp mask that you specify. If the mask is "yyyy", for example, the input string must contain four digits, and those digits represent the year value in the timestamp.

  DateTimeLib.timestampValueWithPattern(
    timestampAsString STRING in
    [, timestampMask STRING in
    ])
  returns (result TIMESTAMP)
result
A variable of type TIMESTAMP.
timestampAsString
A string constant or literal that contains digits whose meaning is indicated by the timestamp mask.
timestampMask
Specifies a timestamp mask that gives meaning to each digit in the first parameter. The default mask is yyyyMMddHHmmss. For other details, see TIMESTAMP.

Related concepts
Syntax diagram for EGL functions

Related reference
Datetime expressions
TIMESTAMP

Feedback
(C) Copyright IBM Corporation 2000, 2005. All Rights Reserved.