Re: patch: make_timestamp function

Поиск
Список
Период
Сортировка
От Fabrízio de Royes Mello
Тема Re: patch: make_timestamp function
Дата
Msg-id CAFcNs+qomxpLLYiX3xAdJwd7zGRjCs3news2RhwHEkdvRfOkqQ@mail.gmail.com
обсуждение исходный текст
Ответ на Re: patch: make_timestamp function  (Pavel Stehule <pavel.stehule@gmail.com>)
Список pgsql-hackers

On Fri, Dec 13, 2013 at 7:09 AM, Pavel Stehule <pavel.stehule@gmail.com> wrote:
>
> I though about it. Then there are two questions
>
> a) Could we have a make_timetz function?
>
> b) What type we use for timezone?
>


I just think in a function that returns the timestamp with timezone based on the current 'timezone' setting.

fabrizio=# show timezone;
  TimeZone  
-------------
 Brazil/East
(1 row)

fabrizio=# select '2013-12-13 11:29:45.786937'::timestamptz;
          timestamptz         
-------------------------------
 2013-12-13 11:29:45.786937-02
(1 row)

fabrizio=# set timezone to 'UTC';
SET
fabrizio=# select '2013-12-13 11:29:45.786937'::timestamptz;
          timestamptz         
-------------------------------
 2013-12-13 11:29:45.786937+00
(1 row)

Regards,

--
Fabrízio de Royes Mello
Consultoria/Coaching PostgreSQL
>> Timbira: http://www.timbira.com.br
>> Blog sobre TI: http://fabriziomello.blogspot.com
>> Perfil Linkedin: http://br.linkedin.com/in/fabriziomello
>> Twitter: http://twitter.com/fabriziomello

В списке pgsql-hackers по дате отправления:

Предыдущее
От: David Rowley
Дата:
Сообщение: Re: logical changeset generation v6.8
Следующее
От: "MauMau"
Дата:
Сообщение: [bug fix] multibyte messages are displayed incorrectly on the client