Search 800 + Posts

Dec 16, 2010

Query to Connect Order Management , Requisition ,Purchasing tables for Drop Ship

Query to Connect Order Management , Requisition ,Purchasing tables for Drop Ship 

select h.order_number,l.line_number SO_Line_number,  ph.segment1
PO_Number,pl.line_num PO_Line_Number,
ph.authorization_status,ph.closed_date,ph.closed_code,
prh.interface_source_code,
prh.segment1 Requisition_number, prl.line_num Requisition_line_number
from
OE_DROP_SHIP_SOURCES ods,
oe_order_headers_all h,
oe_order_lines_all l,
  po_line_locations_all pll,
po_lines_all pl,
po_headers_all ph,
po_requisition_headers_all prh,
po_requisition_lines_all prl
where h.header_id = l.header_id
and h.header_id = ods.header_id
and ods.line_location_id = pll.line_location_id
and ods.po_header_id = ph.po_header_id
and ods.po_line_id = pl.po_line_id
and ph.po_header_id = pl.po_header_id
and prh.requisition_header_id = ods.requisition_header_id
and prl.requisition_line_id = ods.requisition_line_id
and prh.requisition_header_id = prl.requisition_header_id
and h.order_number = &sales_order_number

No comments:

Post a Comment