Re: Bug? Insert into new Datatype 7.0.x

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: mykarz(at)miyabara(dot)com
Cc: pgsql-general(at)postgreSQL(dot)org
Subject: Re: Bug? Insert into new Datatype 7.0.x
Date: 2000-12-07 21:16:48
Message-ID: 17229.976223808@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

"Michael Miyabara-McCaskey" <mykarz(at)miyabara(dot)com> writes:
> I fumbled around for a while, but finally recreated table3 as (oid, text,
> text), and it worked fine... My question what caused the backend to crash?

> The data I was inserting into table3, was the actual oid from table2, column
> 2 and column 3 were number values of the form "x.xxx", or a null value.

It looks like the text-to-float4 converter function is not NULL-safe in
7.0.*. Sorry about that :-(.

7.1 fixes a boatload of problems of that ilk. In the meantime you could
kluge up something with a CASE expression that tests for null before
trying to cast to float4, or you could fix text_float4 to check for a
null input.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Peter Eisentraut 2000-12-07 21:18:51 Re: multi-byte support
Previous Message Nathan Suderman 2000-12-07 21:16:47 conversion