The following lines contain the word 'select', 'insert', 'update' or 'delete':
SELECT *
FROM rcv_shipment_lines rsl
WHERE ( p_organization_id IS NULL OR to_organization_id = p_organization_id )
/*even though to_organization_id is NULL ALLOWED, it is always populated*/
AND trunc(creation_date) between cp_start_date AND cp_end_date
AND to_organization_id IN ( SELECT jcio.organization_id
FROM jai_cmn_inventory_orgs jcio,
mtl_parameters mtl
WHERE mtl.organization_id = jcio.organization_id
AND mtl.process_enabled_flag = 'Y'
)
AND EXISTS ( SELECT 1
FROM jai_rcv_transactions
WHERE shipment_header_id = rsl.shipment_header_id
AND shipment_line_id = rsl.shipment_line_id
AND transaction_type = lv_deliver_trx
);
SELECT *
FROM jai_rcv_transactions jrcv
WHERE shipment_line_id = cp_shipment_line_id
AND ( (transaction_type IN (lv_deliver_trx,lv_rtr_trx))
OR (transaction_type = lv_correct_trx AND
parent_transaction_type IN (lv_rtr_trx,lv_deliver_trx)) )
AND nvl(opm_costing_flag,'N') = 'N';
SELECT receipt_num
FROM jai_rcv_lines
WHERE shipment_line_id = cp_shipment_line_id;
SELECT name
FROM hr_all_organization_units
WHERE organization_id = cp_orgn_id;
SELECT currency_code
FROM gl_sets_of_books
WHERE set_of_books_id = cp_cob_id ;
fnd_file.put_line(fnd_file.output,'Concurrent Program Name: India - Program to Update OPM Cost' );
fnd_file.put_line(fnd_file.output,'**********************************OPM Cost Update Begins**********************************' );
UPDATE rcv_transactions
SET po_unit_price = po_unit_price + ln_costing_amount
WHERE transaction_id = rcv_costing_records.transaction_id;
UPDATE mtl_material_transactions
SET transaction_cost = transaction_cost + ln_costing_amount
WHERE rcv_transaction_id = rcv_costing_records.transaction_id;
UPDATE jai_rcv_transactions
SET opm_costing_flag = 'Y',
opm_costing_amount = ln_costing_amount
WHERE transaction_id = rcv_costing_records.transaction_id;
fnd_file.put_line(fnd_file.output,'Cost Update Successful' );
fnd_file.put_line(fnd_file.output,'The Receipt was already Cost updated');
fnd_file.put_line(fnd_file.output,'**********************************OPM Cost Update Ends**********************************' );