[DB-SIG] date/time handling
Andy Todd
andy47 at halfcooked.com
Thu Aug 3 00:08:19 CEST 2006
Christoph Zwerschke wrote:
> Hello all,
>
> trying to improve date/time handling in PyGreSQL we stumbled over the
> following questions:
>
> 1) Should mx.DateTime still be preferred over stdlib datetime (if both
> are available)? Or should we handle it the other way around meanwhile?
>
> 2) We want to provide a possibility to explicitly choose the preferred
> date/time type, i.e. mx.DateTime or stdlib datetime or even Ticks or
> Python tuples, or strings.
>
> The mx.odbc module does this via an attribute "datetimeformat" of the
> connection object that can be set to constant values named
> DATETIME_DATETIMEFORMAT or STRING_DATETIMEFORMAT (unfortunately, the
> former means mx.DateTime in this context, and there is no value defined
> for stdlib datetime).
>
> Do you think this is a good idea? Maybe we can agree on a preliminary
> standard that can be proposed for a future DB-API 3 (btw, is there any
> work in progress to create such a new version)?
>
> -- Christoph
> _______________________________________________
> DB-SIG maillist - DB-SIG at python.org
> http://mail.python.org/mailman/listinfo/db-sig
I don't know about the mechanism, but my preference for any DB-API
module would be stdlib first and then mx.DateTime.
This has been previously discussed on the list and I believe the
conclusion was to change to this approach in a future version of the DB-API.
Regards,
Andy
--
--------------------------------------------------------------------------------
From the desk of Andrew J Todd esq - http://www.halfcooked.com/
More information about the DB-SIG
mailing list