Re: [sqlite] Creating recurrent appointments?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Gilles Ganault wrote: > I need to write an application to manage appointments. Most of them > are recurrent, with no end-date, while others are one-shots, and the > user must be able to schedule reccurent appointments but be able to > tweak some of them if need be. BTW the way most apps, phones and even standards manage this is by storing a list of events each of which has start and end dates for repeating, and a list of exceptions. A one shot event would have no start or end date. An event that repeats forever would have a start date but no end date. The exceptions override existing repeating events. For example say you have an event that repeats every Tuesday at 3pm. If I want it to be 4pm for next Tuesday then I'd create an exception event pointing at the original but with a different time. You also need exception events that can cancel an existing one. In your user interface or equivalent you have to establish when a user is editing a repeating event whether they are changing just that one instance or the series. The former edits/creates exceptions and the later edits the original. Most applications just flat out ask you when editting which one it is. You should also look into vCalendar/iCalendar standards since that will make import/export easier and make your life easier if you structure your data similar to what they require. Roger -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.6 (GNU/Linux) iD8DBQFIvMA1mOOfHg372QQRAmY4AJ9JC2Muslq/ollOwCBuVK2nBRTJvgCfYKBM LnYj+ZCEXTIDK0Dzios7yKI= =5wtg -END PGP SIGNATURE- ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Re: [sqlite] Creating recurrent appointments?
On Mon, 01 Sep 2008 15:44:05 +0300, Mihai Limbasan <[EMAIL PROTECTED]> wrote: >You will need to loop through this. Thanks. ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
Re: [sqlite] Creating recurrent appointments?
Gilles Ganault wrote: Hello I need to write an application to manage appointments. Most of them are recurrent, with no end-date, while others are one-shots, and the user must be able to schedule reccurent appointments but be able to tweak some of them if need be. To investigate whether I need to bother keeping two tables (one-shots, recurrent, and merge both to display the actual appointment book), I'd like to see how SQLite performs if I use the brute-force approach, which is pre-creating appointments till eg. 2100. Not very smart, but if it works well... Do I need to loop through this, or is there a command that lets me use a single INSERT using something like pseudo "START_DATE, END_DATE, FREQUENCY_EVERY_MONDAY_AT_10AM", etc? == sqlite> create table agenda (id INTEGER PRIMARY KEY, date VARCHAR, label VARCHAR ); sqlite> insert into agenda (id,date,label) values (NULL,"20080902", "Test"); sqlite> commit; == Thank you. You will need to loop through this. ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
[sqlite] Creating recurrent appointments?
Hello I need to write an application to manage appointments. Most of them are recurrent, with no end-date, while others are one-shots, and the user must be able to schedule reccurent appointments but be able to tweak some of them if need be. To investigate whether I need to bother keeping two tables (one-shots, recurrent, and merge both to display the actual appointment book), I'd like to see how SQLite performs if I use the brute-force approach, which is pre-creating appointments till eg. 2100. Not very smart, but if it works well... Do I need to loop through this, or is there a command that lets me use a single INSERT using something like pseudo "START_DATE, END_DATE, FREQUENCY_EVERY_MONDAY_AT_10AM", etc? == sqlite> create table agenda (id INTEGER PRIMARY KEY, date VARCHAR, label VARCHAR ); sqlite> insert into agenda (id,date,label) values (NULL,"20080902", "Test"); sqlite> commit; == Thank you. ___ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users