The UNIX and Linux Forums  

Go Back   The UNIX and Linux Forums > Top Forums > Shell Programming and Scripting
Google UNIX.COM



View Single Post in UNIX Forums - Click on the Thread or Permalink to View Entire Thread -->
  #1 (permalink)  
Old 01-05-2008
arag0rn's Avatar
arag0rn arag0rn is offline
Registered User
 

Join Date: Jan 2008
Posts: 2
awk system date with -d option

Hi

I get problems when using the following command :

Code:
cat logs | awk -F";" '{ system("date -d "1970-01-01 UTC+0100 $1 seconds""); }'
date: date invalide `1968641199401200'
date: date invalide `1968641199381709'
this is what i have in my log file :

Code:
cat logs
1199401200;a
1199381709;b
I don't know where this 196864 comes form

Any idea ?

Thx

Last edited by arag0rn; 01-05-2008 at 08:48 AM..
Reply With Quote
Remove advertisements
!!
Forum Sponsor