date time as epoch ? 
Author Message
 date time as epoch ?

Not exactly what you want but...

I use the following to get datetime stamps in UTC that are
garanteed to increase with time. The format is "yymmddhhmmss".
I didn't see any formats in the man pages that returned the
epoch...but I didn't look that hard.

{
 option = "-u";
 format = "+%y%m%d%H%M%S";
 if (!system("date '"option"' '"format"'") | getline result)
  print result;

Quote:
}

--------------------------------------------------------------------
Charles E. Ely                        Derby Associates International


Sun, 24 May 1998 03:00:00 GMT  
 date time as epoch ?

: Not exactly what you want but...
:
: I use the following to get datetime stamps in UTC that are
: garanteed to increase with time. The format is "yymmddhhmmss".
: I didn't see any formats in the man pages that returned the
: epoch...but I didn't look that hard.
:
: {
:  option = "-u";
:  format = "+%y%m%d%H%M%S";
:  if (!system("date '"option"' '"format"'") | getline result)
:   print result;
: }

   The gnu date command includes a %s directive that returns, according
to the man page: ``seconds since 00:00:00, Jan 1, 1970 (a nonstandard
extension)''.

--
When cryptography is outlawed, bayl bhgynjf jvyy unir cevinpl.



Mon, 25 May 1998 03:00:00 GMT  
 
 [ 2 post ] 

 Relevant Pages 

1. date and time as epoch ?

2. Create Time / date or Modified Time / date of a txt file

3. convert labview date/time to excel date/time

4. DOS compressed date/time into real date/time

5. print all dates after epoch

6. converting epoch timestamp into human date

7. convert epoch time to yyyymmdd hhmmss

8. Clarion Date (Long) -> Access Date\Time

9. time to time with different dates...

10. TIME&DATE in HTML shows TIME

11. Unix time to calendar date/time?

12. Dos Date & time to clarion date & time

 

 
Powered by phpBB® Forum Software