TO track Requisition NUMBER FROM PO NUMBER
===========================================
SELECT segment1
FROM po_requisition_headers_all
WHERE requisition_header_id IN (SELECT requisition_header_id
FROM po_requisition_lines_all
WHERE requisition_line_id IN (SELECT requisition_line_id
FROM po_req_distributions_all
WHERE distribution_id IN
(SELECT req_distribution_id
FROM po_distributions_all
WHERE po_header_id IN
(SELECT po_header_id
FROM po_headers_all
WHERE segment1 =<<Give PO Number>>)
)
)
);
===========================================
SELECT segment1
FROM po_requisition_headers_all
WHERE requisition_header_id IN (SELECT requisition_header_id
FROM po_requisition_lines_all
WHERE requisition_line_id IN (SELECT requisition_line_id
FROM po_req_distributions_all
WHERE distribution_id IN
(SELECT req_distribution_id
FROM po_distributions_all
WHERE po_header_id IN
(SELECT po_header_id
FROM po_headers_all
WHERE segment1 =<<Give PO Number>>)
)
)
);
No comments:
Post a Comment