Re: [HACKERS] extra_float_digits and casting from real to numeric

2014-01-08 Thread Christoph Berg
Re: Tom Lane 2014-01-07 <14979.1389112...@sss.pgh.pa.us> > > But if extra_float_digits > 0 is set, I'd expect not only the float4 > > output to be affected by it, but also casts to other datatypes, > > This proposal scares me. extra_float_digits is strictly a matter of > I/O representation, it do

Re: [HACKERS] extra_float_digits and casting from real to numeric

2014-01-07 Thread Tom Lane
Christoph Berg writes: > A customer recently upgraded their jdbc driver from 8.4 to 9.2. This > enabled the binary wire protocol (effectively between 9.1 and 9.2). > They reported that single precision values inserted into a > numeric(10,2) column were suddenly rounded wrongly, i.e. 1.18 was >

[HACKERS] extra_float_digits and casting from real to numeric

2014-01-07 Thread Christoph Berg
A customer recently upgraded their jdbc driver from 8.4 to 9.2. This enabled the binary wire protocol (effectively between 9.1 and 9.2). They reported that single precision values inserted into a numeric(10,2) column were suddenly rounded wrongly, i.e. 1.18 was inserted as 1.20, while that