Skip to Content
0
May 17, 2016 at 10:15 AM

ABAP 7.40: Accessing a part of a shifted field

36 Views

Hi,

I am still in trouble with ABAP 7.40, sometimes 😉

DATA:
charact TYPE c LENGTH 10 VALUE 'BLABLABLUB',
target TYPE c LENGTH 10.

target = shift_right( val = charact circular = 4 ).

IF target(4) EQ 'BLUB'.
* ....
ENDIF.

I'd like to have an alternative coding without field "target", which is needed for "target(4)"-expression. What I mean is a

IF shift_right( val = charact circular = 4 )(4) EQ 'BLUB'. " <= of course, this does not work 😉

* ....
ENDIF.

Anybody out there, who can help me?