develooper Front page | perl.datetime | Postings from January 2006

Best practices - DateTime vs Database question

Thread Next
From:
John Peacock
Date:
January 17, 2006 07:50
Subject:
Best practices - DateTime vs Database question
Message ID:
43CD125E.8050305@rowman.com
I'm in the planning stages for a membership database (probably using 
Catalyst) to replace InfoCentral (worst-case PHP spagetti code, since 
massively hacked by yours truly).

One feature I want to improve upon is the calendar.  Since this is going 
to be for my synagogue, I need to also display Hebrew dates.

My questions are:

1) What should I store in the database?
  a) Native MySQL DATETIME field?
  b) Three fields representing Rata Die?
  c) Julian number (this is easier to convert to Hebrew Date)?
  d) Month/Day/Year INT fields

2) Should I use DateTime at all, since primarily I am interested in 
events scheduled for a specific date (time is not necessarily 
important)?  The most common "operation" on a date for this purpose is 
"how many weeks until event X" so I can display the next week's events 
or send out scheduling e-mails prior to events.

Thoughts?

John

-- 
John Peacock
Director of Information Research and Technology
Rowman & Littlefield Publishing Group
4501 Forbes Boulevard
Suite H
Lanham, MD  20706
301-459-3366 x.5010
fax 301-429-5748

Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About