Re: Bug? Insert into new Datatype 7.0.x

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Bug? Insert into new Datatype 7.0.x
Дата
Msg-id 17229.976223808@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Bug? Insert into new Datatype 7.0.x  ("Michael Miyabara-McCaskey" <mykarz@miyabara.com>)
Список pgsql-general
"Michael Miyabara-McCaskey" <mykarz@miyabara.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

В списке pgsql-general по дате отправления:

Предыдущее
От: "Jonathan Ellis"
Дата:
Сообщение: Re: Oracle-compatible lpad/rpad behavior
Следующее
От: "Joel Burton"
Дата:
Сообщение: Re: Modification times in records?