Quote:
Originally Posted by srirams
Yes , I saw that ....
I am not able to understand how this datecalc can be included with our needs
You copy the datacalc script to your system.
From with in you script you next can call this script like you call any other command or script.
Again, Suppose your most recent log file is from Jan 28, 2007
In your script:
JDATE=`<path to location of datacalc>/datacalc -j 2007 01 28`
The variable JDATE will now hold the Julian Date representation of Jan 28, 2007.
A Julian date is a single number
Next you substract the 60 day.
((JDATE=${JDATE}-60))
You connvert the Julian Date back to the regualar date format
REGDATE=`<path to location of datacalc>/datacalc -j ${JDATE}`
The variable REGDATE will now hold the string "2006 11 29"