Page 1 of 1

FOR ALL ENTRIES

PostPosted: Wed Jul 19, 2017 2:23 am
by sapmanie
Hi,
Does a field need to be defined in the internal table for the SELECT on matnr to work? As this gives an error.

Code: Select all
report ztest.
data: itab type table of matnr,
         istab type matnr.

istab = '1'.
append istab to itab.
istab = '2'.
append istab to itab.

select * from mara into table imat for all entries in itab [b]where matnr = itab[/b].

Re: FOR ALL ENTRIES

PostPosted: Wed Jul 19, 2017 9:02 am
by Rich
Yes.

Re: FOR ALL ENTRIES

PostPosted: Thu Aug 24, 2017 7:19 am
by Gothmog
Use:
Code: Select all
where matnr = itab-table_line

Re: FOR ALL ENTRIES

PostPosted: Wed Aug 30, 2017 9:19 am
by VLozano
Gothmog wrote:Use:
Code: Select all
where matnr = itab-table_line

I will vote for define the table properly, with a BEGIN w_mat, a material field, and so.

Just for readability.