Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
![]() |
![]() |
Home -> Community -> Usenet -> c.d.o.misc -> Re: numbers to words
A copy of this was sent to "micind" <micind_at_bom3.vsnl.net.in>
(if that email address didn't require changing)
On Thu, 29 Jul 1999 20:00:24 +0530, you wrote:
>can anyone help me in providing a readymade function in forms as well as
>reports to convert numbers to words.
>Its possible by calling a DLL in VB
>How it is possible in D2K
>
>Girish
>micind_at_bom3.vsnl.net.in
>
>
>
You can use a date function to do this....
1* select to_char( to_date(5373484,'J'),'Jsp') from dual SQL> / TO_CHAR(TO_DATE(5373484,'J'),'JSP')
This will work for numbers between 1 and 5,373,484...
You can take it a step further to support numbers -5,373,484 .. 5,373,484 by
select decode( sign( :N ), -1, 'Negative ', 0, 'Zero', NULL ) ||
decode( sign( abs(:N) ), +1, to_char( to_date( abs(:N),'J'),'Jsp') )
from dual
/
--
See http://govt.us.oracle.com/~tkyte/ for my columns 'Digging-in to Oracle8i'...
Current article is "Part I of V, Autonomous Transactions" updated June 21'st
Thomas Kyte tkyte_at_us.oracle.com Oracle Service Industries Reston, VA USA
Opinions are mine and do not necessarily reflect those of Oracle Corporation Received on Thu Jul 29 1999 - 10:11:51 CDT
![]() |
![]() |