Re: [INTERFACES] problem with numeric

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: [INTERFACES] problem with numeric
Дата
Msg-id 16963.949464917@sss.pgh.pa.us
обсуждение исходный текст
Ответ на problem with numeric  ("Ken J. Wright" <ken@ori-ind.com>)
Список pgsql-interfaces
"Ken J. Wright" <ken@ori-ind.com> writes:
> While testing the new ODBC driver I ran into the following problem with
> queries on numeric fields. Unless the values are surrounded by single quote
> marks, the query fails with the message: Unable to identify an operator '='
> for types 'numeric' and 'float'. This occurs in the WHERE clause of the
> query. 
>
> SELECT * from tbl WHERE numfld = 99.125;
> UPDATE tbl SET numfld = 99.13 WHERE numfld = 99.125;

This is indubitably a backend bug.  It's still there in current sources,
too.  Possibly related to an item I have on my personal TODO list:

: Why is NUMERIC not considered numeric by TypeCategory()?  Why is DATE not
: considered a datetime type?  Isn't this routine fundamentally broken?
: If we need a category it should be taken from a pg_type field, not
: hardwired in code...

Thomas, what say you?
        regards, tom lane


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

Предыдущее
От: Byron Nikolaidis
Дата:
Сообщение: Re: [INTERFACES] problem with numeric
Следующее
От: choiunix@unitel.co.kr
Дата:
Сообщение: subscribe