Re: timeofday() and CAST

From: Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl>
To: Vilson farias <vilson(dot)farias(at)digitro(dot)com(dot)br>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-general(at)postgresql(dot)org, SIMONE Carla MOSENA <simone(dot)mosena(at)digitro(dot)com(dot)br>, paulo(dot)pizarro(at)digitro(dot)com(dot)br
Subject: Re: timeofday() and CAST
Date: 2003-08-22 04:21:57
Message-ID: 20030822042157.GJ4122@dcc.uchile.cl
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: 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)

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Egor Shipovalov 2003-08-22 04:32:26 strftime
Previous Message Michael D. Allen 2003-08-22 03:55:52 Re: Example Database