Search Postgresql Archives

Re: Clarifying "timestamp with time zone"

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jeremy Finzel <finzelj@xxxxxxxxx> writes:
> We often prefer to use timestamptz or "timestamp with time zone" in our
> environment because of its actually storing "objective time" with respect
> to UTC.  But in my own work experience, I have scarcely encountered a case
> where business users, and software engineers, do not actually think it
> means the opposite.

Yeah, it's confusing :-(.

> I do believe this is part of the SQL standard,

Actually not, or at least the standard thinks the type should behave
differently from this.  They think it should store a local timestamp and
then separately a GMT offset.  The way it works in PG was dreamed up ~20
years ago by Tom Lockhart, and in retrospect it was not a great idea
for him to have used the SQL-standard type name for something with
not-SQL-standard behavior.

However, at this point, it's not clear how we could change it without
causing truly enormous backwards-compatibility pain.  If it were a
fringe-usage type, maybe we could get away with a renaming, but it's
certainly not that.

> So it seems to me that "timestamp with time zone" is a misnomer in a big
> way, and perhaps it's worth at least clarifying the docs about this,

Don't the docs describe the behavior pretty clearly already?

			regards, tom lane




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux