On Wed, 05 Feb 2003 22:20:54 +0000, Thomas Williams wrote: > I got dates in the yyyy-mm-dd format, and I need to compare them to today's > date, as well do stuff like date += 2 months. > > How do I do it?
As the other ones already has said, use the Date:: modules for manipulation. However, if you get the luck that your format is yyyy-mm-dd comparing becomes very simple. (Just use the the lt, gt, le, ge lexical comparing operators). The today's date in the yyyy-mm-dd format could you get e.g. with use POSIX qw/strftime/; my $today = strftime "%Y-%m-%d", localtime; Best Wishes, Janek -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]