‎2007 Jun 23 2:15 PM
Hi Genius,
Could you please tell me how to check the internal table entries using select options in a subroutine i.e if the entry exists in a range of select-options it is to be taken otherwise it is to be neglected.
I will definitely reward gd point to u but tell me in any case,
Thnx ,
Rahul.....................................................
‎2007 Jun 23 2:40 PM
Here is the simple example ->
tables : mara.
data : i_mara like mara occurs 0 with header line.
select-option s_matnr for mara-matnr.
start-of-selection.
select * from mara into table i_mara
where matnr <b>in s_matnr.</b>
if sy-subrc ne 0.
give error message " No data found ".
endif.
for internal table
loop at i_mara where field in s_matnr
endloop.
Thanks
Seshu
Message was edited by:
Seshu Maramreddy
Message was edited by:
Seshu Maramreddy
‎2007 Jun 23 2:41 PM
‎2007 Jun 23 3:14 PM
hi Rahul
try the following code
select options : s_options for mara-matnr.
select * from mara into corresponding fields of <itab> where matnr in s_options.
if sy-subrc eq 0.
code....
else .
message e001(<message class>)." define message class in se93 and define message there.
endif.
regards
ravish
<b>plz dont forget to reward point if useful</b>