DBA Data[Home] [Help]

APPS.MSC_CL_PURGE_STAGING dependencies on MSC_APPS_INSTANCES

Line 149: FROM msc_apps_instances

145:
146: BEGIN
147:
148: SELECT ST_STATUS INTO lv_staging_table_status
149: FROM msc_apps_instances
150: WHERE INSTANCE_CODE= pINSTANCE_CODE
151: FOR UPDATE;
152:
153: MSC_UTIL.LOG_MSG(MSC_UTIL.G_LVL_DEBUG_1,'Entered to check whether purge possible for the instance-'||pINSTANCE_CODE);

Line 215: UPDATE msc_apps_instances

211: RETURN FALSE;
212:
213:
214: ELSE
215: UPDATE msc_apps_instances
216: SET st_status=G_ST_PURGING
217: WHERE INSTANCE_CODE= pINSTANCE_CODE;
218: COMMIT;
219:

Line 256: FROM msc_apps_instances

252: AND LV.LOOKUP_TYPE = 'MSC_X_SETUP_ENTITY_CODE';
253:
254: CURSOR instance_codes ( cp_instance_id NUMBER ) IS
255: SELECT instance_code,instance_type,st_status
256: FROM msc_apps_instances
257: WHERE instance_id=cp_instance_id
258: UNION ALL
259: SELECT instance_code,instance_type,st_status
260: FROM msc_apps_instances

Line 260: FROM msc_apps_instances

256: FROM msc_apps_instances
257: WHERE instance_id=cp_instance_id
258: UNION ALL
259: SELECT instance_code,instance_type,st_status
260: FROM msc_apps_instances
261: WHERE cp_instance_id =-1;
262:
263: -- Cursor P and q are for update to lock the records before checking for the st_status.
264: CURSOR p IS

Line 266: FROM msc_apps_instances

262:
263: -- Cursor P and q are for update to lock the records before checking for the st_status.
264: CURSOR p IS
265: SELECT instance_code
266: FROM msc_apps_instances
267: WHERE st_status NOT IN (G_ST_PULLING,G_ST_COLLECTING,G_ST_PRE_PROCESSING)
268: FOR UPDATE;
269:
270: CURSOR q (cp_instance_id NUMBER ) IS

Line 272: FROM msc_apps_instances

268: FOR UPDATE;
269:
270: CURSOR q (cp_instance_id NUMBER ) IS
271: SELECT instance_code
272: FROM msc_apps_instances
273: WHERE st_status NOT IN (G_ST_PULLING,G_ST_COLLECTING,G_ST_PRE_PROCESSING)
274: AND instance_id=cp_instance_id
275: FOR UPDATE;
276:

Line 334: SELECT count(*) INTO lv_leg_inst_flag FROM msc_apps_instances WHERE instance_type = G_INS_OTHER ;

330: FROM dual;
331:
332:
333: IF (lv_trunc_profile = SYS_YES AND lv_p_del_rej_rec=SYS_NO ) THEN
334: SELECT count(*) INTO lv_leg_inst_flag FROM msc_apps_instances WHERE instance_type = G_INS_OTHER ;
335: SELECT count(*) INTO lv_inst_flag FROM msc_apps_instances;
336:
337: -- locking the records in msc_apps_instances before checking the st_status
338: IF (lv_p_instance_id <> -1) THEN

Line 335: SELECT count(*) INTO lv_inst_flag FROM msc_apps_instances;

331:
332:
333: IF (lv_trunc_profile = SYS_YES AND lv_p_del_rej_rec=SYS_NO ) THEN
334: SELECT count(*) INTO lv_leg_inst_flag FROM msc_apps_instances WHERE instance_type = G_INS_OTHER ;
335: SELECT count(*) INTO lv_inst_flag FROM msc_apps_instances;
336:
337: -- locking the records in msc_apps_instances before checking the st_status
338: IF (lv_p_instance_id <> -1) THEN
339: open q(lv_p_instance_id);

