Application Development 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: 

How to convert character to DEC data type

Former Member
0 Kudos

I need to convert Char type to DEC type.

4 REPLIES 4

former_member387317
Active Contributor
0 Kudos

go thorough the below links..

Hope it will solve your problem

Thanks & Regards

ilesh 24x7 [:)]

Former Member
0 Kudos

Hi,

The source field must contain the representation of a decimal number, that is, a

sequence of digits with an optional sign and no more than one decimal point. The

source field can contain blanks. If the target field is too short, an overflow may occur. This may cause the system to terminate the program.

Regards,

Bhaskar

Former Member
0 Kudos

Hi Jose,

This is an answered link. Go through this.

Reward me with points, if it is useful.

Regards,

Sagar

Former Member
0 Kudos

Hi,

DATA: char TYPE char10 VALUE '25,786.50'.

DATA: pac(10) TYPE p DECIMALS 2.

REPLACE ALL OCCURRENCES OF ',' IN char WITH space.

CONDENSE char NO-GAPS.

PAC = CHAR.