|
|
|
|
|
|
| Author |
Message |
Sybrand Bakker *nix forums Guru
Joined: 03 Apr 2005
Posts: 1766
|
Posted: Wed Feb 09, 2005 5:38 pm Post subject:
Re: Number data type scale (Oracle, JDBC)
|
|
|
On Wed, 09 Feb 2005 16:57:22 +0100, Tomasz Majchrzak
<tomekem@poczta.fm> wrote:
| Quote: | What is the cause of such result? Is there an initialization parameter that
determines default number data type scale?
My environment: Oracle 9.2, Red Hat Linux 9 with recompiled kernel (2.4.2 .
Thanks for any help,
|
number without further qualifiers equals number(3
This is the non-configurable default.
--
Sybrand Bakker, Senior Oracle DBA |
|
| Back to top |
|
 |
Tomasz Majchrzak *nix forums beginner
Joined: 09 Feb 2005
Posts: 2
|
Posted: Wed Feb 09, 2005 2:57 pm Post subject:
Number data type scale (Oracle, JDBC)
|
|
|
Hi,
I have a table created with statement:
CREATE TABLE test (field NUMBER);
I inserted one value into it:
INSERT INTO test VALUES (4);
According to Oracle documentation:
------------------------------------------------------------
column_name NUMBER (precision, scale)
If a precision is not specified, the column stores values as given.
If no scale is specified, the scale is zero.
------------------------------------------------------------
I checked in database dictionary - DATA_LENGTH for column is set to NULL.
However when I retrieve this data from database with JDBC, getScale()
method of ResultSetMetaData class returns -127 which indicates double
value.
When I run the same scenario against second database (almost similar environment).
everything is fine - so JDBC driver is working properly.
What is the cause of such result? Is there an initialization parameter that
determines default number data type scale?
My environment: Oracle 9.2, Red Hat Linux 9 with recompiled kernel (2.4.2 .
Thanks for any help,
Tomek |
|
| Back to top |
|
 |
Google
|
|
| Back to top |
|
 |
|
|
The time now is Thu Jan 08, 2009 2:50 am | All times are GMT
|
|
Bad Credit Loan | Loans | Credit Card | Mobile Phone | Credit Score
|
|
Copyright © 2004-2005 DeniX Solutions SRL
|
|
|
|
Other DeniX Solutions sites:
Unix/Linux blog |
electronics forum |
medicine forum |
science forum |
|
|
Privacy Policy
|
Powered by phpBB © 2001, 2005 phpBB Group
|
|