pgjdbc/pgjdbc GitHub issues and pull requests (mirror)  
help / color / mirror / Atom feed
From: NKame (@NKame) <[email protected]>
To: pgjdbc/pgjdbc <[email protected]>
Subject: Re: [pgjdbc/pgjdbc] issue #3432: Don't send extra_float_digits for PostgreSQL 12+ by default
Date: Thu, 07 Nov 2024 22:01:56 +0000
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>
References: <[email protected]>

Same link, but the information is the the same since 2019.
`By default, floating point values are output in text form in their shortest precise decimal representation; the decimal value produced is closer to the true stored binary value than to any other value representable in the same binary precision.`
`For compatibility with output generated by older versions of PostgreSQL, and to allow the output precision to be reduced, the [extra_float_digits](https://www.postgresql.org/docs/17/runtime-config-client.html#GUC-EXTRA-FLOAT-DIGITS) parameter can be used to select rounded decimal output instead.`
And reading furthermore 
`The meaning of this parameter, and its default value, changed in PostgreSQL 12`
and even further
`If the value is 1 (the default) or above, float values are output in shortest-precise format; see [Section 8.1.3](https://www.postgresql.org/docs/17/datatype-numeric.html#DATATYPE-FLOAT). The actual number of digits generated depends only on the value being output, not on the value of this parameter.`

So I was wrong assuming you needed to reset it to get full precision. Since version 12 it is not needed anymore, so the breaking of PgBouncer default conf on PostgreSQL 12+ is even more meaningless.


view thread (6+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: github://pgjdbc/pgjdbc
  Cc: [email protected], [email protected]
  Subject: Re: [pgjdbc/pgjdbc] issue #3432: Don't send extra_float_digits for PostgreSQL 12+ by default
  In-Reply-To: <<[email protected]>>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox