Number to Word Convert Function
Dear All,
Plz anybody have function name which can convert NUMBER to WORD.
example: 1213 to One Thousand Two Hundred Thirteen
thanks,
RP
rp,
Pls. use below FM...
CALL FUNCTION 'SPELL_AMOUNT'
EXPORTING
AMOUNT = amouno
CURRENCY = 'USD'
FILLER = ' '
LANGUAGE = SY-LANGU
IMPORTING
IN_WORDS = SPELL
EXCEPTIONS
NOT_FOUND = 1
TOO_LARGE = 2
OTHERS = 3.
Check
http://www.sap-img.com/fu001.htm
(OR)
Also you can use FM HR_IN_CHG_INR_WRDS.
report ztest02.
data: words(50) type c.
call function 'HR_IN_CHG_INR_WRDS'
exporting
amt_in_num = '100000'
importing
amt_in_words = words.
write:/ words.
Pls. Reward if useful
Similar Messages
-
Wanted Number to Words(english) function
Hi,
I need urgently a pl/sql function which converts numbers into english words, currently function running in my reports is not supporting beyond the 5373484 value and the following error thrown. Please give me the code required for this at the earliest.
ORA-01854: julian date must be between 1 and 5373484
ORA-06512: at "IAPMS.NUMTOWORD", line 6
ORA-06512: at line 1
Thanks
Sairem -----------------------------------------------------------------------
rem Filename: spellout.sql
rem Purpose: This script will spell out numbers to words
rem Author: Ajit Mathew
rem -----------------------------------------------------------------------
select decode( sign( &num ), -1, 'Negative ', 0, 'Zero', NULL ) ||
decode( sign( abs(&num) ), +1, to_char( to_date( abs(&num),'J'),'Jsp') )
from dual -
Function to convert number to word format.
Dear Friends,
Could you please help me with a code that will take 'sum of all values of a column' as input parameter & return its value in word format.
Number can be negative , it can/can't contain digits after decimal.
i have two ways but it won't work when my no. becomes negative
Moreover i want that it should work on both type of data, numbers without decimal & number with decimal.
that is what i possess:
1)
function CF_1FORMULA return char is
num1 number;
p_number number;
type myArray is table of varchar2(255);
l_str myArray := myArray( '',
' thousand ', ' million ',
' billion ', ' trillion ',
' quadrillion ', ' quintillion ',
' sextillion ', ' septillion ',
' octillion ', ' nonillion ',
' decillion ', ' undecillion ',
' duodecillion ' );
l_num varchar2(50);
l_return varchar2(4000);
begin
num1:=:my_mumber;
p_number:=num1;
l_num:=trunc( p_number );
for i in 1 .. l_str.count
loop
exit when l_num is null;
if ( to_number(substr(l_num, length(l_num)-2, 3)) <> 0 )
then
l_return := to_char(
to_date(
substr(l_num, length(l_num)-2, 3),
'J' ),
'Jsp' ) || l_str(i) || l_return||'Rupees';
end if;
l_num := substr( l_num, 1, length(l_num)-3 );
end loop;
return l_return;
end;
and
2)
select to_char(to_date(floor(1234.99),'J'),'Jsp')||' Rupees and '||to_char(to_date((1234.99-(floor(1234.99)))*100,'J'),'Jsp')||' Paise' from dual;
kindly help me.
Thanks & Regards
VishnuCommon question.
But you will have realised that already if you'd bothered to search the forum...
http://forums.oracle.com/forums/search.jspa?threadID=&q=number+to+word&objID=f75&dateRange=all&userID=&numResults=30 -
Hi,
I want to convert number in words and get the output through a query.
For example :if the value in row is 1311 then I want the query to return it like one thousand three hundreds and eleven.
Any help is highly appreciated.
CheersIt could be better indeed, scope is larger, but problem with 0 still exists.
SQL> select to_char(to_date(0,'J'), 'JSP') as converted_form from dual;
select to_char(to_date(0,'J'), 'JSP') as converted_form from dual
ERROR at line 1:
ORA-01854: julian date must be between 1 and 5373484
SQL> Better to build function as showed by Tom Kyte in the link given earlier.
Nicolas. -
I need to get the number of words of pdf files. I usually convert them into word files to get the word count. Some pdf files are protected and can't be converted into word files. Is there another way to get the number of words of these protected pdf files? I use adobe professional XI Pro.
Scroll through and read the answers available in the thread below. You may find the information helpful.
Trying to write Javascript code to get word count
Be well... -
In the new iOS-7 Safari, has the "reader" function been changed to eliminate the option to modify font size (and hence to modify the number of words per line), or is it just that I can't find how to do that?
iOS 7
Seperate text size modification is no longer available in Safari Reafer.
Use Settings.
Settings >General > Text Size -
Write number in words (using Oracle)
Hello
Can you please advise how to convert a number to word in Oracle?
I am aware of using following but this has limitation of using number till 5373484
select to_char(to_date('2013', 'j'), 'jsp') as "Date in Words" from dual
Thanks in advance,
TinkuHi, Tinku,
See this Tom Kyte page. It shows how to insert "billion", "trillion" etc. into the strings that 'Jsp' provides. Basically, you only have to spell the first thousand numbers, that is, up to 3 digits. The next 3 digits just repeat the pattern, with "thousand" appended to the end. The 3 digits after that just repeat the pattern again, with "million" concatenated, the 3 digits after that have "billion" (at least in the USA), and so on.
The same page also shows spelling functions for French and Portuguese. -
AOA ALL
Dear i want to convert a numeric value for eg:'1000' into words that is 'ONE THOUSAND' in a report.does any body knows a method or function for that available in developer or any other way...
do tell me
thxHi,
See the link
converting number to words(100==one hundred)
Provided a function to convert number to words
Thanks,
Oracle Reports Team -
Getting number of Words in a Frame in CS4
Hello All,
I am trying to get the number of words in a Text Frame. I tried the API GetWordCountInfo of ITextUtils
For E.g. Utils<ITextUtils>()->GetWordCountInfo( iTextmodel, 0, iTotalLength, ITextUtils::kUpdateAll, ITextUtils::kStartCounting,
wordStarted, characters, words, paragraphs, lines, oversetCharacters, oversetWords, oversetParagraphs, oversetLines, bWordAcrossOverset,
helper );
I am took the value of words and checked. I am getting value such as 2049679. Even though there is no text in the frame. Am not sure what wrong value I have given as a parameter required.
Has anyone tried this before. Or Is there some other way of getting the word count from the frame. If so please do let me know.
Thank you all in advance.
Regards
Farzana.Hi ,
I have declared the parameters to the function as uint32.
And when I see them in alert I am converting the same to int32 by using ToInt32(). I tried using uint32 appending directly as number to my string variable. But it gives same output in alert.
Thanks
Regards
Farzana, -
How to Count number of words in a file....
Hi Experts,
I have uploaded the text file, from the application server, like this:
call function 'GUI_UPLOAD'
exporting
filename = LV_ip_FILENAME
tables
data_tab = LT_FILETABLE.
The text file contains some number character words.... like "sap labs india..... "
Now, I wanted to count number of words in an internal table LT_FILETABLE.... can anybody help me?Hi,
Special Characters in Regular Expressions
The following tables summarize the special characters in regular expressions:
Escape character
Special character Meaning
Escape character for special characters
Special character for single character strings
Special character Meaning
. Placeholder for any single character
C Placeholder for any single character
d Placeholder for any single digit
D Placeholder for any character other than a digit
l Placeholder for any lower-case letter
L Placeholder for any character other than a lower-case letter
s Placeholder for a blank character
S Placeholder for any character other than a blank character
u Placeholder for any upper-case letter
U Placeholder for any character other than an upper-case letter
w Placeholder for any alphanumeric character including _
W Placeholder for any non-alphanumeric character except for _
[ ] Definition of a value set for single characters
[^ ] Negation of a value set for single characters
[ - ] Definition of a range in a value set for single characters
[ [:alnum:] ] Description of all alphanumeric characters in a value set
[ [:alpha:] ] Description of all letters in a value set
[ [:blank:] ] Description for blank characters and horizontal tabulators in a value set
[ [:cntrl:] ] Description of all control characters in a value set
[ [:digit:] ] Description of all digits in a value set
[ [:graph:] ] Description of all graphic special characters in a value set
[ [:lower:] ] Description of all lower-case letters in a value set
[ [:print:] ] Description of all displayable characters in a value set
[ [:punct:] ] Description of all punctuation characters in a value set
[ [:space:] ] Description of all blank characters, tabulators, and carriage feeds in a value set
[ [:unicode:] ] Description of all Unicode characters in a value set with a code larger than 255
[ [:upper:] ] Description of all upper-case letters in a value set
[ [:word:] ] Description of all alphanumeric characters in a value set, including _
[ [:xdigit:] ] Description of all hexadecimal digits in a value set
a f
v Diverse platform-specific control characters
[..] Reserved for later enhancements
[==] Reserved for later enhancements
u2192 More
Special characters for character string patterns
Special character Meaning
Concatenation of n single characters
{n,m} Concatenation of at least n and a maximum of m single characters
{n,m}? Reserved for later enhancements
? One or no single characters
Concatenation of any number of single characters including 'no characters'
*? Reserved for later enhancements
+ Concatenation of any number of single characters excluding 'no characters'
+? Reserved for later enhancements
| Linking of two alternative expressions
( ) Definition of subgroups with registration
(?: ) Definition of subgroups without registration
1, 2, 3 ... Placeholder for the register of subgroups
Q ... E Definition of a string of literal characters
(? ... ) Reserved for later enhancements
for more details please refer the following,
[http://help.sap.com/abapdocu_70/en/ABENREGEX_SYNTAX_SIGNS.htm]
[http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/902ce392-dfce-2d10-4ba9-b4f777843182?QuickLink=index&overridelayout=true]
Thanks,
Renuka S. -
CONVERT function in SQL Server to oracle
All,
How to convert CONVERT function in SQL Server to oracle, below mentioned format is in SQL Server:
variable1 = convert(numeric(20), SUBSTRING( parameter1,parameter2,parameter3)
parameter1 datatype nvarchar2(100)
parameter2 datatype bigint
parameter3 datatype bigint
I did bit R&D, but was not successful..but still getting on..
If any help that would be great...
Regards,
~ORAYou cannot specify the precision/scale or length of input paramters to a stored procedure in Oracle, or at least the pl/sql engine does not respect the sizing. Assuming that you want to do something with variable1 in the procedure, and not just return it, the Oracle equivalent would be something along the lines of:
SQL> CREATE FUNCTION f (p_param1 IN VARCHAR2,
2 p_param2 IN NUMBER,
3 p_param3 IN NUMBER) RETURN NUMBER IS
4 l_var1 NUMBER(20) := SUBSTR(p_param1, p_param2, p_param3);
5 BEGIN
6 RETURN l_var1 * 10;
7 END;
8 /
Function created.
SQL> SELECT f('ABC10DEF', 4, 2) FROM dual;
F('ABC10DEF',4,2)
100You may need to adjust the return type to match what you are actually returning.
You can also use this iin a direct assignment in pl/sql without doig a select, something like:
SQL> DECLARE
2 l_num NUMBER(20);
3 BEGIN
4 l_num := f('ABC10DEF', 4, 2);
5 DBMS_OUTPUT.Put_Line('The number is: '||l_num);
6 END;
7 /
The number is: 100John -
How to change the elements number in Number To Boolean Array Function VI
Hi, I'm working on using the DAQ digital output to control the digital input of a DAC, and I used the Number To Boolean Array Function. VI to convert the number to a Boolean array. The maximum number should be 4096, therefore it should consist of 12 elements.
For the description of the VI, it says Boolean array returns an array of 8, 16, 32, or 64 elements, depending on the number of bits in the integer. Therefore, I change the number of the channels in task to 16, but it still doesn't work. Any suggesitions are greatly appreciated.
Thanks!
Possible reason(s):
Write cannot be performed, because the number of channels in the data does not match the number of channels in the task.
When writing, supply data for all channels in the task. Alternatively, modify the task to contain the same number of channels as the data written.
Number of Channels in Task: 12
Number of Channels in Data: 32
Task Name: _unnamedTask<1B>
Solved!
Go to Solution.
Attachments:
DAC test.vi 47 KBOnce you have the boolean array, you can resize it using array tools. For example you can use "reshape array" with a lenght of 12 to trim the array to 12 booleans elements (you can also use array subset).
LabVIEW Champion . Do more with less code and in less time . -
How to Count total number of Words in PDF?
I am used Adobe Acrobat javascript inbuilt function getPageNumWords(<pagenumber>) it return the number of words present in specified page, but while am copy and paste text content from PDF file to MS Word, Words count given by MS Word is little bit differ, so any one know in which aspect Acrobat count the words?
Which words count result is correct?
Shall is go with Acrobat Words count result or MS Words count result?
But I want to count the total number of words in PDF file (my input is PDF file) else can I go with iText?
Words count in PDf using iText is possible?Word counts are likely to vary a little according to how you count. For instance, are hyphenated words one or two words? What if the hyphen is at the end of a line? Do numbers count as words? Headers and footers? Captions?
Generally, you just accept a slight variation. If you are counting words in a professional context, i.e. where payment is per word, you probably need a contractual definition of how words are to be counted; in the absence of one, I suggest you use Word. -
Number to word Indonesia version
i need a help
i want to make number to word conversion in indonesia language
my question how to use the javascript in adobe livecyle, i am a newbie in using javascript and livecyle
here the script that i got from google
[quoute]
function terbilang(bilangan) {
bilangan = String(bilangan);
var angka = new Array('0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0');
var kata = new Array('','Satu','Dua','Tiga','Empat','Lima','Enam','Tujuh','Delapan','Sembilan');
var tingkat = new Array('','Ribu','Juta','Milyar','Triliun');
var panjang_bilangan = bilangan.length;
/* pengujian panjang bilangan */
if (panjang_bilangan > 15) {
kaLimat = "Diluar Batas";
return kaLimat;
/* mengambil angka-angka yang ada dalam bilangan, dimasukkan ke dalam array */
for (i = 1; i <= panjang_bilangan; i++) {
angka[i] = bilangan.substr(-(i),1);
i = 1;
j = 0;
kaLimat = "";
/* mulai proses iterasi terhadap array angka */
while (i <= panjang_bilangan) {
subkaLimat = "";
kata1 = "";
kata2 = "";
kata3 = "";
/* untuk Ratusan */
if (angka[i+2] != "0") {
if (angka[i+2] == "1") {
kata1 = "Seratus";
} else {
kata1 = kata[angka[i+2]] + " Ratus";
/* untuk Puluhan atau Belasan */
if (angka[i+1] != "0") {
if (angka[i+1] == "1") {
if (angka[i] == "0") {
kata2 = "Sepuluh";
} else if (angka[i] == "1") {
kata2 = "Sebelas";
} else {
kata2 = kata[angka[i]] + " Belas";
} else {
kata2 = kata[angka[i+1]] + " Puluh";
/* untuk Satuan */
if (angka[i] != "0") {
if (angka[i+1] != "1") {
kata3 = kata[angka[i]];
/* pengujian angka apakah tidak nol semua, lalu ditambahkan tingkat */
if ((angka[i] != "0") || (angka[i+1] != "0") || (angka[i+2] != "0")) {
subkaLimat = kata1+" "+kata2+" "+kata3+" "+tingkat[j]+" ";
/* gabungkan variabe sub kaLimat (untuk Satu blok 3 angka) ke variabel kaLimat */
kaLimat = subkaLimat + kaLimat;
i = i + 3;
j = j + 1;
/* mengganti Satu Ribu jadi Seribu jika diperlukan */
if ((angka[5] == "0") && (angka[6] == "0")) {
kaLimat = kaLimat.replace("Satu Ribu","Seribu");
return kaLimat + "Rupiah";
[/quote]
PLEASEEE................ YOUR HELP...i need a help
i want to make number to word conversion in indonesia language
my question how to use the javascript in adobe livecyle, i am a newbie in using javascript and livecyle
here the script that i got from google
[quoute]
function terbilang(bilangan) {
bilangan = String(bilangan);
var angka = new Array('0','0','0','0','0','0','0','0','0','0','0','0','0','0','0','0');
var kata = new Array('','Satu','Dua','Tiga','Empat','Lima','Enam','Tujuh','Delapan','Sembilan');
var tingkat = new Array('','Ribu','Juta','Milyar','Triliun');
var panjang_bilangan = bilangan.length;
/* pengujian panjang bilangan */
if (panjang_bilangan > 15) {
kaLimat = "Diluar Batas";
return kaLimat;
/* mengambil angka-angka yang ada dalam bilangan, dimasukkan ke dalam array */
for (i = 1; i <= panjang_bilangan; i++) {
angka[i] = bilangan.substr(-(i),1);
i = 1;
j = 0;
kaLimat = "";
/* mulai proses iterasi terhadap array angka */
while (i <= panjang_bilangan) {
subkaLimat = "";
kata1 = "";
kata2 = "";
kata3 = "";
/* untuk Ratusan */
if (angka[i+2] != "0") {
if (angka[i+2] == "1") {
kata1 = "Seratus";
} else {
kata1 = kata[angka[i+2]] + " Ratus";
/* untuk Puluhan atau Belasan */
if (angka[i+1] != "0") {
if (angka[i+1] == "1") {
if (angka[i] == "0") {
kata2 = "Sepuluh";
} else if (angka[i] == "1") {
kata2 = "Sebelas";
} else {
kata2 = kata[angka[i]] + " Belas";
} else {
kata2 = kata[angka[i+1]] + " Puluh";
/* untuk Satuan */
if (angka[i] != "0") {
if (angka[i+1] != "1") {
kata3 = kata[angka[i]];
/* pengujian angka apakah tidak nol semua, lalu ditambahkan tingkat */
if ((angka[i] != "0") || (angka[i+1] != "0") || (angka[i+2] != "0")) {
subkaLimat = kata1+" "+kata2+" "+kata3+" "+tingkat[j]+" ";
/* gabungkan variabe sub kaLimat (untuk Satu blok 3 angka) ke variabel kaLimat */
kaLimat = subkaLimat + kaLimat;
i = i + 3;
j = j + 1;
/* mengganti Satu Ribu jadi Seribu jika diperlukan */
if ((angka[5] == "0") && (angka[6] == "0")) {
kaLimat = kaLimat.replace("Satu Ribu","Seribu");
return kaLimat + "Rupiah";
[/quote]
PLEASEEE................ YOUR HELP... -
Using convert function on nvarchar2
Hi experts,
I am having a bit of a problem with the convert function. We use convert to compare street- and citynames and ignore any special characters, such as é ç etc.
Something like:
select ...
from ...
where convert(new_street_name, 'US7ASCII') = convert(existing_street_name, 'US7ASCII')
This works fine if the datatype is varchar2, for instance:
SQL> select convert('äàáâçëèéêïìíîöòóôüùúûÿ','US7ASCII') text from dual;
TEXT
aaaaceeeeiiiioooouuuuy
If the datatype if nvarchar2 however, the result is not as expected:
SQL> select convert(cast('äàáâçëèéêïìíîöòóôüùúûÿ'as nvarchar2(64)),'US7ASCII') text from dual;
TEXT
慡慡捥敥敩楩楯潯潵畵
The NLS character settings on our database (10.2.0.4) are:
NLS_CHARACTERSET AL32UTF8 Character set
NLS_NCHAR_CONV_EXCP FALSE NLS conversion exception
NLS_NCHAR_CHARACTERSET AL16UTF16 NCHAR Character set
I have tried several combinations... but no luck so far. Is it possible to use convert on an nvarchar2 to go from é to e?
Maybe it is better just to use the translate function and define each conversion explicitly. Convert seemed a nice option because it works without any additional parameters... on a varchar2 at least
Thanks!The usage of convert is not encouraged by the docs and in my opinion it's rather by accident that this works in your specific case than something other.
What's going on?
Convert returns the char-datatype of the input.
We can use simple to_char to use the convert funtion in the way you intend.
(You shoud take care when handling n_char data in sql statements, especially in 10 g enviromnments. You have to set the environment parameter ORA_NCHAR_LITERAL_REPLACE=TRUE and use the n-prefix. Take a look at the globalization guide for more details.)
CREATE TABLE "TESTNCHAR"
( "ID" NUMBER,
"STR" NVARCHAR2(30),
"STR2" VARCHAR2(300)
insert into testnchar values (1, n'ßäàáâçëèéêïìíîöòóôüùúûÿ','ßäàáâçëèéêïìíîöòóôüùúûÿ')
select
id
,str,str2
,dump(str,1010) dmp
,dump(str2,1010) dmp2
,dump(convert(str,'US7ASCII')) dc
,dump(convert(str2,'US7ASCII')) dc2
,convert(to_char(str),'US7ASCII') c
,convert(str2,'US7ASCII') c2
from testnchar
ID
STR
STR2
DMP
DMP2
DC
DC2
C
C2
1
ßäàáâçëèéêïìíîöòóôüùúûÿ
ßäàáâçëèéêïìíîöòóôüùúûÿ
Typ=1 Len=46 CharacterSet=AL16UTF16: 0,223,0,228,0,224,0,225,0,226,0,231,0,235,0,232,0,233,0,234,0,239,0,236,0,237,0,238,0,246,0,242,0,243,0,244,0,252,0,249,0,250,0,251,0,255
Typ=1 Len=46 CharacterSet=AL32UTF8: 195,159,195,164,195,160,195,161,195,162,195,167,195,171,195,168,195,169,195,170,195,175,195,172,195,173,195,174,195,182,195,178,195,179,195,180,195,188,195,185,195,186,195,187,195,191
Typ=1 Len=23: 63,97,97,97,97,99,101,101,101,101,105,105,105,105,111,111,111,111,117,117,117,117,121
Typ=1 Len=23: 63,97,97,97,97,99,101,101,101,101,105,105,105,105,111,111,111,111,117,117,117,117,121
?aaaaceeeeiiiioooouuuuy
?aaaaceeeeiiiioooouuuuy
We can see that this already fails for ß.
To give you an idea of alternative approaches:
create table test_comp (nid number, str1 varchar2(300), str2 varchar2(300))
insert into test_comp values (1, 'ßäàáâçëèéêïìíîöòóôüùúûÿ','ssäàáâçëèéêïìíîöòóôüùúûÿ')
insert into test_comp values (2, 'ßäàáâçëèéêïìíîöòóôüùúûÿ','säàáâçëèéêïìíîöòóôüùúûÿ')
select
from test_comp
where
str2 like str1
no data found
select
from test_comp
where
upper(str2) like NLS_UPPER(str1, 'NLS_SORT = XGERMAN')
NID
STR1
STR2
1
ßäàáâçëèéêïìíîöòóôüùúûÿ
ssäàáâçëèéêïìíîöòóôüùúûÿ
Maybe you are looking for
-
Why can't i see my iCloud library on Apple tv
I am subscribed to iTunes Match. It works fine on the iPad, but does not show up as my iCloud library on the Apple TV. I can stream purchased iStore music. Any advice?
-
Adobe Reader 9 automatically closes
Whenever I open Adobe Reader 9.0, whether directly from the shortcut or through opening a pdf document, the program will close after approximately 10-20 seconds, with the usual "Adobe Reader 9.0 has encountered a problem and needs to close. We are so
-
Unable to Access Resource Error in AE CS6
Hello, I'm running After Effects CS6 11.0 on MAC OSX and everytime I attempt to apply text, either by creating a new text layer from the drop down menu or dragging open a text box I get "Unable to Access Resource P_TextSmallCaps_Sm_N_D (type png)
-
In 21 century, Skype is still written in Delphi
It's 2014 year now. Skype is owned by Microsoft. Desktop client is still written in Delphi. It's a shame! Such a great corporation could not find strong will and resources to throw out that Delphi garbage of 90s. And finally write a new client using
-
Error when creating basic pay (IT0008) in pa30
Dear Experts, Greetings! I am getting error when creating basic pay (IT0008) in pa30. Attached the print screen for the same. Kindly help me out. Thanks & Regards, Vamshi Krishna M