Line 337: -- locking the records in msc_apps_instances before checking the st_status

333: IF (lv_trunc_profile = SYS_YES AND lv_p_del_rej_rec=SYS_NO ) THEN
334: SELECT count(*) INTO lv_leg_inst_flag FROM msc_apps_instances WHERE instance_type = G_INS_OTHER ;
335: SELECT count(*) INTO lv_inst_flag FROM msc_apps_instances;
336:
337: -- locking the records in msc_apps_instances before checking the st_status
338: IF (lv_p_instance_id <> -1) THEN
339: open q(lv_p_instance_id);
340: close q;
341: ELSE

Line 346: SELECT count(*) INTO lv_st_status_flag FROM msc_apps_instances WHERE st_status IN ( G_ST_PULLING,G_ST_COLLECTING,G_ST_PRE_PROCESSING ) AND ((instance_id=lv_p_instance_id) OR (lv_p_instance_id=-1));

342: open p;
343: close p;
344: END IF;
345: -- Counting number of instances for which st_status is G_ST_PULLING , G_ST_COLLECTING and G_ST_PRE_PROCESSING
346: SELECT count(*) INTO lv_st_status_flag FROM msc_apps_instances WHERE st_status IN ( G_ST_PULLING,G_ST_COLLECTING,G_ST_PRE_PROCESSING ) AND ((instance_id=lv_p_instance_id) OR (lv_p_instance_id=-1));
347:
348: MSC_UTIL.LOG_MSG(MSC_UTIL.G_LVL_DEBUG_1,'Value of lv_st_status_flag-'||lv_st_status_flag);
349:
350: END IF;

Line 366: UPDATE msc_apps_instances

362:
363: MSC_UTIL.LOG_MSG(MSC_UTIL.G_LVL_DEBUG_1,'Truncation flag is YES. Entering in truncation LOOP');
364:
365:
366: UPDATE msc_apps_instances
367: SET st_status= G_ST_PURGING;
368: COMMIT;
369:
370: lv_retval := FND_INSTALLATION.GET_APP_INFO ( 'MSC', lv_dummy1, lv_dummy2, v_applsys_schema);

Line 409: UPDATE msc_apps_instances

405:
406: END LOOP;
407: CLOSE table_names;
408:
409: UPDATE msc_apps_instances
410: SET st_status= G_ST_EMPTY;
411: COMMIT;
412:
413: ELSE

Line 454: UPDATE msc_apps_instances

450:
451: MSC_UTIL.LOG_MSG(MSC_UTIL.G_LVL_DEBUG_1,' Instance type is LEGACY ,so setting st_status to empty');
452:
453:
454: UPDATE msc_apps_instances
455: SET st_status=G_ST_EMPTY
456: WHERE instance_code=lv_p_instance_code;
457: COMMIT;
458:

Line 464: UPDATE msc_apps_instances

460:
461: MSC_UTIL.LOG_MSG(MSC_UTIL.G_LVL_DEBUG_1,'Instance type is ERP ,so setting st_status to previous st_status-'||lv_st_status);
462:
463:
464: UPDATE msc_apps_instances
465: SET st_status=lv_st_status
466: WHERE instance_code=lv_p_instance_code;
467: COMMIT;
468:

Line 1961: FROM msc_apps_instances

1957:
1958: IF p_instance_id IS NOT NULL THEN
1959: SELECT instance_type, lrtype
1960: INTO lv_instance_type, lv_last_refresh_type
1961: FROM msc_apps_instances
1962: WHERE instance_id= p_instance_id;
1963: MSC_UTIL.LOG_MSG(MSC_UTIL.G_D_DEBUG_1,'instance_type='||lv_instance_type);
1964: END IF;
1965: lv_pbs := nvl(TO_NUMBER(FND_PROFILE.VALUE('MRP_PURGE_BATCH_SIZE')), 2000);