[PYTHON DB-SIG] [comp.lang.python] Date-Time requirements (esp. for databases)
Jim Fulton
jim@digicool.com
Mon, 28 Oct 1996 12:50:54 -0500
------- Start of forwarded message -------
From: jim@digicool.com (Jim Fulton)
Subject: Date-Time requirements (esp. for databases)
Newsgroups: comp.lang.python
Date: 28 Oct 1996 12:49:17 -0500
Organization: Digital Creations, L.C.
Path: news.infi.net!usenet
Lines: 45
Sender: jim@ninny.digicool.com
Message-ID: <lqvibvrnc2.fsf@ninny.digicool.com>
NNTP-Posting-Host: ninny.digicool.com
X-Newsreader: Gnus v5.1
A number of databases support date-time data. It would be helpful to
have a standard date-time implementation for use in Python database
implementations (and elsewhere, of course).
I think that the date-time implementation should:
1. Support conversion from strings in a very wide variety of formats
(e.g. 'Oct, 1, 1994 12:34am EST', '1994/10/1 00:34:21.456')
2. Support subtraction of date-times, and addition and
subtraction of dates and numbers.
3. Store dates efficiently.
4. Store dates immutably.
5. Represent dates to a specified minimum precision
(e.g. milliseconds).
6. Handle all dates in the Gregorian calendar. (e.g. there should
not be problems storing dates from the 18th or 21st centurys.)
7. Provide read-access to date-components (e.g. year, month, second,
day-of-week, etc.)
I'm afraid the implementation should also address issues like:
8. Support for time-zones,
9. Support for daylight-savings time.
I have an implementation of date-time data that meets requirements
1-7 and a little of 8, however, this implementation is encumbered and
I plan to create a new implementation. If I reimplement my date-time
data type, I'd like to do so in a way that is useful to the Python
community at large, and to people developing database interfaces in
particular. I'm particularly interested in suggestions on whether and
how and how much to deal with issues such as time zones and (ugh)
daylight-savings time.
Jim
--
Jim Fulton Digital Creations
jim@digicool.com 540.371.6909
------- End of forwarded message -------
=================
DB-SIG - SIG on Tabular Databases in Python
send messages to: db-sig@python.org
administrivia to: db-sig-request@python.org
=================