I had a problem with date manipulation.This is my scenario.I have a daily generating report files,they will be generated from Monday to Friday.Now I need to compare those reports.My perl code should work in such a way that if today is Monday I need to compare todays report with previous week Friday’s report.And my date format will be like this 20100803 if i give like this i need to be compared with 20100802. If i give Monday’s report i.e 20100802 it should compare with 20100730 i.e 30th of July. Can anyone please help me.
Thanks in Advance.
This won’t handle holidays (and you should really think about those), but it’s the minimal implementation in Perl:
Where
$timeis a specified time value.