The following lines contain the word 'select', 'insert', 'update' or 'delete':
SELECT
identifier, MSD_SOURCE_DATE_COL, CUSTOM_VIEW_NAME
FROM
msd_dem_series
WHERE
series_id = p_series_id
AND series_type = 1;
select rma_types
from msd_dem_rma_type;
select accnt_class_type
from msd_dem_accnt_classes;
/* insert return history data into return history staging table */
EXECUTE IMMEDIATE x_large_sql;
/* CTO Change - This update is no longer required from 7.3 onwards,
* since it uses the new site code format.
*/
IF ( p_series_id = MSD_DEM_COMMON_UTILITIES.C_RETURN_HISTORY
AND msd_dem_common_utilities.is_use_new_site_format = 0)
THEN
msd_dem_common_utilities.log_debug ('Start Updating Site codes - ' || TO_CHAR(systimestamp, 'DD-MON-YYYY HH24:MI:SS'));
MSD_DEM_UPDATE_LEVEL_CODES.update_code(x_errbuf ,
x_retcode,
p_SR_instance_id,
'SITE',
p_dest_table,
'LEVEL4',
'LEVEL4_SR_PK');
/* Delete the RMA types stored in the DB table */
delete from msd_dem_rma_type;
/* Delete the WIP Accounting classes stored in the DB table */
delete from msd_dem_accnt_classes;
SELECT meaning --jarora
FROM fnd_lookup_values_vl
WHERE lookup_type = p_lookup_type
AND lookup_code = p_lookup_code;
SELECT owner
FROM dba_objects
WHERE owner = owner
AND object_type = 'TABLE'
AND object_name = 'MDP_MATRIX'
ORDER BY created desc;
x_errbuf := 'The ''Date From'' and ''Date To'' fields are ignored if ''Rolling'' date range type is selected.';
x_errbuf := 'The ''History Collection Window'' field is ignored if ''Absolute'' date range type is selected.';
errbuf := 'The ''History Collection Window'' field cannot be NULL, if ''Rolling'' date range type is selected.';
errbuf := 'The ''Date From'' and ''Date To'' fields cannot be NULL, if ''Absolute'' date range type is selected.';
select instr(p_entity_name,':'),length(p_entity_name) --sopjarora
INTO l_position,l_length
FROM DUAL;
select substr(p_entity_name,1,l_position - 1),substr(p_entity_name,l_position + 1,l_length)
INTO l_table_name,l_series_name
FROM DUAL;
msd_dem_common_utilities.log_debug ('Begin delete from history staging table - ' || TO_CHAR(systimestamp, 'DD-MON-YYYY HH24:MI:SS'));
x_sql := 'DELETE FROM '|| x_dest_table || ' where sdate between ''' || x_from_date || ''' AND ''' || x_to_date || '''';
/* Delete RH ERR table */ -- bug#7486714
SELECT count(1) into x_table_present FROM dba_objects WHERE owner = owner AND object_type = 'TABLE' AND object_name = 'MSD_DEM_RETURN_HISTORY_ERR';
msd_dem_common_utilities.log_debug ('End delete from history staging table - ' || TO_CHAR(systimestamp, 'DD-MON-YYYY HH24:MI:SS'));