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

internal table

Former Member
0 Likes
444

Hi,

My internal table consists of

user

xxx

yyy

anil

anil

anil

zzzz

I have to call the funtion module if it is not 'anil'. we should not loop-endloop between func module. outside we have to check the above condition.

How to acheive this effectively.

Regards,

Ratna

4 REPLIES 4
Read only

Former Member
0 Likes
424

u calll put like this.

sort itab by field.

read itab with key field = 'anil'.

if sy-subrc ne 0.

call FM

else.

endif.

check performance of read

Regards

prabhu

Read only

Former Member
0 Likes
424

hi,

first sort ur interal table .

then DELETE ADJACENT DUPLICATES FROM INTERNAL TABLE.

then call ur FM.

Rewards with point if helpful.

Regards

Santosh

Read only

Former Member
0 Likes
424

Hi

Check for the user 'ANIL' with READ statement

if sy-subrc ne 0. call the FM. endif.

Thanks

Sandeep

Read only

0 Likes
424

You can also do

LOOP AT itab WHERE user <> 'Anil'

CALL FM .

ENDLOOP .