1,126
edits
(Added section on arsdate -F parameter for CMOD custom date format.) |
|||
| Line 144: | Line 144: | ||
$ arsdate -C -a 17034 | $ arsdate -C -a 17034 | ||
17034 -> 08/20/16 | 17034 -> 08/20/16 | ||
== Custom date formats == | |||
Newer versions of the <code> arsdate</code> command support the <code> -F</code> option, which allows you to use the formatting parameters listed above to determine the format of the output. | |||
$ arsdate -F "%Y/%m/%d" 17034 | |||
10907 -> 2016/08/20 | |||
$ arsdate -F "%Y-%m-%d %H:%M" -i 1489982862 | |||
1489982862 -> 17-03-20 04:07 | |||
Note that the <code> -F</code> parameter comes first, the date format string is enclosed in quotes, and the internal date/date-time format comes last. By default, arsdate expects a date format - add the <code> -i</code> parameter to process an internal date-time value. | |||
== IBM CMOD Dates in SQL == | == IBM CMOD Dates in SQL == | ||