problem with float8 input format
От | Louis-David Mitterrand |
---|---|
Тема | problem with float8 input format |
Дата | |
Msg-id | 20000810172646.A2268@styx обсуждение исходный текст |
Ответы |
Re: problem with float8 input format
|
Список | pgsql-general |
Hello, Suddenly I am getting errors with the following function: SELECT incr(max_price($1),0.05) 000810.17:20:41.181 [2246] ERROR: Bad float8 input format '0.05' 000810.17:20:41.181 [2246] AbortCurrentTransaction Where incr() is defined as: CREATE FUNCTION "incr" (float8,float8 ) RETURNS float8 AS ' SELECT CASE WHEN $1 < dpow(10,int8(log($1))+1)/2 THEN (dpow(10,int8(log($1)))) * $2 ELSE (dpow(10,int8(log($1))+1)/2) * $2 END ' LANGUAGE 'SQL'; Strangely engough the function call works fine when called from psql but fails (but not always!) from a C trigger. Thanks in advance for any help, -- Louis-David Mitterrand - ldm@apartia.org - http://www.apartia.org "Kill a man, and you are an assassin. Kill millions of men, and you are a conqueror. Kill everyone, and you are a god." -- Jean Rostand
В списке pgsql-general по дате отправления: