Cents corrupted on large number [message #684355] |
Tue, 18 May 2021 03:26  |
Buchas
Messages: 101 Registered: March 2006
|
Senior Member |
|
|
Hello,
I insert into table one value, but when select, I get another value. Is it Oracle bug, or am I missing something?
SQL> create table test15(num number(17,2));
Table created
SQL> insert into test15 (num)values(123456789012345.12);
1 row inserted
SQL> commit;
Commit complete
SQL> select * from test15;
NUM
-------------------
123456789012345,01
As you see I inserted value with .12 decimal part, but when selecting, I get .01
Why the numbers do not match?
|
|
|
|
Re: Cents corrupted on large number [message #684357 is a reply to message #684356] |
Tue, 18 May 2021 04:13  |
Buchas
Messages: 101 Registered: March 2006
|
Senior Member |
|
|
It seems there is some problem with PL/SQL Developer, as using to_char shows correct value for me:
SQL> select num from test15;
NUM
-------------------
123456789012345,01
SQL> select to_char(num) from test15;
TO_CHAR(NUM)
----------------------------------------
123456789012345.12
OK, I can live with that, thanks.
|
|
|