Examples
The following examples show how date and time patterns are interpreted in the U.S. locale. The date and time represented in these examples is 2001-07-04 12:08:56 local time in the U.S. Pacific Time time zone.
| Date and Time Pattern | Result |
| "yyyy.MM.dd G 'at' HH:mm:ss z" | 2001.07.04 AD at 12:08:56 PDT |
| "EEE MMM d ''yy" | Wed Jul 4 '01 |
| "h:mm a" | 12:08 PM |
| "hh 'o''clock' a zzzz" | 12 o'clock PM Pacific Daylight Time |
| "K:mm a z" | 0:08 PM PDT |
| "yyyyy.MMMMM.dd GGG hh:mm aaa" | 02001.July.04 AD 12:08 PM |
| "EEE d MMM yyyy HH:mm:ss Z" | Wed 4 Jul 2001 12:08:56 -0700 |
| "yyMMddHHmmssZ" | 010704120856-0700 |
This example shows how the entire date/time value can be formatted in a single call:
$DateTime (simple-variable-value format-string)
Where: format-string: a date and time pattern
Note: $DateTime does not include the parameter lang-code for presenting date and time patterns in a language other than the designated default language.
Example:
$DateTime (${CT}, "EEE dd MMM yyyy HH:mm:ss Z")
