BUG #12460: Extracting epoch from timestamp string incorrectly assumes "with time zone"

Поиск
Список
Период
Сортировка
От adeconsulting@pacbell.net
Тема BUG #12460: Extracting epoch from timestamp string incorrectly assumes "with time zone"
Дата
Msg-id 20150108004400.11502.38491@wrigleys.postgresql.org
обсуждение исходный текст
Ответы Re: BUG #12460: Extracting epoch from timestamp string incorrectly assumes "with time zone"  (David G Johnston <david.g.johnston@gmail.com>)
Список pgsql-bugs
The following bug has been logged on the website:

Bug reference:      12460
Logged by:          Alan Edel
Email address:      adeconsulting@pacbell.net
PostgreSQL version: 9.3.5
Operating system:   FreeBSD 9.3
Description:

8.3.6 queries using "timestamp" and "timestamptz" casting both give the same
result:

select extract(epoch from cast('2015/01/07 14:00:00' as timestamp));
 date_part
------------
 1420668000
(1 row)

select extract(epoch from cast('2015/01/07 14:00:00' as timestamptz));
 date_part
------------
 1420668000
(1 row)

However, 9.3.5 gives different results, the first one appears to be
incorrect:

select extract(epoch from cast('2015/01/07 14:00:00' as timestamp));
 date_part
------------
 1420639200
(1 row)

select extract(epoch from cast('2015/01/07 14:00:00' as timestamptz));
 date_part
------------
 1420668000
(1 row)

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

Предыдущее
От: tneumann@users.sourceforge.net
Дата:
Сообщение: BUG #12458: Comparison with CHAR is inconsistent between string types
Следующее
От: David G Johnston
Дата:
Сообщение: Re: BUG #12460: Extracting epoch from timestamp string incorrectly assumes "with time zone"