Re: BUG #4960: Unexpected timestamp rounding

Поиск
Список
Период
Сортировка
От Kevin Grittner
Тема Re: BUG #4960: Unexpected timestamp rounding
Дата
Msg-id 4A7315060200002500029269@gw.wicourts.gov
обсуждение исходный текст
Ответ на BUG #4960: Unexpected timestamp rounding  ("Matthias" <matthias.cesna@gmail.com>)
Ответы Re: BUG #4960: Unexpected timestamp rounding
Список pgsql-bugs
"Matthias" <matthias.cesna@gmail.com> wrote:

> I noticed an unusual (and from my point of view inconsistent)
> rounding of a timestamp:

What do you get when you run?:

show integer_datetimes;

If it is off, which is probably the default for your distribution
under 8.3.X, timestamps are floating point (approximate) values which
get less precise as you move away from the base timestamp of
'2000-01-01 00:00'.

The default under 8.4 is to use integer timestamps, which have a
microsecond precision across the range they support.  (That range is
not as broad as the floating point format, but plenty large for most
practical uses.)

You can configure PostgreSQL to use integer timestamps in 8.3 if you
build from source, but you will need to convert your database.

-Kevin

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

Предыдущее
От: "Matthias"
Дата:
Сообщение: BUG #4960: Unexpected timestamp rounding
Следующее
От: "Kevin Grittner"
Дата:
Сообщение: Re: BUG #4960: Unexpected timestamp rounding