Numeric with '-'

Поиск
Список
Период
Сортировка
От Hiroshi Inoue
Тема Numeric with '-'
Дата
Msg-id 000401bf7c3a$1fec7200$2801007e@tpf.co.jp
обсуждение исходный текст
Ответы Re: [HACKERS] Numeric with '-'  (Brian Hirt <bhirt@mobygames.com>)
Re: [HACKERS] Numeric with '-'  (Tom Lane <tgl@sss.pgh.pa.us>)
Список pgsql-hackers
Hi,

The following phenomenon was reported to pgsql-jp(ML in Japan).

rest=# select -1234567890.1234567;
ERROR:  Unable to convert left operator '-' from type 'unknown'

-1234567890.1234567 is treated as - '1234567890.1234567'
as the following comment in scan.l says.
/* we no longer allow unary minus in numbers.* instead we pass it separately to parser. there it gets* coerced via
doNegate()-- Leon aug 20 1999*/
 

However doNegate() does nothing for SCONST('1234567890.1234567').
I don't understand where or how to combine '-' and numeric SCONST.

Regards.

Hiroshi Inoue
Inoue@tpf.co.jp


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

Предыдущее
От: Chris Bitmead
Дата:
Сообщение: Re: [HACKERS] Re: [PATCHES] Patch for more readable parse error messages
Следующее
От: Brian Hirt
Дата:
Сообщение: Re: [HACKERS] Numeric with '-'