DBA Data[Home] [Help]

APPS.GMI_MO_PURGE SQL Statements

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

Line: 26

  select line_id, flow_status_code, open_flag, cancelled_flag
    from oe_order_lines_all lines
   where lines.flow_status_code in('CLOSED','CANCELLED')
     and ship_from_org_id=p_organization_id
     and trunc(lines.creation_date) between l_date_from and l_date_to;
Line: 33

 SELECT  trans_id
   FROM  ic_tran_pnd itp
  WHERE  doc_type = 'OMSO'
    AND  trans_qty = 0
    AND  lot_id    = 0
    AND  delete_mark = 0
    AND  completed_ind = 0
    AND  line_detail_id is NULL
    AND  line_id = p_line_id;
Line: 44

  SELECT  icl.line_id,
          icl.header_id
    FROM  ic_txn_request_lines   icl
   where  icl.line_status = 5
     and  icl.txn_source_line_id = p_line_id;
Line: 51

   select count(*)
   from   wsh_delivery_details wdd
   where  wdd.source_line_id=p_line_id
   and    wdd.source_code='OE'
   and    wdd.inv_interfaced_flag = 'Y';
Line: 79

           update ic_Tran_pnd
           set delete_mark=1
           where trans_id= c1rec.trans_id;
Line: 100

         v_sql_stmt := 'CREATE TABLE IC_TXN_REQUEST_HEADERS_BAK AS SELECT * FROM IC_TXN_REQUEST_HEADERS WHERE 1=2';
Line: 111

         v_sql_stmt := 'CREATE TABLE IC_TXN_REQUEST_LINES_BAK AS SELECT * FROM IC_TXN_REQUEST_LINES WHERE 1=2';
Line: 157

			 'INSERT INTO IC_TXN_REQUEST_LINES_BAK ' ||
			 '(SELECT * FROM IC_TXN_REQUEST_LINES  ' ||
			 ' WHERE line_id = :1) ';
Line: 164

			 'INSERT INTO IC_TXN_REQUEST_HEADERS_BAK ' ||
			 ' (SELECT * FROM IC_TXN_REQUEST_HEADERS ' ||
			 ' WHERE header_id = :1) ';
Line: 173

			 DELETE FROM  ic_txn_request_lines
			         WHERE line_id=l_line_id;
Line: 176

			 DELETE  FROM   ic_txn_request_headers ich
			          WHERE  header_id=l_header_id
			          AND  NOT EXISTS (select 1 from ic_txn_request_lines icl
			                            where icl.header_id=ich.header_id);