Re: TO_NUMBER PROBLEM

From: AWILSON <awilson_at_rci.rogers.com>
Date: 1996/12/06
Message-ID: <32A8B773.4CE6_at_rci.rogers.com>#1/1


karl wrote:
>
> When I use tonumber to return with a format mask the decimal points get
> lost.
> Although I use ther format mask. Is this an Oracle bug or there is some way
> round it
> eg to_number('1.200',-999.9999) returns 1.2 when i want 1.200. Can anyonoe
> please HELP.
> Thanks in advance KARL

-- 
I'm confused. For mathematical purposes, 1.2 is equivalent to 1.200
isn't it?
If you want to _display_ the number to 3 digits precision, try

column a format 999.999 heading "Value"
select to_number('1.200',999.999) a
  from sys.dual;

which gives:

   Value
--------
   1.200

======================================================================
The above reflect my personal views and in no way are connected with
whomsoever I may be working for at this particular point in time.
 
Alan Wilson                              Help fight continental drift.
======================================================================
Received on Fri Dec 06 1996 - 00:00:00 CET

Original text of this message