formatTimestamp
Description
Returns a timestamp formatted as a string, with optional control over the output format and time zone.
Syntax
Like many functions in DataPrime, formatTimestamp
supports two notations, function and method notation. These interchangeable forms allow flexibility in how you structure expressions.
Arguments
Name | Type | Required | Description |
---|---|---|---|
timestamp | timestamp | true | The timestamp to format |
format | string | false | The format specification. Defaults to iso8601 |
tz | string | false | A valid time zone string (see Time Zone section for details) |
Example
Print a timestamp with a +5h offset using the default format**
Output
Theme
Light