![Free-eBooks.net](/resources/img/logo-nfe.png)
![All New Design](/resources/img/allnew.png)
14.02 How to convert numeric data to char type as formatted
If we want to see the numerals, in comma separated format, we shall use the "select to_char(]23456.89,'99g99g999d99')as formatted_date from dual" or "select to_char(]23456.89,'99,99,999.99')as formatted_date from dual". In either case the result will be
FORMATTED-NUMBER
- - - - - - - - - - - - - - - - - -
1,23,456,89
14.03 How to convert char type data as date type
To-Date( ) Transforms a number, char or varchar2 into
a date, for example user enters the date as '1961-
08-25' in the yyyy-mm-dd format referring 25th august 1961, We need to convert this data into date format
Syntax: select to-date('1961-08-25','yyyy- mm-dd')as chr-2-date from dual
Result: