| От | Tom Lane |
|---|---|
| Тема | Re: reducing NUMERIC size for 9.1 |
| Дата | |
| Msg-id | 19060.1280513299@sss.pgh.pa.us обсуждение |
| Ответ на | Re: reducing NUMERIC size for 9.1 (Robert Haas <robertmhaas@gmail.com>) |
| Ответы |
Re: reducing NUMERIC size for 9.1
|
| Список | pgsql-hackers |
Robert Haas <robertmhaas@gmail.com> writes:
> .... Maybe something like this,
> obviously with a suitable comment which I haven't written yet:
> numeric_digits = (precision + 6) / 4;
> return (numeric_digits * sizeof(int16)) + NUMERIC_HDRSZ;
This is OK for the base-10K case, but there's still code in there
for the base-10 and base-100 cases. Can you express this logic in
terms of DEC_DIGITS and sizeof(NumericDigit) ? I think you might
find it was actually clearer that way, cf Polya.
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера