07-10-2006 3:05 PM
Can i put an include(of a SAP table) during my structure definition ? I know that is possible in an internal table definition, but something got me wrong when i try to insert a include into a structure, see bellow :
BEGIN OF E_COMP,
INCLUDE ZM098, "other SAP table
SOMA(5) TYPE P,
DATA TYPE D,
END OF E_COMP.
07-10-2006 3:07 PM
07-10-2006 3:07 PM
07-10-2006 3:07 PM
data : BEGIN OF E_COMP,
INCLUDE structure ZM098. "other SAP table
data :SOMA(5) TYPE P,
TYPE D,
END OF E_COMP.
regards
srikanth
07-10-2006 3:07 PM
You need to mention the keyword STRUCTURE after INCLUDE.
i.e. INCLUDE STRUCTURE ZM098.
-Kiran
07-10-2006 3:07 PM
Try like this
DATA:BEGIN OF E_COMP,
INCLUDE ZM098. "other SAP table
DATA: SOMA(5) TYPE P,
TYPE D.
DATA: END OF E_COMP.
If useful reward points.
Regards,
Vasanth
07-10-2006 3:09 PM
HI,
Check it out
replace the include statement with
INCLUDE STRUCTRE ZM098.
Regards,
Naveen
07-10-2006 3:09 PM
Hi Andre,
the following code should work
DATA BEGIN OF E_COMP,
INCLUDE STRUCTURE ZM098.
DATA: SOMA(5) TYPE P,
DATA TYPE D,
END OF E_COMP.
Regards, Manuel
07-10-2006 3:10 PM
hai
Check the bellow Structure Declaration
the changes in bold characters
<b>data: begin of e_comp.
include structure zm098.
data: soma(5) type p,
data type d.
data: end of e_comp.</b>
Thanks & regards
Sreeni
07-10-2006 3:19 PM
HI Andre.
REPORT zarun_2.
DATA : BEGIN OF e_comp <b>OCCURS 0</b>. "Internal table with header line
INCLUDE STRUCTURE emara. <b>"Include Structure in MARA table</b>
DATA : soma(5) TYPE p,
data TYPE d,
END OF e_comp.
Regards,
Arun Sambargi.
07-10-2006 6:13 PM
hi all,
Tks for those who answered me, but the right addiction was it :
TYPES : BEGIN OF E_COMP.
INCLUDE STRUCTURE ZM098.
TYPES : TESTE LIKE ZM098-VALOR_01,
END OF E_COMP.
tks everybody,
André