From: | Dean Rasheed <dean(dot)a(dot)rasheed(at)gmail(dot)com> |
---|---|
To: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
Cc: | David Rowley <david(dot)rowley(at)2ndquadrant(dot)com>, Bruce Momjian <bruce(at)momjian(dot)us>, Đặng Minh Hướng <kakalot49(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: NaNs in numeric_power (was Re: Postgres 11 release notes) |
Date: | 2018-05-16 07:15:33 |
Message-ID: | CAEZATCW=3GDB3S92tXsCUxuE9jdEt7HWbHMWyX3Qc9FXP2u3cg@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | Postg사설 토토 사이트SQL pgsql-www |
On 15 May 2018 at 22:55, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> David Rowley <david(dot)rowley(at)2ndquadrant(dot)com> writes:
>> On 16 May 2018 at 02:01, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>>> I'm not particularly fussed about getting credit for that. However,
>>> looking again at how that patch series turned out --- ie, that
>>> we ensured POSIX behavior for NaNs only in HEAD --- I wonder
>>> whether we shouldn't do what was mentioned in the commit log for
>>> 6bdf1303, and teach numeric_pow() about these same special cases.
>>> It seems like it would be more consistent to change both functions
>>> for v11, rather than letting that other shoe drop in some future
>>> major release.
>
>> I'm inclined to agree. It's hard to imagine these two functions
>> behaving differently in regards to NaN input is useful to anyone.
>
> Here's a proposed patch for that.
>
In the case 1 ^ NaN = 1, what should the result scale be?
For other inputs, the result scale is at least as large as the scale
of the first input, so I would suggest that the same ought to be the
case here.
Otherwise, this looks fine, and I agree that it makes thinks neater /
more consistent.
Regards,
Dean
From | Date | Subject | |
---|---|---|---|
Next Message | Dmitry Ivanov | 2018-05-16 08:27:09 | Re: [HACKERS] Planning counters in pg_stat_statements |
Previous Message | Amit Kapila | 2018-05-16 04:25:05 | Re: Postgres 11 release notes |
From | Date | Subject | |
---|---|---|---|
Next Message | Etsuro Fujita | 2018-05-16 09:30:23 | Re: Postgres 11 release notes |
Previous Message | Amit Kapila | 2018-05-16 04:25:05 | Re: Postgres 11 release notes |