Re: BUG #8355: PL/Python 3 can't convert infinity to PostgreSQL's value - Mailing list pgsql-bugs

From Tom Lane
Subject Re: BUG #8355: PL/Python 3 can't convert infinity to PostgreSQL's value
Date
Msg-id 7861.1375475031@sss.pgh.pa.us
Whole thread Raw
In response to BUG #8355: PL/Python 3 can't convert infinity to PostgreSQL's value  (grv87@yandex.ru)
Responses Re: BUG #8355: PL/Python 3 can't convert infinity to PostgreSQL's value
List pgsql-bugs
grv87@yandex.ru writes:
> PL/Python can't convert Python's float with infinity value to PostgreSQL's
> float.
> The reason is that Python's standard representation of infinity is 'inf'
> ('Infinity' is accepted as well), but PostgreSQL's representation is
> 'Infinity' only.

Hmm, I was about to contradict you, because it works fine on my Linux
and OS X machines:

regression=# select 'inf'::float8;
  float8
----------
 Infinity
(1 row)

but further experimentation says that this doesn't work on my ancient
HPUX box; and you're complaining about Windows.  So what we've got here
is a platform dependency in the behavior of strtod().  I don't think
we can promise to hide all such dependencies, but maybe it'd be a good
idea to take care of this particular one.

            regards, tom lane

pgsql-bugs by date:

Previous
From: grv87@yandex.ru
Date:
Subject: BUG #8355: PL/Python 3 can't convert infinity to PostgreSQL's value
Next
From: Tom Lane
Date:
Subject: Re: BUG #8355: PL/Python 3 can't convert infinity to PostgreSQL's value