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

can anyone explain me the abap code ?

Former Member
0 Likes
662

Hi gurus,

can any one explain me about this code please

IF rsallowedchar-allowchar IS INITIAL.

SELECT SINGLE

allowchar

INTO (rsallowedchar-allowchar)

FROM rsallowedchar

WHERE allowkey = 'S'.

ENDIF.

regards

raju

Hi gurus,

can any one explain me about this code please

IF rsallowedchar-allowchar IS INITIAL.

SELECT SINGLE

allowchar

INTO (rsallowedchar-allowchar)

FROM rsallowedchar

WHERE allowkey = 'S'.

ENDIF.

regards

raju

4 REPLIES 4
Read only

Former Member
0 Likes
609

this check if the field rsallowedchar-allowchar is empty

before it does the select

if it is empty it selects from table rsallowedchar the first value it finds

into field rsallowedchar-allowchar

where the field allowkey in table rsallowedchar is equal to S

Read only

Former Member
0 Likes
609

IF rsallowedchar-allowchar IS INITIAL.

if the above condition is true it wil get the single record from rsallowedchar

into rsallowedchar-allowchar where the condition allowkey = 's'.

SELECT SINGLE

allowchar

INTO (rsallowedchar-allowchar)

FROM rsallowedchar

WHERE allowkey = 'S'.

ENDIF.

Read only

Former Member
0 Likes
609

Hi Venkata Raju

If field allowchar is initial and field allowkey is equal to 's' then

a single record is fetched from Table rsallowedchar and inserted into

field allowchar.

bye -

Naresh-

Read only

Sathish
Product and Topic Expert
Product and Topic Expert
0 Likes
609

'rsallowedchar' is a table. 'allowchar' is a field in the structure rsallowedchar.

IF rsallowedchar-allowchar IS INITIAL.

this line does a check whether the field allowchar is empty or not. If it is empty then a selection is made from the table reading one row of records matching the condition when allowkey is 'S'.

Hope this gave a clear explanation.