Numeric field quirk [Again]

Поиск
Список
Период
Сортировка
От Matthew Hagerty
Тема Numeric field quirk [Again]
Дата
Msg-id 4.3.2.7.2.20001004235437.00d05550@pop3.venux.net
обсуждение исходный текст
Ответы Re: Numeric field quirk [Again]  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Numeric field quirk [Again]  (Jan Wieck <janwieck@Yahoo.com>)
Re: Numeric field quirk [Again]  (Bruce Momjian <pgman@candle.pha.pa.us>)
Список pgsql-hackers
Greetings,

Well, it seems that the numeric issue I was having has nothing to do with 
the precision and scale being set the same, it has to do with the input 
data.  The precision has to be at least 2 greater than the biggest number 
you need to enter, i.e.

equinox=# create table test ( d numeric(4,2) );
CREATE
equinox=# insert into test values(10);
INSERT 167844 1
equinox=# insert into test values(101);
ERROR:  overflow on numeric ABS(value) >= 10^2 for field with precision 4 
scale 2


Matthew



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

Предыдущее
От: Matthew Hagerty
Дата:
Сообщение: Numeric field quirk
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Numeric field quirk [Again]