SELECT likp~vbeln likp~lfart lips~werks likp~kunnr
INTO CORRESPONDING FIELDS OF TABLE it_likps
FROM likp INNER JOIN lips
ON likp~vbeln = lips~vbeln
FOR ALL ENTRIES IN it_ztmt204
WHERE posnr = ''
AND likp~vbeln = it_ztmt204-vbeln.
FOR ALL ENTRIES IN ,与 INNER JOIN 不要写在一个SQL上,
执行效率比想象的差很多,特别是FOR的内表大的时候……。