Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Runtime error - conversion

Former Member
0 Likes
1,074

CONVT_NO_NUMBER runtime error.

Error - Unable to interpret "100.000.00 " as a number.

Any solutions and reason why this error occured?

7 REPLIES 7
Read only

Former Member
0 Likes
947

Hello,

Are you trying to assign the value 100.000.00 to a variable of type i. If so, change the data type to type P.

Hope this helps.

Regards,

Sachin

Read only

0 Likes
947

@ Sachin,

ok...any other solution do u have.... is the number format correct... moreover the the user wants to see it as full.... will using 'pack' solve it?

Read only

0 Likes
947

Hello,

When assigning to a type p variable you will not send the thousand separator as in your case it ','.

data amt type p decimals 2.

amt = '100000.00'.

Now depending on your user settings (which you can check by System->User Profile->Own Data Defaults tab), it will display the complete text with appropriate thousand separator and decimal operators.

Hope this helps

Regards,

Sachin

Read only

Former Member
0 Likes
947

Try moving your character field containing '100.000.00' to a TYPE N field in the correct length (i.e DATA nnn(10) TYPE N.

Then move your TYPE N field to a TYPE P or I field, as required.

Read only

rainer_hbenthal
Active Contributor
0 Likes
947

The runtime ha scompletly right, 100.000.00 is not a number.

100.000,00 is a number

100000,00 is a number

100000.00 is a number

Thousands seperator and decimal fraction indicator in a valid number are never the same. I case of thousand separator all blocks except the most left one needs three digits.

In case of thousands separator you need to delete them and the fractional divider needs to be a dot, that can be interpreted by the runtime.

Read only

kesavadas_thekkillath
Active Contributor
0 Likes
947

Please paste the declaration of variables and the particular LOC from the source code extract of the dump.

Read only

Former Member
0 Likes
947

Search forums...there are 250 hits in forums for CONVT_NO_NUMBER, but the answer is probably always the same....digits, a decimal point and a +/- sign make a number, thousands separators make it a character string.