Chaim Frenkel <[EMAIL PROTECTED]> writes:
> One other that might be useful is have strftime() (or something similar)
> built-in without having to use POSIX; and the default should be
> YYYYMMDDHHMMSS.fffffff, (the ISO format)
The more commonly-used ISO format is the extended format rather than the
basic one:
YYYY-MM-DDTHH:MM:SS+ZZZZ
(and yes, the T is part of the format). More commonly, people use the ISO
extended date format and the ISO extended time format separately with a
space between them and the time zone also separated out:
YYYY-MM-DD HH:MM:SS +ZZZZ
> I personally prefer to pass around the string representation, more
> that perl and unix systems need to handle datetime. (And I find it
> easier to read the ISO version than a time in seconds)
I agree. The ISO format is better if you need to write out a date to a
file that you're reading later and you don't need absolutely maximum
speed, particularly if you have good tools to parse it and turn it back
into a native format again.
--
Russ Allbery ([EMAIL PROTECTED]) <http://www.eyrie.org/~eagle/>