DBA Data[Home] [Help]

APPS.CST_LCMADJUSTMENTS_PUB SQL Statements

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

Line: 67

    SELECT organization_id, primary_cost_method
      FROM mtl_parameters mp
     WHERE EXISTS (SELECT 1
             FROM cst_lc_adj_interface
            WHERE organization_id = mp.organization_id
              AND process_status IN (1,2));
Line: 93

  SELECT worker_rows
  INTO   l_maxrows
  FROM   mtl_interface_proc_controls
  WHERE  process_code = 4;
Line: 105

      SELECT cst_lc_processor_grp_s.NEXTVAL
      INTO   l_group_id
      FROM   DUAL;
Line: 110

      UPDATE cst_lc_adj_interface i
        SET transaction_id = NVL(transaction_id, CST_LC_ADJ_INTERFACE_TRX_S.NEXTVAL),
            group_id = l_group_id,
            request_id = fnd_global.conc_request_id,
            process_phase = 2
      WHERE organization_id = c_o.organization_id
        AND process_status in (1,2)
        AND (group_id IS NULL
            OR
            NOT EXISTS (SELECT 1
        FROM fnd_concurrent_requests R,
             fnd_concurrent_programs P
        WHERE R.program_application_id = P.application_id
	AND R.concurrent_program_id = P.concurrent_program_id
	AND P.concurrent_program_name = 'CSTLCADJ'
	AND R.argument1 = TO_CHAR(i.group_id)
	AND R.phase_code IN ('I','P','R')))
        AND (c_o.primary_cost_method IN (1,2)
             OR
             NOT EXISTS (SELECT 1
            FROM mtl_material_transactions
           WHERE costed_flag in ('N', 'E')
             AND transaction_date < i.transaction_date
             AND transaction_source_type_id = 1
             AND rcv_transaction_id IN (SELECT transaction_id
                 FROM rcv_transactions rt
        START WITH rt.transaction_id = i.rcv_transaction_id
        CONNECT BY rt.parent_transaction_id = PRIOR rt.transaction_id)))
        AND ROWNUM <= l_maxrows;
Line: 154

        UPDATE cst_lc_adj_interface
          SET group_id = NULL,
              process_phase = 1
        WHERE group_id = l_group_id
          AND organization_id = c_o.organization_id;