Re: [BUGS] BUG #5428: Discrepency in remainder on mod function.

2010-04-17 Thread Khee Chin
On Sat, Apr 17, 2010 at 5:11 AM, Tom Lane wrote: > "Khee Chin" writes: >> I'm not certain if this is a bug or an intended behavior. > >> I noticed a discrepency in calculating the remainders across pgsql (PG), >> wolframalpha (W) and using Knuth's description of floored division > > We follow wha

Re: [BUGS] BUG #5428: Discrepency in remainder on mod function.

2010-04-16 Thread Tom Lane
"Khee Chin" writes: > I'm not certain if this is a bug or an intended behavior. > I noticed a discrepency in calculating the remainders across pgsql (PG), > wolframalpha (W) and using Knuth's description of floored division We follow whatever the C compiler's idea of modulo is. This is somewhat