Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR SQL

Components/Fields of Internal Table

DATA : it_mara TYPE STANDARD TABLE OF mara  WITH HEADER LINE.

DATA : it_detail   TYPE abap_compdescr_tab,
           wa_comp TYPE abap_compdescr.

DATA : ref_descr TYPE REF TO cl_abap_structdescr.

ref_descr ?= cl_abap_typedescr=>describe_by_data( it_mara ).
it_detail[] = ref_descr->components .

loop at it_detail into wa_comp.
write:/ wa_comp-name .
endloop.
Source by answers.sap.com #
 
PREVIOUS NEXT
Tagged: #Internal #Table
ADD COMMENT
Topic
Name
6+6 =