Re: timeofday() and CAST - Mailing list pgsql-general

From Alvaro Herrera
Subject Re: timeofday() and CAST
Date
Msg-id 20030822042157.GJ4122@dcc.uchile.cl
Whole thread Raw
In response to Re: timeofday() and CAST  ("Vilson farias" <vilson.farias@digitro.com.br>)
Responses Re: timeofday() and CAST  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-general
On Thu, Aug 21, 2003 at 02:58:40PM -0300, Vilson farias wrote:

>   I've been taking a look at documentation about timezones (Appendix A/Time
> Zone Abbreviations) and it seems that BRT is really missing in that list.
> Isn't Brazil important/big enough to have at least BRT and BRST timezones
> supported from PostgreSQL? IMHO maybe it's time for a more robust support
> for timezones, because maybe more people from other countries are getting
> the same problem in newer PostgreSQL releases, since timestamps from strings
> are not so flexible as they were in older releases.

Hmm... I'm seeing Chile standard timezones, so it's not a matter of how
big the country is.  However, in the table at
src/backend/utils/adt/datetime.c I'm seeing conflict between BST
(British Summer Time), BST (Brazil Standard Time) and BST (Bering
Standard Time), so they just picked one.  However there's a timezone
called "BRA" that's apparently "Brazil Time".

I agree however that it's a pretty ugly bug that you can get a timezone
that the server won't accept back.

Maybe the bug is that src/backend/utils/adt/nabstime.c::timeofday() uses
%Z instead of %z.

--
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"Thou shalt not follow the NULL pointer, for chaos and madness await
thee at its end." (2nd Commandment for C programmers)

pgsql-general by date:

Previous
From: "Michael D. Allen"
Date:
Subject: Re: Example Database
Next
From: "Egor Shipovalov"
Date:
Subject: strftime