[Tutor] trouble with dates and python and databases

Alan Gauld alan.gauld at btinternet.com
Fri Mar 12 09:20:13 CET 2010


"Christopher Spears" <cspears2002 at yahoo.com> wrote 

> My problem is I'm not sure how to store and retrieve the dates.  
> I assume the best way to record the date is to use datetime.date.

If you are using a database I'd just use the database date functions.
There should be functions to generate and store dates via SQL.

For SQLite:

http://www.sqlite.org/lang_datefunc.html

HTH,

Alan G.



More information about the Tutor mailing list