Boldra has asked for the wisdom of the Perl Monks concerning the following question:
I'm trying to save an event recurrence pattern into a database, such that after I fetch a row, I can ask "->next" ? To see the next event.
Specifically, I am expecting users to store "weekly", "quarterly" and "quarterly, but one week later" in the field. I then need to query the database for "any resource available in date range a--b," but I'll actually be fetching the whole table and querying it in Perl, because we're trying to stay database agnostic.
It looks like the most widely recognised formats are cron and iCal. I can't seem to find good CPAN support for iCal recurrences. The DateTime::Event::Cron module looks very good, but cron won't directly store quarters; you need two entries. There's also DateTime::Event::Recurrence, but that seems to have no serialization/inflation. Maybe I could dump the object as perl and store that in the database, but yuck.
Does anyone have any good suggestions for this? Thanks
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Serialzed Date Recurrence
by haukex (Archbishop) on Mar 11, 2017 at 10:40 UTC | |
Re: Serialzed Date Recurrence
by Anonymous Monk on Mar 09, 2017 at 12:34 UTC | |
by Boldra (Curate) on Mar 09, 2017 at 16:03 UTC | |
by Anonymous Monk on Mar 09, 2017 at 23:48 UTC |