Re: BUG #14026: Problem to convert number to real

Поиск
Список
Период
Сортировка
От John R Pierce
Тема Re: BUG #14026: Problem to convert number to real
Дата
Msg-id 56EB3B5C.3020809@hogranch.com
обсуждение исходный текст
Ответ на BUG #14026: Problem to convert number to real  (carlos_penteado@yahoo.com.br)
Список pgsql-bugs
On 3/16/2016 1:07 PM, carlos_penteado@yahoo.com.br wrote:
> SELECT 109048.96::float, 0.96::float
> RETURNS
> 109048.96;0.96
> but
> SELECT 109048.96::real, 0.96::real
> RETURNS
> 109049;0.96


float with unspecified precision is treated as double precision. real is
by definition single precision, which is only accurate to around 6 digits.

see http://www.postgresql.org/docs/current/static/datatype-numeric.html



--
john r pierce, recycling bits in santa cruz

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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: Re: BUG #14030: BRIN doc bug
Следующее
От: Tom Lane
Дата:
Сообщение: Re: BUG #14024: problem in Creating pivot table