01-16-2006 11:17 AM
&----
*
& Include zzzzzzz
&----
data : begin of itab2 occurs 0,
matnr like knmt-matnr,
kdmat like knmt-kdmat,
maktx like makt-maktx,
matkl like mara-matkl,
bismt like mara-bismt,
end of itab2.
select matnr
into knmt-matnr
from knmt.
if sy-subrc = 0.
itab2-matnr = knmt-matnr.
append itab2.
endif.
endselct.
i get err
"statment is not accessible.
01-16-2006 11:19 AM
u give declaration
tables knmt.
and use the following
select single matnr kdmat
into (knmt-matnr , knmt-kdmat ).
01-16-2006 11:22 AM
01-16-2006 11:26 AM
The code you have pasted above will not work, because the sy-subrc check should come AFTER the endselect, and not before.
Maybe that is the error?
Hope this helps.
Sudha
01-16-2006 11:22 AM
Hi,
May be put start-of-selection statement before select statement
01-16-2006 11:22 AM
Hi Liat,
I copy-pasted yoour code and it is giving no error for me.
except for the spelling of endslect should be endselect.
01-16-2006 11:25 AM
Hi,
try that:
SELECT matnr
FROM knmt
APPENDING CORRESPONDING FIELDS OF TABLE itab2.
regards Andreas
01-16-2006 11:35 AM
01-16-2006 12:12 PM
01-16-2006 12:13 PM
i mad this alone
data : begin of itab2 occurs 0,
matnr like knmt-MATNR,
kdmat like knmt-kdmat,
maktx like makt-maktx,
matkl like mara-matkl,
bismt like mara-bismt,
end of itab2.
and i get the same err
01-16-2006 12:19 PM
do as andreas mann already proposed:
SELECT matnr
FROM knmt
APPENDING CORRESPONDING FIELDS OF TABLE itab2.
this most likely what you want to.
Regards
René
01-16-2006 12:37 PM
Can you paste the error in some detail? For eg, which module/include, line no, etc?
Sudha