Re: Mapping Java BigDecimal

Поиск
Список
Период
Сортировка
От Jakub Bednář
Тема Re: Mapping Java BigDecimal
Дата
Msg-id 4B542920.6070600@b2bcentrum.cz
обсуждение исходный текст
Ответ на Re: Mapping Java BigDecimal  (John R Pierce <pierce@hogranch.com>)
Список pgsql-jdbc
John R Pierce wrote:
> Jakub Bednář wrote:
>> Hi All,
>>
>> We decide add support PostgreSQL database (now supporting only Oracle
>> database) to our product.
>>
>> In Oracle we mapping Java BigDecimal to number(19, 2), in PostgreSQL
>> to numeric(19, 2).
>>
>> If I store to "BigDecimal column" number without decimal, e.g. "3",
>> than Oracle JDBC driver return "3", but PostgreSQL JDBC driver return
>> "3.00".
>
> does a java BigDecimal number have a fixed  2 digit fraction precision
> like that?   If not, why not just define it as NUMERIC and let the
> fractional part 'float' as assigned. ?
>
>
>
>
No. Two digit fraction was example. I'll fix it by using map BigDecimal
to numeric without specify  precision and scale.

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

Предыдущее
От: John R Pierce
Дата:
Сообщение: Re: Mapping Java BigDecimal
Следующее
От: Guillaume Cottenceau
Дата:
Сообщение: Re: 8.3 build 605 downloads broken?