Skip to Main Content

SQL & PL/SQL

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

to_number default format

Laurent SchneiderMay 27 2004 — edited Mar 19 2008
My question is actually related to my answer to 248241

What is the default format for to_number? The default format for to_char(number) is TM9, but I cannot figure out the default format for to_number.

Ok, here is my puzzle :
SQL> alter session set nls_numeric_characters=',.';

SQL> select STRING, to_number(string) from x;

STRING          TO_NUMBER(STRING)
--------------- -----------------
-0,000000000001        -1,000E-12
999999999999999        1,0000E+15
1e+25                  1,0000E+25
try to do this without alter session but with to_number(string,<fmt>,'nls_numeric_characters='',.''');

An ice-cream for the first to find out the right fmt :-)

Regards
Laurent
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 24 2004
Added on May 27 2004
13 comments
2,751 views