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: 

strange problem

Former Member
0 Kudos

I had declare a constant like

C_AST_VAL LIKE PRPS-ASTNR VALUE 'INCRC300',

when i trying to move into internal table like

MOVE C_AST_VAL TO i_FINAL_COM-ASTNR.

i_final is same as a custom table which is prps-astnr.

but it is always passing this value 00000300 .

even i tried to replace C_AST_VAL WITH hardcode value still it has same value 00000300 .

I THINK problem is with PRPS table , which has 2 fields

with same name . plz some body who has worked help me.

Thanks,

sridhar .

7 REPLIES 7

Former Member
0 Kudos

Hi,

It is because PRPS-ASTNR is a numeric character(Character string with only digits).

You cannot store alphabetical characters in that.

Regards,

Wenceslaus.

LucianoBentiveg
Active Contributor
0 Kudos

When you declare

C_AST_VAL LIKE PRPS-ASTNR VALUE 'INCRC300',

C_AST_VAL is filled with '00000300' becose is a NUMC field.

0 Kudos

thanks,

but with numc we store both char and numbers , why char are ingored.

thanks,

sridhar

0 Kudos

Hi,

NUMC is a field with only numeric characters.

We cannot store alphabets in them.

Ps: Reward helpful posts.

Regards,

Wenceslaus.

0 Kudos

hi sridhar

with numc can have only digits not alphabetic char's that is y it is not accepting characters and it is taking it as 0's.

regards,

sandhya

Former Member
0 Kudos

Hi,

I couldnt see PRPS having ASTNR repeated, r u talking bout ASTNR and ASTNA.

Sharath.

Former Member
0 Kudos

Hi,

As per SAP help definition -

NUMC

Character string that may only contain digits. The length of a field of this type is limited to a maximum of 255 places.