Hi i have select select like this
SELECT likp~vbeln
lips~posnr
likp~kunnr
lips~lfimg
lips~uecha
lips~matnr
lips~lgort
lips~charg
lips~vgbel
lips~arktx
lips~werks
likp~wadat_ist
kna1~name1
FROM likp INNER JOIN lips ON lipsvbeln = likpvbeln
INNER JOIN kna1 ON kna1kunnr = likpkunnr
INNER JOIN ekko ON ekkoebeln = lipsvgbel
INNER JOIN vbup ON vbupvbeln = lipsvbeln
AND vbupposnr = lipsposnr
APPENDING corresponding fields of table itab
FOR ALL ENTRIES IN i
WHERE likp~vbeln = i-vbeln
AND likp~wadat_ist IN s_wadat
AND ( likplfart = 'NL' OR likplfart = 'NLCC')
AND kna1~land1 IN s_land1
AND vbup~wbsta IN r_wbsta.
here s_land1 is Ship to country code
r_wbsta is delivery status (range)
s_wadat is Goods Issue Date from selection screen
and table i is the following
SELECT vbeln FROM vlkpa INTO TABLE i
WHERE vkorg IN s_vkorg "Sales org from selection screen
AND lfart IN r_lfart. "this is a range of delivery types passed
I need help in breaking down that select statement as it is going for time out.
any suggesstions?