Hello Experts,
Please suggest flow logic to buld alv for single and double bounce sales order.
requirment as follow
The selection screen need to have two fields.
One is Sales Organisation. And second is the date range, both are mandatory.
The output needs to display the following fields
Sales Org(Manufacturing) Sales order(Manufacturing) Sales Org(Originating) Sales Order(Originating) Customer Number(From Originating sales order)
some logic provide by them
Based on the selection criteria, VBAK need to be used to
capture all the sales orders that have been created in that date range by using
VBAK-AUDAT.
Extract sales orders of type ZGOR only by checking
VBAK-AUART.
For each order, check the VBKD-BSTKD to get the Purchase
order number.
And immediately check
EKKN VBELN to see if it has any account assignment.
If it has no value in EKKN-VBELN, ignore that sales order.
If the PO has value in EKKN-VBELN, then that is the sales
order number from associate.
Get the PO number from VBKD-BSTKD and check if it has any
value in EKKN-VBELN again.
If it does not exist,
display the sales order and the corresponding details in the output.
This corresponds to Single Bounce.
If EKKN-VBELN exists, then that is the sales order number
from the associate.
Get the PO number from VBKD-BSTKD and check if it has any
value in EKKN-VBELN again.
If it does not exist,
display the sales order and the corresponding details in the output.
This corresponds to Double Bounce.