Skip to Content
Former Member
Feb 27, 2007 at 12:53 AM

shipping point and delivery creation date


Hi :

im selecting sales orders , items and schedule line

from a custom table based on plant, shipping point and delivery creation date.

Is there any relation between Schedule lines and delivery creation date.

For delivery creation date d_date = SY-DATUM, and should select Mat Avail dt MBDAT or Trans. planning dt TDDAT which ever comes earlier.

vbep-edatu = itab-d_date.

select a1belnr a1posnr vbep~etenr into corresponding fields of table itab from a1 inner join vbap

on a1belnr = vbapvbeln

inner join vbep on a1posnr = vbepposnr

where a1~werks = p_werks

AND vbap~vstel = p_vstel

AND vbep~edatu = p_edatu

AND (vbep~mbdat <= p_edatu OR

vbep~tddat <= p_edatu ).

can anyone help me with this select statement.