the_0ne has asked for the wisdom of the Perl Monks concerning the following question:
I get this...use Date::Set; # when the event occurs: every friday. my $set = Date::Set->event ( rule => 'FREQ=WEEKLY;BYDAY=FR'); # in what period we want occurences: december 2002 my $period = Date::Set->period (time => ['20021201', '20021231']); my @occurs = $set->during (at => $period)->list; print "occurences on ", join (" ,", @occurs), "\n";
This prints off...use Date::Set; $a = Date::Set->event(); $a->event( rule => 'FREQ=MONTHLY;INTERVAL=2;' ); $a->event( start => '20030801', end => '20031201' ); @list = $a->list; foreach (@list) { print "$_\n"; }
This prints off...$a = Date::Set->event( rule => 'FREQ=YEARLY;INTERVAL=2' ); $a->during( start => '20030801', end => '20200801' ); print $a . "\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Date::Set not returning correct results.
by asarih (Hermit) on Sep 06, 2003 at 17:14 UTC | |
by the_0ne (Pilgrim) on Sep 07, 2003 at 00:29 UTC | |
|
Re: Date::Set not returning correct results.
by fglock (Vicar) on Sep 07, 2003 at 01:12 UTC | |
by the_0ne (Pilgrim) on Sep 07, 2003 at 03:36 UTC |