Quantcast
Channel: SCN: Message List
Viewing all articles
Browse latest Browse all 9076

Re: Creating internal table Using INCLUDE STRUCTURE

$
0
0

Hello Karthi,

 

Try with the below declarations.

 

DATA: BEGIN OF ty_employee.

         INCLUDE TYPEzkarthi_student.

         INCLUDE TYPEzkarthi_marks AS marks RENAMING WITH SUFFIX _mark.

DATA: END OF ty_employee.


Also refer to the below example provided by SAP in F1 help of the statement.


Example from SAP


In this example, the structure week is defined by repeated copying of the components in the structured type t_day. The components for week are all on one level and can be addressed as follows: week-work_mon, week-free_mon, week-work_tue, and so on. Alternatively, however, the following address method is also possible: week-monday-work, week-monday-free, week-tuesday-work, and so on.

TYPES: BEGIN OF t_day,
         work TYPE c LENGTH 8,
         free TYPE c LENGTH 16,
       END OF t_day.

DATA BEGIN OF week.
  INCLUDE TYPE t_day AS monday    RENAMING WITH SUFFIX _mon.
  INCLUDE TYPE t_day AS tuesday   RENAMING WITH SUFFIX _tue.
  INCLUDE TYPE t_day AS wednesday RENAMING WITH SUFFIX _wed.
  ...
DATA END OF week.

Regards,

Thanga


Viewing all articles
Browse latest Browse all 9076

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>