hi all
can anyone tell me for wat this table p_gt_variant_fieldcat is used in this form because it is not used anywhere else in the program and also the variable w_field
FORM include_customer_number
TABLES p_gt_variant_fieldcat STRUCTURE gt_variant_fieldcat.
DATA w_field TYPE slis_fieldcat_alv.
LS_FIELDCAT-FIELDNAME = 'LIFNR'.
LS_FIELDCAT-TABNAME = 'GT_COVP_EXT'.
LS_FIELDCAT-SELTEXT_M = 'Vendor Number'.
APPEND ls_fieldcat TO p_gt_variant_fieldcat.
LS_FIELDCAT-FIELDNAME = 'NAME1'.
LS_FIELDCAT-TABNAME = 'GT_COVP_EXT'.
LS_FIELDCAT-SELTEXT_M = 'Vendor Name'.
APPEND ls_fieldcat TO p_gt_variant_fieldcat.
DESCRIBE TABLE <gt_pos_data> LINES t_lines.
DO t_lines TIMES.
READ TABLE <gt_pos_data> INDEX sy-index INTO s_output.
APPEND s_output TO t_output.
enddo.
SELECT ekkoebeln ekkolifnr lfa1~name1
INTO CORRESPONDING FIELDS OF TABLE t_lifnr
FROM ( ekko
INNER JOIN lfa1
ON ekkolifnr = lfa1lifnr )
FOR ALL ENTRIES IN t_output
WHERE ebeln = t_output-ebeln.
SORT t_lifnr BY ebeln.
LOOP AT t_output INTO s_output.
READ TABLE t_lifnr WITH KEY ebeln = s_output-ebeln.
s_output-lifnr = t_lifnr-lifnr.
s_output-name1 = t_lifnr-name1.
MODIFY t_output FROM s_output.
ENDLOOP.
ASSIGN t_output to <gt_pos_data>.
ENDFORM.