Skip to Content
0
May 08, 2020 at 01:13 PM

Deep for statment

86 Views

Hi All ,


I am testing below example found in web .

I am getting no result into lt_final table as there are no values in lt_makt table . Can somebody suggest that how to validate tables are initial or not .

DATA(lt_final) = VALUE ty_t_final( FOR ls_ekpo IN lt_ekpo
FOR ls_ekko IN lt_ekko FROM line_index( lt_ekko[ ebeln = ls_ekpo-ebeln ] )
WHERE ( ebeln = ls_ekpo-ebeln )
FOR ls_makt IN lt_makt FROM line_index( lt_makt[ matnr = ls_ekpo-matnr ] )
WHERE ( matnr = ls_ekpo-matnr )
FOR ls_t001w IN lt_t001w FROM line_index( lt_t001w[ werks = ls_ekpo-werks ] )
WHERE ( werks = ls_ekpo-werks )
LET ls_final = VALUE ty_final(
lifnr = ls_ekko-lifnr
maktx = ls_makt-maktx
name1 = ls_t001w-name1 )
IN ( CORRESPONDING #( BASE ( ls_final ) ls_ekpo ) ) ).

Regards,

Srikanth