hi
Genrating next date requires bit of too many ifs any way here si what i would plan to do .hope it helps. I have just given you idea as how you can proceed.
Once done post the code
)))
#!bin/ksh
nextDate( ){
MM=`echo "$VAR1" | awk '{print substr($VAR1,1,2)}'`
DD=`echo "$VAR1" | awk '{print substr($VAR1,3,2)}'`
YYYY=`echo "$VAR1" | awk '{print substr($VAR1,5,4)}'`
# Do all your evaluations here
# Increase value of Day
DD=`expr $DD + 1`
If [[ $DD >31 ]] # for odd months
#increment month
If [[ $DD > 30 ]] # for even months
#increment month
#Same logic applies for year
#Dont forget leap year and February month
}
VAR1=20060101
d0=$VAR1
d1=nextDate $d0
d2=nexDate $d1
..
...
......
d7=nexDate $d6
if missing one day will give a warning missing date ???
Do cat one after another
cat d0.log > 7days.log
if [[$?!=0]]
echo $d0 file missing
#append rest data
cat d1.log >> 7days.log
if [[$?!=0]]
echo $d1 file missing
....
...
Do the same for rest of files
and Finally
lines = `cat 7 days.log | wc -l`