Hi good day to all, i am new to abap,
can any one solve my problem pls.
don't use innerjions and for all entries.
use two select stmts like this .
but here data is not retriving...pls solve my problem.
this is my task
Tables : marc,
mara.
Data : Begin of itab occurs 0,
matnr like marc-matnr,
werks like marc-werks,
pstat like marc-pstat,
bwtty like marc-bwtty,
ersda like mara-ersda,
ernam like mara-ernam,
mtart like mara-mtart,
mbrsh like mara-mbrsh,
end of itab.
select-options : s_matnr for marc-matnr.
start-of-selection.
select matnr
werks
pstat
bwtty
from marc
into corresponding fields of itab
where matnr in s_matnr.
APPEND ITAB.
endselect.
SELECT MATNR
ERSDA
ERNAM
MTART
MBRSH
FROM MARA
into
CORRESPONDING FIELDS OF ITAB
WHERE MATNR = ITAB-MATNR.
append ITAB.
ENDSELECT.
end-of-selection.
write : /1 sy-vline , 2 'MaterialNo',
10 sy-vline , 12 'Plant',
20 sy-vline , 22 'MaintStatus',
40 sy-vline , 42 'Valu Catgry',
60 sy-vline , 62 'CreatDate',
80 sy-vline , 82 'NamePerson',
100 sy-vline , 102 'MatrlType',
120 sy-vline , 122 'Ind Sector',
140 sy-vline.
loop at itab.
write : /1 sy-vline , 2 itab-matnr,
10 sy-vline , 12 itab-werks,
20 sy-vline , 22 itab-pstat,
40 sy-vline , 42 itab-bwtty,
60 sy-vline , 62 itab-ersda,
80 sy-vline , 82 itab-ernam,
100 sy-vline , 102 itab-mtart,
120 sy-vline , 122 itab-mbrsh,
140 sy-vline.
Endloop.
Thaks&Regards
Suresh