Leading zero and comma decimal separator [message #636615] |
Wed, 29 April 2015 03:08  |
 |
sinpeak
Messages: 59 Registered: January 2011 Location: india
|
Member |
|
|
Hi,
My client's oracle DB installation is such that the decimal separator is "," and "." is the separator for thousand and more.
E.g One Thousand euros and twenty 25 cents is :
1.000,25
In such a case they want a leading zero in all numbers between -1 and 1 (excluding ).
E.g. 25 cents should be displayed as : 0,25 . But Oracle defaults such a value to : ",25" and not "0,25".
So I used the following :
select to_char(col1,'90.99') from table1
and got the result :
The decimal sign should be "," and not "."
I can obviously use a REPLACE in my PLSQL code ( to replace "." with "," ). But I do not want to make it specific to a certain DB setting of command and dot. Is there any generic way to handling this ?
|
|
|
|
|
|