Re: help with front/backend datatype converting
| От | Tom Lane |
|---|---|
| Тема | Re: help with front/backend datatype converting |
| Дата | |
| Msg-id | 25794.1168054222@sss.pgh.pa.us обсуждение |
| Ответ на | Re: help with front/backend datatype converting ("Do, Leon \(Leon\)" <leondo@alcatel-lucent.com>) |
| Список | pgsql-jdbc |
"Do, Leon \(Leon\)" <leondo@alcatel-lucent.com> writes:
> It can takes any input. You cann't assume it only return hh:mm.
Yes you can --- see EncodeTimezone(). I concur with Kris' opinion
that the driver need not cater for output formats the server will
never generate. Especially not if it's explicitly setting DateStyle,
as I seem to remember it does.
One thing that possibly *does* need fixed as of 8.2 is that the server
can generate hh:mm:ss if the timezone has a fractional-minute UTC
offset. I do not believe there are any modern timezones that do, but
quite a lot do if you check dates 100 or so years ago.
regression=# set timezone = 'Europe/Dublin';
SET
regression=# select now() - '100 years'::interval;
?column?
-------------------------------------
1907-01-06 03:28:22.483631-00:25:21
(1 row)
regards, tom lane
В списке pgsql-jdbc по дате отправления: