Quantcast
Channel: Teradata Forums - Database
Viewing all articles
Browse latest Browse all 14773

How to spell out numeric value in English words by select query. - response (4) by ksaikrishna

$
0
0

Hi Dnoeth,

THnaks for the information.It is really usefull for me.

I have one more question.

Can't we spellout the numbers in terdata?

In requirement have a column having 4 degit numbers and need to spellout it at report level.

Could you please help on this? and also let me know any limitations on interger(like range..etc)

In Oracle "

SQL> select sal, (to_char(to_date(sal,'j'), 'jsp'))
from emp;
the output like,
SAL (TO_CHAR(TO_DATE(SAL,'J'),'JSP'))
--------- -----------------------------------------------------
800 eight hundred
1600 one thousand six hundred
1250 one thousand two hundred fifty
If you want to add some text like,
Rs. Three Thousand only.
SQL> select sal "Salary ",
(' Rs. '|| (to_char(to_date(sal,'j'), 'Jsp'))|| ' only.'))
"Sal in Words" from emp
/
Salary Sal in Words
------- ------------------------------------------------------
800 Rs. Eight Hundred only.
1600 Rs. One Thousand Six Hundred only.
1250 Rs. One Thousand Two Hundred Fifty only.
14. Display Odd/ Even number of records

How to achive this in terdata?

Thanks ,
Sai


Viewing all articles
Browse latest Browse all 14773

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>