DBA Data[Home] [Help]

APPS.GML_PO_RECV1_PKG SQL Statements

The following lines contain the word 'select', 'insert', 'update' or 'delete':

Line: 49

    SELECT po_no
    FROM   po_ordr_hdr
    WHERE  po_id = G_po_id;
Line: 54

    SELECT line_no
    FROM   po_ordr_dtl
    WHERE  line_id = G_poline_id;
Line: 84

    SELECT po_status
    FROM   cpg_oragems_mapping
    WHERE  po_id   = G_po_id
    AND    line_id = G_poline_id;
Line: 126

 |                and insert into the receiving interface table.          |
 |                                                                        |
 | MODIFICATION HISTORY                                                   |
 |   20-NOV-97  Kenny  ----  Created.                                     |
 |   26-JAN-99  T.Ricci removed and recv_status <> -1 in where for who    |
 |              column select BUG#795134                                  |
 |   23-NOV-99  NC deleted insert into cpg_receiving_interface.This table |
 |              nolonger exists in 11i.Instead, storing the data in global|
 |	 	vars which will be used later.                            |
 |   29-NOV-99  NC -ve received_qty's being sent to apps side if a receipt|
 |   		is voided after a return is made against it.Changed the   |
 |		received_qty to zero ( instead of a -ve number) in such   |
 |		cases.							  |
 |   04-FEB-2000 PB Bug# 1094230 - a voided return should be excluded form|
 |  		 the total returned quantity. 			          |
 | 		 If the received UOM is different that the Order UOM      |
 | 		 then the necessary conversions need to be made.Same      |
 | 		 applies to returned quantity			     	  |
 +========================================================================*/


  PROCEDURE sum_recv AS
    v_po_no           po_ordr_hdr.po_no%TYPE;
Line: 157

    v_last_updated_by   po_recv_dtl.last_updated_by%TYPE;
Line: 158

    v_last_update_login   po_recv_dtl.last_update_login%TYPE;
Line: 179

    SELECT po_no, orgn_code
    FROM   po_ordr_hdr
    WHERE  po_id = vc_po_id;
Line: 184

    SELECT line_no,ORDER_UM1, item_id
    FROM   po_ordr_dtl
    WHERE  po_id = vc_po_id AND
           line_id = vc_line_id;
Line: 190

    SELECT po_status
    FROM   po_ordr_dtl
    WHERE  po_id = vc_po_id AND
           line_id = vc_line_id;
Line: 196

    SELECT g.org_id
    FROM   gl_plcy_mst g, sy_orgn_mst o
    WHERE  o.orgn_code = v_orgn_code
    AND    o.co_code = g.co_code;
Line: 203

    SELECT NVL(sum(recv_qty1), 0),recv_um1
    FROM   po_recv_dtl
    WHERE  po_id       = G_po_id
    AND    poline_id   = G_poline_id
    AND    recv_status <> -1
    GROUP BY recv_um1;
Line: 211

    SELECT NVL(SUM(return_qty1), 0),return_um1
    FROM   po_rtrn_dtl dtl , po_rtrn_hdr hdr
    WHERE  dtl.po_id = G_po_id
    AND    dtl.poline_id = G_poline_id
    AND    dtl.return_id = hdr.return_id
    AND    hdr.delete_mark <> 1
    GROUP BY return_um1;
Line: 320

    SELECT NVL(SUM(return_qty1), 0)
    INTO   v_returned_qty
    FROM   po_rtrn_dtl dtl , po_rtrn_hdr hdr
    WHERE  dtl.po_id = G_po_id
    AND    dtl.poline_id = G_poline_id
    AND    dtl.return_id = hdr.return_id;
Line: 328

    SELECT NVL(sum(recv_qty1), 0)
    INTO   v_received_qty
    FROM   po_recv_dtl
    WHERE  po_id       = G_po_id
    AND    poline_id   = G_poline_id
    AND    recv_status <> -1;
Line: 338

    SELECT created_by, last_updated_by, last_update_login
    INTO   v_created_by, v_last_updated_by, v_last_update_login
    FROM   po_recv_dtl
    WHERE  po_id       = G_po_id
    AND    poline_id   = G_poline_id
/*    AND    recv_status <> -1 */
    AND last_update_date = (select max(last_update_date) from po_recv_dtl
    WHERE  po_id       = G_po_id
    AND    poline_id   = G_poline_id);
Line: 421

      GML_PO_RECV2_PKG.update_line_locations (v_po_header_id,
                             v_po_line_id,
                             v_line_location_id,
                             v_po_release_id,
                             G_org_id,
                             G_po_status,
                             G_actual_received_qty,
                             G_returned_qty,
                             G_created_by,
                             SYSDATE);