Tuesday, 24 December 2013

Purchase module sub-query in oracle apps

/* Formatted on 12/24/2013 6:18:41 PM (QP5 v5.114.809.3010) */
SELECT   segment1
  FROM   po_headers_all
 WHERE   po_header_id IN (SELECT   po_header_id
                            FROM   po_lines_all
                           WHERE   po_header_id = 756464)


/* Formatted on 12/24/2013 6:20:35 PM (QP5 v5.114.809.3010) */
SELECT   segment1
  FROM   po_headers_all
 WHERE   po_header_id IN
               (SELECT   po_header_id
                  FROM   po_lines_all
                 WHERE   po_header_id IN (SELECT   po_header_id
                                            FROM   po_distributions_all
                                           WHERE   po_header_id = 756464))
                                         
                
/* Formatted on 12/24/2013 6:30:32 PM (QP5 v5.114.809.3010) */
SELECT   segment1
  FROM   po_headers_all
 WHERE   po_header_id IN
               (SELECT   po_header_id
                  FROM   po_lines_all
                 WHERE   po_header_id IN
                               (SELECT   po_header_id
                                  FROM   po_distributions_all
                                 WHERE   PO_DISTRIBUTION_ID IN
                                               (SELECT   PO_DISTRIBUTION_ID
                                                  FROM   rcv_transactions
                                                 WHERE   PO_DISTRIBUTION_ID =
                                                            53129)))
                                                           
                                                           
                                                           
/* Formatted on 12/24/2013 6:46:27 PM (QP5 v5.114.809.3010) */
SELECT   segment1
  FROM   po_headers_all
 WHERE   po_header_id IN
               (SELECT   po_header_id
                  FROM   po_lines_all
                 WHERE   po_header_id IN
                               (SELECT   po_header_id
                                  FROM   po_distributions_all
                                 WHERE   PO_DISTRIBUTION_ID IN
                                               (SELECT   PO_DISTRIBUTION_ID
                                                  FROM   rcv_transactions
                                                 WHERE   SHIPMENT_LINE_ID IN
                                                               (SELECT   SHIPMENT_LINE_ID
                                                                  FROM   RCV_SHIPMENT_LINES
                                                                 WHERE   SHIPMENT_LINE_ID =
                                                                            3011))))


/* Formatted on 12/24/2013 7:23:19 PM (QP5 v5.114.809.3010) */
SELECT   segment1
  FROM   po_headers_all
 WHERE   po_header_id IN
               (SELECT   po_header_id
                  FROM   po_lines_all
                 WHERE   po_header_id IN
                               (SELECT   po_header_id
                                  FROM   po_distributions_all
                                 WHERE   PO_DISTRIBUTION_ID IN
                                               (SELECT   PO_DISTRIBUTION_ID
                                                  FROM   rcv_transactions
                                                 WHERE   SHIPMENT_LINE_ID IN
                                                               (SELECT   SHIPMENT_LINE_ID
                                                                  FROM   RCV_SHIPMENT_LINES
                                                                 WHERE   SHIPMENT_LINE_ID IN
                                                                               (SELECT   SHIPMENT_LINE_ID
                                                                                  FROM   RCV_SHIPMENT_HEADERS
                                                                                 WHERE   SHIPMENT_LINE_ID =
                                                                                            3005)))))

No comments:

Post a Comment