A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2002-February/020471.html below:

add basic time type to the standardlibrary

[Python-Dev] proposal: add basic time type to the standardlibraryM.-A. Lemburg mal@lemburg.com
Wed, 27 Feb 2002 18:31:13 +0100
Kevin Jacobs wrote:
> 
> On Wed, 27 Feb 2002, M.-A. Lemburg wrote:
> > SQL databases don't deal with leap seconds. They store
> > the broken down value (in some way) without time zone information
> > and that's it, fortunately :-)
> 
> Er...  SQL99 (and I believe SQL92) have native support for time with and
> without time zones, and neither say nothing about how databases are to
> "store" those values.  I don't have a copy in front of me, so I can't tell
> you what they say about leap-seconds.  Of course, few implementations
> support this yet, though it worth being forward-looking.

True, SQL-92 defines data types "TIME WITH TIME ZONE" and
"TIMESTAMP WITH TIME ZONE". The standard is only available
as book, but here's a draft which has all the details:

http://www.contrib.andrew.cmu.edu/~shadow/sql/sql1992.txt

Still, only Oracle and PostgreSQL seem to actually implement these 
and ODBC (SQL/CLI), the defacto standard for database interfacing, 
doesn't even provide interfaces to query or store time zone 
information (you can put the information directly in the SQL 
string, but not use it in bound variables).

Basically, you should not store local time in databases,
but instead use UTC. If you need the original time zone 
information for reference, you'd keep this in separate
DB columns (e.g. as strings).

-- 
Marc-Andre Lemburg
CEO eGenix.com Software GmbH
______________________________________________________________________
Company & Consulting:                           http://www.egenix.com/
Python Software:                   http://www.egenix.com/files/python/



RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4