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: 

ABAP HELP!!!!?

Former Member
0 Kudos
77

Dear All,

I have a couple of issues:

1) Can we use any FM to convert Character from lower Case to UPPER case

Please share the names of those Function module ex: Golden = GOLDEN

2) I have a code (IF statement) which is not working can you Please tell me WHY

Do I need to use ( ).

if sy-subrc = 0 and it_summ-spmon <> sy-datum+0(6) .

it_summ-begin_inv = it_summ_new-enroute_inv + it_summ_new-whse_en_inv.

endif.

Please HELP!!!!

7 REPLIES 7

Former Member
0 Kudos
49

Hi

1) Can we use any FM to convert Character from lower Case to UPPER case

Please share the names of those Function module ex: Golden = GOLDEN

TRANSLATE <string> TO UPPER CASE.

Max

Message was edited by:

max bianchi

Manohar2u
Active Contributor
0 Kudos
49

1. AIPC_CONVERT_TO_UPPERCASE

2. move to local variable and compare

Former Member
0 Kudos
49

hi,

1) use the FM SWA_STRING_TO_UPPERCASE.

regards,

priya.

ferry_lianto
Active Contributor
0 Kudos
49

Hi,

1. No need FM. You can use translate statement.

TRANSLATE <fieldname> to UPPERCASE.

2. You can not compare SPMON with SY-DATUM0(6) if SPMON4(2) is week/accounting period instead of month.

Regards,

Ferry Lianto

Former Member
0 Kudos
49

1) Can we use any FM to convert Character from lower Case to UPPER case

Please share the names of those Function module ex: Golden = GOLDEN

<b>

Use TRANSLATE command to convert case.</b>

2) I have a code (IF statement) which is not working can you Please tell me WHY

Do I need to use ( ).

Try this:

<b>if sy-subrc EQ 0.

if it_summ-spmon NE sy-datum+0(6) .

</b> it_summ-begin_inv = it_summ_new-enroute_inv + it_summ_new-whse_en_inv.

endif.

Thanks,

Santosh

Former Member
0 Kudos
49

Hi

Check the field it_summ-spmon perhaps it's long 7 char,

SY-DATUM(6) = '200702'

IT_SUMM-SPMON = '2007002'.

They are the same meaning but different value.

Max

Former Member
0 Kudos
49

Thanks for everyone who took time to answer my question...