Re: BUG #1712: JDBC column precision for bigint is 0

Поиск
Список
Период
Сортировка
От Kevin Grittner
Тема Re: BUG #1712: JDBC column precision for bigint is 0
Дата
Msg-id s2aea164.069@gwmta.wicourts.gov
обсуждение исходный текст
Ответ на BUG #1712: JDBC column precision for bigint is 0  ("Gilles Dubochet" <dubochet@urbanet.ch>)
Список pgsql-bugs
I agree on all counts.  The only way that I would extend the description
of "the number of decimal digits" is that I think it's fairly clear that
for floating point numbers it should be "the number of significant
digits" since the fractional part is often only an approximation of any
decimal representation, and its representation could go on forever.

java.util.Date and its java.sql subclasses have well defined formats.
No elaboration with the precision is required, and I've never seen any
hint that it is intended to apply.

As someone tasked with keeping a software framework functional and
efficient with multiple database products through standard JDBC, I often
find myself dealing with different vendor interpretations of the softer
parts of the JDBC spec.  Each vendor is understandably reluctant to
switch from a plausible interpretation they've already implemented to
someone else's interpretation.

-Kevin

>>> Oliver Jowett <oliver@opencloud.com> 06/13/05 4:57 PM >>>

Actually, I just dug through the JDBC javadoc, and noticed that
ResultSetMetaData.getPrecision() does talk about the number of decimal
digits; but in all the other places it's used (such as DatabaseMetaData)
it's not described.

For numeric types using number of decimal digits seems reasonable since
it's consistent with the NUMERIC type's precision/scale information.

Previous reports of this also wanted to provide precision for dates and
times according to the number of digits in them, which seems much more
dubious.

I guess it's another case of the JDBC specification being woefully
underspecified :(

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

Предыдущее
От: "Bug Finder"
Дата:
Сообщение: BUG #1718: geqo_selection.c:linear()
Следующее
От: Tom Lane
Дата:
Сообщение: Re: BUG #1718: geqo_selection.c:linear()