Re: Problem with java infinity mapping to postgres real column type

Поиск
Список
Период
Сортировка
От Kris Jurka
Тема Re: Problem with java infinity mapping to postgres real column type
Дата
Msg-id 487ED732.8070102@ejurka.com
обсуждение исходный текст
Ответ на Re: Problem with java infinity mapping to postgres real column type  (Tom Lane <tgl@sss.pgh.pa.us>)
Ответы Re: Problem with java infinity mapping to postgres real column type
Список pgsql-jdbc
Tom Lane wrote:
> Kris Jurka <books@ejurka.com> writes:
>> Actually the problem is:
>> jurka=# select 'infinity'::float8::float4;
>> ERROR:  type "real" value out of range: overflow
>
> Well, that's definitely a problem, but what PG version are you testing
> on what platform?  I get this using CVS HEAD on Fedora 9, Darwin, and
> HPUX:
>
> regression=# select 'infinity'::float8::float4;
>   float4
> ----------
>  Infinity
> (1 row)
>

I get the error (or variant) for 7.4 -> 8.2 on Debian Linux.  8.3 and
HEAD work.

I see this in the 8.3 release notes:

Fix float4/float8 to handle Infinity and NAN (Not A Number) consistently
(Bruce)  The code formerly was not consistent about distinguishing
Infinity from overflow conditions.

Kris Jurka


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Problem with java infinity mapping to postgres real column type
Следующее
От: "Johan Miller"
Дата:
Сообщение: Re: Problem with java infinity mapping to postgres real column type