Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search archives
  Advanced Search

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


  • From: Kris Jurka <jurka(at)ejurka(dot)com>
  • To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
  • Cc: Kris Jurka <books(at)ejurka(dot)com>, Johan Miller <johanmiller(at)gmail(dot)com>, pgsql-jdbc(at)postgresql(dot)org
  • Subject: Re: Problem with java infinity mapping to postgres real column type
  • Date: Wed, 16 Jul 2008 23:22:58 -0600
  • Message-id: <487ED732.8070102@ejurka.com> <text/plain>

Tom Lane wrote:
Kris Jurka <books(at)ejurka(dot)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




Home | Main Index | Thread Index

Privacy Policy | About PostgreSQL
Copyright © 1996 – 2012 PostgreSQL Global Development Group