Re: Native type for storing fractions (e.g 1/3)?

Поиск
Список
Период
Сортировка
От Martijn van Oosterhout
Тема Re: Native type for storing fractions (e.g 1/3)?
Дата
Msg-id 20070315202613.GB9067@svana.org
обсуждение исходный текст
Ответ на Re: Native type for storing fractions (e.g 1/3)?  ("Florian G. Pflug" <fgp@phlo.org>)
Ответы Re: Native type for storing fractions (e.g 1/3)?  ("Florian G. Pflug" <fgp@phlo.org>)
Список pgsql-general
On Thu, Mar 15, 2007 at 09:11:23PM +0100, Florian G. Pflug wrote:
> You'd need a type for large integers first - otherwise your
> ty_fraction will be quite limited. I think numeric could be
> used for that, though I don't know if numeric guarantees that
> at least the operators +,-,* and modulo return exact results
> (Don't loose digits). But even if they do, using some existing
> library for arbitrary sized integers would probably lead to
> better performance.

Numeric is an arbitrary sized number library, so using that would be
smart.

Have a nice day,
--
Martijn van Oosterhout   <kleptog@svana.org>   http://svana.org/kleptog/
> From each according to his ability. To each according to his ability to litigate.

Вложения

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

Предыдущее
От: Robert Treat
Дата:
Сообщение: Re: [SQL] PostgreSQL to Oracle
Следующее
От: "Webb Sprague"
Дата:
Сообщение: Re: simple coordinate system