Re: Data types

Поиск
Список
Период
Сортировка
Искать
От
Mitch Vincent
Тема
Re: Data types
Дата
Msg-id
010601c12a89$1125a350$1251000a@mitch
Список
Дерево обсуждения
Re: Data types Barry Lind <barry@xythos.com>
Numeric is just a fixed-precision type, it can handle any number (I guess?)
as long as your realize it will round the number to the precision that it
was originally set up to keep.. For instance :

brw=# create table test (test numeric(9,2));
CREATE
brw=# insert into test values (9.12345);
INSERT 2503213 1
brw=# select * from test;
 test
------
 9.12
(1 row)

brw=# insert into test values (9.149);
INSERT 2503214 1

brw=# select * from test;
 test
------
 9.12
 9.15
(2 rows)

So just about any type is an OK match, as long as the above behavior is
realized and expected.

Good luck!

-Mitch


----- Original Message -----
From: "Mihai Gheorghiu" 
To: 
Sent: Tuesday, August 21, 2001 4:12 PM
Subject: [GENERAL] Data types


> Would Java BigDecimal type be a good match for PG Numeric, or do I need to
> look further?
>
> Thank you all,
>
> Mihai Gheorghiu
>
>
> ---------------------------(end of broadcast)---------------------------
> TIP 5: Have you checked our extensive FAQ?
>
> http://www.postgresql.org/users-lounge/docs/faq.html
>

В списке pgsql-general по дате отправления
От: Tom Lane
Дата:
Сообщение: Re: macaddr data type issue
От: Tom Lane
Дата:
FAQ