Query the Supply Order Interface data for the Sales Order - This informs SCO that a SCO order is to be created.
SELECT I.INTERFACE_BATCH_NUMBER ,
I.LINE_INTERFACE_ID ,
i.interface_source_code intf ,
i.supply_order_source src ,
h.supply_order_reference_number ,
H.SUPPLY_ORDER_REFERENCE_ID ,
i.supply_order_reference_line_id reflineid,
i.process_status sts ,
i.supply_type supply ,
i.inventory_item_id item ,
i.quantity qty ,
i.supply_operation oprn ,
i.supply_order_header_id supplyheader ,
i.creation_date ,
i.process_status ,
m.message_text ,
m.MESSAGE_NAME ,
m.TOKEN_NAME_A ,
m.TOKEN_VALUE_A ,
m.TOKEN_NAME_B ,
m.TOKEN_VALUE_B ,
m.TOKEN_NAME_C ,
m.TOKEN_VALUE_C
FROM fusion.dos_supply_lines_int i,
fusion.dos_messages m ,
fusion.dos_supply_headers_int h
WHERE m.processing_entity_type(+) = 'INTERFACE_LINE'
AND m.processing_entity_id(+) = i.line_interface_id
AND i.header_interface_id = h.header_interface_id
AND h.supply_order_reference_number IN ('&SOURCE_ORDER')
ORDER BY h.SUPPLY_ORDER_REFERENCE_NUMBER,
I.LINE_INTERFACE_ID ,
i.creation_date ASC;