TZTimestamp fields contain a combination of date and time with a timezone offset, in an ISO 8601 format.
The format is yyyyMMdd-HH:mm:ss[.SSS][Z|[+|–hh[:oo]]] where square brackets denote optionality, and a pipe denotes a choice.
| Code | Meaning | Valid range |
|---|---|---|
| yyyy | Year | 0000-9999 |
| MM | Month of year | 01-12 |
| dd | Day of month | 01-31 |
| HH | Hour of day | 00-23 |
| mm | Minute of hour | 00-59 |
| ss | Second of minute | 00-59 |
| SSS | Fractions of seconds | |
| hh | Offset hours | 00-12 |
| oo | Offset minutes | 00-59 |
| : | Literal value serving as a separator | |
| Z | Literal value denoting UTC | |
| + | Literal value a positive offset from UTC | |
| - | Literal value a negative offset from UTC |
The fractions of seconds, including the period, may be omitted. The fraction may include 3 digits to convey milliseconds, 6 digits to convey microseconds, 9 digits to convey nanoseconds, 12 digits to convey picoseconds; Other number of digits may be used with bilateral agreement.
| Example | Valid | Notes |
|---|---|---|
| 20060901-07:39:00Z | ||
| 20060901-02:39:00-05 | ||
| 20060901-15:39:00+08 | ||
| 20060901-13:09:00+05:30 | ||
| 20060901-13:09:00.123+05:30 | ||
| 20060901-07:39:00 | No offset |