Re: Ryu floating point output patch
Donald Dong <xdong@csumb.edu>
From: Donald Dong <xdong@csumb.edu>
To: Andrew Gierth <andrew@tao11.riddles.org.uk>
Cc: "pgsql-hackers@postgresql.org" <pgsql-hackers@postgresql.org>
Date: 2019-01-19T23:59:13Z
Lists: pgsql-hackers
> On Jan 18, 2019, at 2:05 AM, Andrew Gierth <andrew@tao11.riddles.org.uk> wrote:
>
> BTW, doing that in a thread about a commitfest patch confuses the
> commitfest app and cfbot (both of which think it's a new version of the
> patch under discussion), so best avoided.
Oops. Thank you. Noted.
I think the previous additional digits behavior still exist
in the latest patch. For example:
=# set extra_float_digits = 0;
SET
=# select float4in('1.123456789');
float4in
----------
1.12346
(1 row)
=# set extra_float_digits = 1;
SET
=# select float4in('1.123456789');
float4in
-----------
1.1234568
(1 row)
The extra_float_digits is increased by 1, but two digits are
added. Without the patch, it will render ' 1.123457' instead.
Commits
-
Provide an extra-float-digits setting for pg_dump / pg_dumpall
- af25bc03e17e 12.0 landed
-
Change floating-point output format for improved performance.
- 02ddd499322a 12.0 landed
-
Use strtof() and not strtod() for float4 input.
- f397e08599a3 12.0 landed