Re: [SQL] Round integer division

2010-06-26 Thread Jasen Betts
On 2010-06-25, Lee Hachadoorian wrote: > > > On 06/25/2010 07:00 PM, Scott Marlowe wrote: >> That all floating point representations are approximate? >> > But if it's error due to approximation, shouldn't the result be random? > I tried this for a handful of larger numbers, and it appears to > con

Re: [SQL] Round integer division

2010-06-26 Thread Jasen Betts
On 2010-06-25, Lee Hachadoorian wrote: > Is it documented anywhere that floating-point numbers round > "scientifically", that is 0.5 rounds to the nearest even number? That's swiss rounding. And no, as I understand it documented that most arithmetic) is platform specific. Postgres is written

Re: [SQL] How do I remove selected words from text field?

2010-06-26 Thread Frank Bax
Osvaldo Kussama wrote: 2010/6/25 Frank Bax : I'm not quite sure how to ask for the query I want, so let's start with data: create table t1 (i int, val varchar); insert into t1 values(1,'A B C D'); insert into t1 values(2,'B D E F'); insert into t1 values(3,'G H I J'); create table t2 (q varchar

Re: [SQL] How do I remove selected words from text field?

2010-06-26 Thread Frank Bax
Osvaldo Kussama wrote: 2010/6/25 Frank Bax : I'm not quite sure how to ask for the query I want, so let's start with data: create table t1 (i int, val varchar); insert into t1 values(1,'A B C D'); insert into t1 values(2,'B D E F'); insert into t1 values(3,'G H I J'); create table t2 (q varchar