Formats a string according to strftime, similar to unix strftime. See Java documentation for valid Date/Time valid escapes.
Name | Type | Required | Default | Description |
---|---|---|---|---|
format | string | Yes | Format string. See Java documentation forvalid Date/Time valid escapes. | |
field | string | No | @timestamp | where to get the current time |
as | string | Yes | Specifies the output field | |
locale | string | No | Specifies the locale such as US or en_GB | |
timezone | string | No | Specifies the timezone such as GMT, EST or Europe/London. See the full list of supported timezones. |
format
is the unnamed parameter.
format time
time := formatTime("%Y/%m/%d %H:%M:%S", field=@timestamp, locale=en_US, timezone=Z)