DBA Data[Home] [Help]

APPS.GME_POST_MIGRATION dependencies on GME_DEBUG

Line 138: gme_debug.log_initialize('Migration');

134: AND ROWNUM = 1;
135:
136: BEGIN
137: IF (g_debug IS NOT NULL) THEN
138: gme_debug.log_initialize('Migration');
139: END IF;
140: IF (g_debug <= gme_debug.g_log_procedure) THEN
141: gme_debug.put_line('Start procedure '||l_api_name);
142: END IF;

Line 140: IF (g_debug <= gme_debug.g_log_procedure) THEN

136: BEGIN
137: IF (g_debug IS NOT NULL) THEN
138: gme_debug.log_initialize('Migration');
139: END IF;
140: IF (g_debug <= gme_debug.g_log_procedure) THEN
141: gme_debug.put_line('Start procedure '||l_api_name);
142: END IF;
143: g_migration_run_id := gma_migration.gma_migration_start ('GME', 'RECREATE_OPEN_BATCHES');
144: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 141: gme_debug.put_line('Start procedure '||l_api_name);

137: IF (g_debug IS NOT NULL) THEN
138: gme_debug.log_initialize('Migration');
139: END IF;
140: IF (g_debug <= gme_debug.g_log_procedure) THEN
141: gme_debug.put_line('Start procedure '||l_api_name);
142: END IF;
143: g_migration_run_id := gma_migration.gma_migration_start ('GME', 'RECREATE_OPEN_BATCHES');
144: IF (g_debug <= gme_debug.g_log_statement) THEN
145: gme_debug.put_line('Migration RUN ID = '||g_migration_run_id);

Line 144: IF (g_debug <= gme_debug.g_log_statement) THEN

140: IF (g_debug <= gme_debug.g_log_procedure) THEN
141: gme_debug.put_line('Start procedure '||l_api_name);
142: END IF;
143: g_migration_run_id := gma_migration.gma_migration_start ('GME', 'RECREATE_OPEN_BATCHES');
144: IF (g_debug <= gme_debug.g_log_statement) THEN
145: gme_debug.put_line('Migration RUN ID = '||g_migration_run_id);
146: END IF;
147: FOR get_batches IN Cur_get_batches LOOP
148: BEGIN

Line 145: gme_debug.put_line('Migration RUN ID = '||g_migration_run_id);

141: gme_debug.put_line('Start procedure '||l_api_name);
142: END IF;
143: g_migration_run_id := gma_migration.gma_migration_start ('GME', 'RECREATE_OPEN_BATCHES');
144: IF (g_debug <= gme_debug.g_log_statement) THEN
145: gme_debug.put_line('Migration RUN ID = '||g_migration_run_id);
146: END IF;
147: FOR get_batches IN Cur_get_batches LOOP
148: BEGIN
149: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 149: IF (g_debug <= gme_debug.g_log_statement) THEN

145: gme_debug.put_line('Migration RUN ID = '||g_migration_run_id);
146: END IF;
147: FOR get_batches IN Cur_get_batches LOOP
148: BEGIN
149: IF (g_debug <= gme_debug.g_log_statement) THEN
150: gme_debug.put_line('Current batch is '||get_batches.plant_code||'-'||get_batches.batch_no);
151: END IF;
152: gme_common_pvt.set_timestamp;
153: IF (l_current_org_id <> get_batches.organization_id) THEN

Line 150: gme_debug.put_line('Current batch is '||get_batches.plant_code||'-'||get_batches.batch_no);

146: END IF;
147: FOR get_batches IN Cur_get_batches LOOP
148: BEGIN
149: IF (g_debug <= gme_debug.g_log_statement) THEN
150: gme_debug.put_line('Current batch is '||get_batches.plant_code||'-'||get_batches.batch_no);
151: END IF;
152: gme_common_pvt.set_timestamp;
153: IF (l_current_org_id <> get_batches.organization_id) THEN
154: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 154: IF (g_debug <= gme_debug.g_log_statement) THEN

150: gme_debug.put_line('Current batch is '||get_batches.plant_code||'-'||get_batches.batch_no);
151: END IF;
152: gme_common_pvt.set_timestamp;
153: IF (l_current_org_id <> get_batches.organization_id) THEN
154: IF (g_debug <= gme_debug.g_log_statement) THEN
155: gme_debug.put_line('Doing setup for org = '||get_batches.organization_id);
156: END IF;
157:
158: -- Bug 9164563 - Reset the global flag to make sure setup is done for new org.

Line 155: gme_debug.put_line('Doing setup for org = '||get_batches.organization_id);

151: END IF;
152: gme_common_pvt.set_timestamp;
153: IF (l_current_org_id <> get_batches.organization_id) THEN
154: IF (g_debug <= gme_debug.g_log_statement) THEN
155: gme_debug.put_line('Doing setup for org = '||get_batches.organization_id);
156: END IF;
157:
158: -- Bug 9164563 - Reset the global flag to make sure setup is done for new org.
159: gme_common_pvt.g_setup_done := FALSE;

Line 186: IF (g_debug <= gme_debug.g_log_statement) THEN

182: WHERE entity_type = DECODE(get_batches.batch_type, 10, gme_common_pvt.g_wip_entity_type_fpo, gme_common_pvt.g_wip_entity_type_batch)
183: AND organization_id = get_batches.organization_id
184: AND wip_entity_name = l_prefix||get_batches.batch_no;
185:
186: IF (g_debug <= gme_debug.g_log_statement) THEN
187: gme_debug.put_line('Start batch header');
188: END IF;
189:
190: /* Process batch header record */

Line 187: gme_debug.put_line('Start batch header');

183: AND organization_id = get_batches.organization_id
184: AND wip_entity_name = l_prefix||get_batches.batch_no;
185:
186: IF (g_debug <= gme_debug.g_log_statement) THEN
187: gme_debug.put_line('Start batch header');
188: END IF;
189:
190: /* Process batch header record */
191: build_batch_hdr(p_batch_header_mig => get_batches,

Line 202: IF (g_debug <= gme_debug.g_log_statement) THEN

198: l_batch_header.terminated_ind := 0;
199: l_batch_header.enhanced_pi_ind := 'N';
200: l_batch_header.batch_id := l_wip_entity_id;
201: l_batch_header.wip_whse_code := NULL;
202: IF (g_debug <= gme_debug.g_log_statement) THEN
203: gme_debug.put_line('Before wip entities');
204: END IF;
205:
206: -- Bug 13706812/13839066 - Let's make sure we update primary_item_id.

Line 203: gme_debug.put_line('Before wip entities');

199: l_batch_header.enhanced_pi_ind := 'N';
200: l_batch_header.batch_id := l_wip_entity_id;
201: l_batch_header.wip_whse_code := NULL;
202: IF (g_debug <= gme_debug.g_log_statement) THEN
203: gme_debug.put_line('Before wip entities');
204: END IF;
205:
206: -- Bug 13706812/13839066 - Let's make sure we update primary_item_id.
207: OPEN Cur_get_prim_item(l_batch_header.recipe_validity_rule_id, l_batch_header.organization_id);

Line 244: IF (g_debug <= gme_debug.g_log_statement) THEN

240: ,gme_common_pvt.g_wip_entity_type_fpo)
241: ,mtl_gen_object_id_s.NEXTVAL
242: ,l_primary_item_id);
243:
244: IF (g_debug <= gme_debug.g_log_statement) THEN
245: gme_debug.put_line('After wip entities');
246: END IF;
247:
248: l_batch_tbl(1) := l_batch_header;

Line 245: gme_debug.put_line('After wip entities');

241: ,mtl_gen_object_id_s.NEXTVAL
242: ,l_primary_item_id);
243:
244: IF (g_debug <= gme_debug.g_log_statement) THEN
245: gme_debug.put_line('After wip entities');
246: END IF;
247:
248: l_batch_tbl(1) := l_batch_header;
249: FORALL a IN 1..l_batch_tbl.count

Line 252: IF (g_debug <= gme_debug.g_log_statement) THEN

248: l_batch_tbl(1) := l_batch_header;
249: FORALL a IN 1..l_batch_tbl.count
250: INSERT INTO gme_batch_header VALUES l_batch_tbl(a);
251:
252: IF (g_debug <= gme_debug.g_log_statement) THEN
253: gme_debug.put_line('After batch header');
254: END IF;
255: /* Process material details records */
256: OPEN Cur_get_materials(get_batches.batch_id);

Line 253: gme_debug.put_line('After batch header');

249: FORALL a IN 1..l_batch_tbl.count
250: INSERT INTO gme_batch_header VALUES l_batch_tbl(a);
251:
252: IF (g_debug <= gme_debug.g_log_statement) THEN
253: gme_debug.put_line('After batch header');
254: END IF;
255: /* Process material details records */
256: OPEN Cur_get_materials(get_batches.batch_id);
257: FETCH Cur_get_materials BULK COLLECT INTO l_mtl_dtl_mig_tbl;

Line 259: IF (g_debug <= gme_debug.g_log_statement) THEN

255: /* Process material details records */
256: OPEN Cur_get_materials(get_batches.batch_id);
257: FETCH Cur_get_materials BULK COLLECT INTO l_mtl_dtl_mig_tbl;
258: CLOSE Cur_get_materials;
259: IF (g_debug <= gme_debug.g_log_statement) THEN
260: gme_debug.put_line('No. of materials = '||l_mtl_dtl_mig_tbl.count);
261: END IF;
262:
263: build_mtl_dtl(p_mtl_dtl_mig => l_mtl_dtl_mig_tbl,

Line 260: gme_debug.put_line('No. of materials = '||l_mtl_dtl_mig_tbl.count);

256: OPEN Cur_get_materials(get_batches.batch_id);
257: FETCH Cur_get_materials BULK COLLECT INTO l_mtl_dtl_mig_tbl;
258: CLOSE Cur_get_materials;
259: IF (g_debug <= gme_debug.g_log_statement) THEN
260: gme_debug.put_line('No. of materials = '||l_mtl_dtl_mig_tbl.count);
261: END IF;
262:
263: build_mtl_dtl(p_mtl_dtl_mig => l_mtl_dtl_mig_tbl,
264: x_mtl_dtl => l_mtl_dtl_tbl);

Line 316: IF (g_debug <= gme_debug.g_log_statement) THEN

312: END LOOP;
313:
314: FORALL a IN 1..l_mtl_dtl_tbl.count
315: INSERT INTO gme_material_details VALUES l_mtl_dtl_tbl(a);
316: IF (g_debug <= gme_debug.g_log_statement) THEN
317: gme_debug.put_line('After materials');
318: END IF;
319:
320: /* Process batch step records */

Line 317: gme_debug.put_line('After materials');

313:
314: FORALL a IN 1..l_mtl_dtl_tbl.count
315: INSERT INTO gme_material_details VALUES l_mtl_dtl_tbl(a);
316: IF (g_debug <= gme_debug.g_log_statement) THEN
317: gme_debug.put_line('After materials');
318: END IF;
319:
320: /* Process batch step records */
321: l_steps_tbl.delete;

Line 330: IF (g_debug <= gme_debug.g_log_statement) THEN

326: OPEN Cur_get_steps(get_batches.batch_id);
327: FETCH Cur_get_steps BULK COLLECT INTO l_steps_mig_tbl;
328: CLOSE Cur_get_steps;
329:
330: IF (g_debug <= gme_debug.g_log_statement) THEN
331: gme_debug.put_line('No.of steps = '||l_steps_mig_tbl.count);
332: END IF;
333:
334: build_steps(p_steps_mig => l_steps_mig_tbl,

Line 331: gme_debug.put_line('No.of steps = '||l_steps_mig_tbl.count);

327: FETCH Cur_get_steps BULK COLLECT INTO l_steps_mig_tbl;
328: CLOSE Cur_get_steps;
329:
330: IF (g_debug <= gme_debug.g_log_statement) THEN
331: gme_debug.put_line('No.of steps = '||l_steps_mig_tbl.count);
332: END IF;
333:
334: build_steps(p_steps_mig => l_steps_mig_tbl,
335: x_steps => l_steps_tbl);

Line 356: IF (g_debug <= gme_debug.g_log_statement) THEN

352:
353: l_actv_count := l_activities_tbl.count;
354: build_activities(p_activities_mig => l_activities_mig_tbl,
355: x_activities => l_activities_tbl);
356: IF (g_debug <= gme_debug.g_log_statement) THEN
357: gme_debug.put_line('No. of activities = '||l_activities_mig_tbl.count);
358: END IF;
359: FOR j IN (l_actv_count + 1)..l_activities_tbl.count LOOP
360: l_old_bstep_activ_id := l_activities_tbl(j).batchstep_activity_id;

Line 357: gme_debug.put_line('No. of activities = '||l_activities_mig_tbl.count);

353: l_actv_count := l_activities_tbl.count;
354: build_activities(p_activities_mig => l_activities_mig_tbl,
355: x_activities => l_activities_tbl);
356: IF (g_debug <= gme_debug.g_log_statement) THEN
357: gme_debug.put_line('No. of activities = '||l_activities_mig_tbl.count);
358: END IF;
359: FOR j IN (l_actv_count + 1)..l_activities_tbl.count LOOP
360: l_old_bstep_activ_id := l_activities_tbl(j).batchstep_activity_id;
361: SELECT gme_batch_step_activity_s.NEXTVAL INTO l_activities_tbl(j).batchstep_activity_id FROM DUAL;

Line 376: IF (g_debug <= gme_debug.g_log_statement) THEN

372:
373: l_rsrc_count := l_resources_tbl.count;
374: build_resources(p_resources_mig => l_resources_mig_tbl,
375: x_resources => l_resources_tbl);
376: IF (g_debug <= gme_debug.g_log_statement) THEN
377: gme_debug.put_line('No. of resources = '||l_resources_mig_tbl.count);
378: END IF;
379: FOR k IN (l_rsrc_count + 1)..l_resources_tbl.count LOOP
380: l_old_bstep_rsrc_id := l_resources_tbl(k).batchstep_resource_id;

Line 377: gme_debug.put_line('No. of resources = '||l_resources_mig_tbl.count);

373: l_rsrc_count := l_resources_tbl.count;
374: build_resources(p_resources_mig => l_resources_mig_tbl,
375: x_resources => l_resources_tbl);
376: IF (g_debug <= gme_debug.g_log_statement) THEN
377: gme_debug.put_line('No. of resources = '||l_resources_mig_tbl.count);
378: END IF;
379: FOR k IN (l_rsrc_count + 1)..l_resources_tbl.count LOOP
380: l_old_bstep_rsrc_id := l_resources_tbl(k).batchstep_resource_id;
381: SELECT gem5_batchstepline_id_s.NEXTVAL INTO l_resources_tbl(k).batchstep_resource_id FROM DUAL;

Line 397: IF (g_debug <= gme_debug.g_log_statement) THEN

393:
394: l_pprm_count := l_proc_param_tbl.count;
395: build_parameters(p_parameters_mig => l_proc_param_mig_tbl,
396: x_parameters => l_proc_param_tbl);
397: IF (g_debug <= gme_debug.g_log_statement) THEN
398: gme_debug.put_line('No. of process params = '||l_proc_param_mig_tbl.count);
399: END IF;
400: FOR m IN (l_pprm_count + 1)..l_proc_param_tbl.count LOOP
401: SELECT gme_process_parameters_id_s.NEXTVAL INTO l_proc_param_tbl(m).process_param_id FROM DUAL;

Line 398: gme_debug.put_line('No. of process params = '||l_proc_param_mig_tbl.count);

394: l_pprm_count := l_proc_param_tbl.count;
395: build_parameters(p_parameters_mig => l_proc_param_mig_tbl,
396: x_parameters => l_proc_param_tbl);
397: IF (g_debug <= gme_debug.g_log_statement) THEN
398: gme_debug.put_line('No. of process params = '||l_proc_param_mig_tbl.count);
399: END IF;
400: FOR m IN (l_pprm_count + 1)..l_proc_param_tbl.count LOOP
401: SELECT gme_process_parameters_id_s.NEXTVAL INTO l_proc_param_tbl(m).process_param_id FROM DUAL;
402: l_proc_param_tbl(m).batch_id := l_batch_header.batch_id;

Line 416: IF (g_debug <= gme_debug.g_log_statement) THEN

412:
413: l_rtxn_count := l_rsrc_txns_tbl.count;
414: build_rsrc_txns(p_rsrc_txns_mig => l_rsrc_txns_mig_tbl,
415: x_rsrc_txns => l_rsrc_txns_tbl);
416: IF (g_debug <= gme_debug.g_log_statement) THEN
417: gme_debug.put_line('No. of rsrc txns = '||l_rsrc_txns_mig_tbl.count);
418: END IF;
419: FOR n IN (l_rtxn_count + 1)..l_rsrc_txns_tbl.count LOOP
420: SELECT gem5_poc_trans_id_s.NEXTVAL INTO l_rsrc_txns_tbl(n).poc_trans_id FROM DUAL;

Line 417: gme_debug.put_line('No. of rsrc txns = '||l_rsrc_txns_mig_tbl.count);

413: l_rtxn_count := l_rsrc_txns_tbl.count;
414: build_rsrc_txns(p_rsrc_txns_mig => l_rsrc_txns_mig_tbl,
415: x_rsrc_txns => l_rsrc_txns_tbl);
416: IF (g_debug <= gme_debug.g_log_statement) THEN
417: gme_debug.put_line('No. of rsrc txns = '||l_rsrc_txns_mig_tbl.count);
418: END IF;
419: FOR n IN (l_rtxn_count + 1)..l_rsrc_txns_tbl.count LOOP
420: SELECT gem5_poc_trans_id_s.NEXTVAL INTO l_rsrc_txns_tbl(n).poc_trans_id FROM DUAL;
421: l_rsrc_txns_tbl(n).orgn_code := NULL;

Line 429: IF (g_debug <= gme_debug.g_log_statement) THEN

425: END LOOP; /* Resources Loop */
426: END LOOP; /* Activities Loop */
427: END LOOP; /* Steps Loop */
428:
429: IF (g_debug <= gme_debug.g_log_statement) THEN
430: gme_debug.put_line('After steps processing now inserting all step data');
431: END IF;
432:
433: FORALL a IN 1..l_steps_tbl.count

Line 430: gme_debug.put_line('After steps processing now inserting all step data');

426: END LOOP; /* Activities Loop */
427: END LOOP; /* Steps Loop */
428:
429: IF (g_debug <= gme_debug.g_log_statement) THEN
430: gme_debug.put_line('After steps processing now inserting all step data');
431: END IF;
432:
433: FORALL a IN 1..l_steps_tbl.count
434: INSERT INTO gme_batch_steps VALUES l_steps_tbl(a);

Line 435: IF (g_debug <= gme_debug.g_log_statement) THEN

431: END IF;
432:
433: FORALL a IN 1..l_steps_tbl.count
434: INSERT INTO gme_batch_steps VALUES l_steps_tbl(a);
435: IF (g_debug <= gme_debug.g_log_statement) THEN
436: gme_debug.put_line('After insert steps');
437: END IF;
438: FORALL a IN 1..l_activities_tbl.count
439: INSERT INTO gme_batch_step_activities VALUES l_activities_tbl(a);

Line 436: gme_debug.put_line('After insert steps');

432:
433: FORALL a IN 1..l_steps_tbl.count
434: INSERT INTO gme_batch_steps VALUES l_steps_tbl(a);
435: IF (g_debug <= gme_debug.g_log_statement) THEN
436: gme_debug.put_line('After insert steps');
437: END IF;
438: FORALL a IN 1..l_activities_tbl.count
439: INSERT INTO gme_batch_step_activities VALUES l_activities_tbl(a);
440: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 440: IF (g_debug <= gme_debug.g_log_statement) THEN

436: gme_debug.put_line('After insert steps');
437: END IF;
438: FORALL a IN 1..l_activities_tbl.count
439: INSERT INTO gme_batch_step_activities VALUES l_activities_tbl(a);
440: IF (g_debug <= gme_debug.g_log_statement) THEN
441: gme_debug.put_line('After insert activities');
442: END IF;
443: FORALL a IN 1..l_resources_tbl.count
444: INSERT INTO gme_batch_step_resources VALUES l_resources_tbl(a);

Line 441: gme_debug.put_line('After insert activities');

437: END IF;
438: FORALL a IN 1..l_activities_tbl.count
439: INSERT INTO gme_batch_step_activities VALUES l_activities_tbl(a);
440: IF (g_debug <= gme_debug.g_log_statement) THEN
441: gme_debug.put_line('After insert activities');
442: END IF;
443: FORALL a IN 1..l_resources_tbl.count
444: INSERT INTO gme_batch_step_resources VALUES l_resources_tbl(a);
445: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 445: IF (g_debug <= gme_debug.g_log_statement) THEN

441: gme_debug.put_line('After insert activities');
442: END IF;
443: FORALL a IN 1..l_resources_tbl.count
444: INSERT INTO gme_batch_step_resources VALUES l_resources_tbl(a);
445: IF (g_debug <= gme_debug.g_log_statement) THEN
446: gme_debug.put_line('After insert resources');
447: END IF;
448: FORALL a IN 1..l_proc_param_tbl.count
449: INSERT INTO gme_process_parameters VALUES l_proc_param_tbl(a);

Line 446: gme_debug.put_line('After insert resources');

442: END IF;
443: FORALL a IN 1..l_resources_tbl.count
444: INSERT INTO gme_batch_step_resources VALUES l_resources_tbl(a);
445: IF (g_debug <= gme_debug.g_log_statement) THEN
446: gme_debug.put_line('After insert resources');
447: END IF;
448: FORALL a IN 1..l_proc_param_tbl.count
449: INSERT INTO gme_process_parameters VALUES l_proc_param_tbl(a);
450: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 450: IF (g_debug <= gme_debug.g_log_statement) THEN

446: gme_debug.put_line('After insert resources');
447: END IF;
448: FORALL a IN 1..l_proc_param_tbl.count
449: INSERT INTO gme_process_parameters VALUES l_proc_param_tbl(a);
450: IF (g_debug <= gme_debug.g_log_statement) THEN
451: gme_debug.put_line('After insert process params');
452: END IF;
453: FORALL a IN 1..l_rsrc_txns_tbl.count
454: INSERT INTO gme_resource_txns VALUES l_rsrc_txns_tbl(a);

Line 451: gme_debug.put_line('After insert process params');

447: END IF;
448: FORALL a IN 1..l_proc_param_tbl.count
449: INSERT INTO gme_process_parameters VALUES l_proc_param_tbl(a);
450: IF (g_debug <= gme_debug.g_log_statement) THEN
451: gme_debug.put_line('After insert process params');
452: END IF;
453: FORALL a IN 1..l_rsrc_txns_tbl.count
454: INSERT INTO gme_resource_txns VALUES l_rsrc_txns_tbl(a);
455: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 455: IF (g_debug <= gme_debug.g_log_statement) THEN

451: gme_debug.put_line('After insert process params');
452: END IF;
453: FORALL a IN 1..l_rsrc_txns_tbl.count
454: INSERT INTO gme_resource_txns VALUES l_rsrc_txns_tbl(a);
455: IF (g_debug <= gme_debug.g_log_statement) THEN
456: gme_debug.put_line('After insert rsrc txns');
457: END IF;
458:
459: create_step_dependencies(p_old_batch_id => get_batches.batch_id,

Line 456: gme_debug.put_line('After insert rsrc txns');

452: END IF;
453: FORALL a IN 1..l_rsrc_txns_tbl.count
454: INSERT INTO gme_resource_txns VALUES l_rsrc_txns_tbl(a);
455: IF (g_debug <= gme_debug.g_log_statement) THEN
456: gme_debug.put_line('After insert rsrc txns');
457: END IF;
458:
459: create_step_dependencies(p_old_batch_id => get_batches.batch_id,
460: p_new_batch_id => l_batch_header.batch_id);

Line 461: IF (g_debug <= gme_debug.g_log_statement) THEN

457: END IF;
458:
459: create_step_dependencies(p_old_batch_id => get_batches.batch_id,
460: p_new_batch_id => l_batch_header.batch_id);
461: IF (g_debug <= gme_debug.g_log_statement) THEN
462: gme_debug.put_line('After create dependencies');
463: END IF;
464:
465: create_item_step_assoc(p_old_batch_id => get_batches.batch_id,

Line 462: gme_debug.put_line('After create dependencies');

458:
459: create_step_dependencies(p_old_batch_id => get_batches.batch_id,
460: p_new_batch_id => l_batch_header.batch_id);
461: IF (g_debug <= gme_debug.g_log_statement) THEN
462: gme_debug.put_line('After create dependencies');
463: END IF;
464:
465: create_item_step_assoc(p_old_batch_id => get_batches.batch_id,
466: p_new_batch_id => l_batch_header.batch_id);

Line 467: IF (g_debug <= gme_debug.g_log_statement) THEN

463: END IF;
464:
465: create_item_step_assoc(p_old_batch_id => get_batches.batch_id,
466: p_new_batch_id => l_batch_header.batch_id);
467: IF (g_debug <= gme_debug.g_log_statement) THEN
468: gme_debug.put_line('After create associations');
469: END IF;
470:
471: create_batch_step_charges(p_old_batch_id => get_batches.batch_id,

Line 468: gme_debug.put_line('After create associations');

464:
465: create_item_step_assoc(p_old_batch_id => get_batches.batch_id,
466: p_new_batch_id => l_batch_header.batch_id);
467: IF (g_debug <= gme_debug.g_log_statement) THEN
468: gme_debug.put_line('After create associations');
469: END IF;
470:
471: create_batch_step_charges(p_old_batch_id => get_batches.batch_id,
472: p_new_batch_id => l_batch_header.batch_id);

Line 473: IF (g_debug <= gme_debug.g_log_statement) THEN

469: END IF;
470:
471: create_batch_step_charges(p_old_batch_id => get_batches.batch_id,
472: p_new_batch_id => l_batch_header.batch_id);
473: IF (g_debug <= gme_debug.g_log_statement) THEN
474: gme_debug.put_line('After create charges');
475: END IF;
476:
477: create_batch_step_transfers(p_old_batch_id => get_batches.batch_id,

Line 474: gme_debug.put_line('After create charges');

470:
471: create_batch_step_charges(p_old_batch_id => get_batches.batch_id,
472: p_new_batch_id => l_batch_header.batch_id);
473: IF (g_debug <= gme_debug.g_log_statement) THEN
474: gme_debug.put_line('After create charges');
475: END IF;
476:
477: create_batch_step_transfers(p_old_batch_id => get_batches.batch_id,
478: p_new_batch_id => l_batch_header.batch_id);

Line 479: IF (g_debug <= gme_debug.g_log_statement) THEN

475: END IF;
476:
477: create_batch_step_transfers(p_old_batch_id => get_batches.batch_id,
478: p_new_batch_id => l_batch_header.batch_id);
479: IF (g_debug <= gme_debug.g_log_statement) THEN
480: gme_debug.put_line('After create transfers');
481: END IF;
482:
483: FOR i IN 1..l_mtl_dtl_tbl.count LOOP

Line 480: gme_debug.put_line('After create transfers');

476:
477: create_batch_step_transfers(p_old_batch_id => get_batches.batch_id,
478: p_new_batch_id => l_batch_header.batch_id);
479: IF (g_debug <= gme_debug.g_log_statement) THEN
480: gme_debug.put_line('After create transfers');
481: END IF;
482:
483: FOR i IN 1..l_mtl_dtl_tbl.count LOOP
484: gme_common_pvt.calc_mtl_req_date(p_batch_header_rec => l_batch_header

Line 494: IF (g_debug <= gme_debug.g_log_statement) THEN

490: RAISE calc_mtl_req_date_err;
491: END IF;
492: END LOOP;
493:
494: IF (g_debug <= gme_debug.g_log_statement) THEN
495: gme_debug.put_line('After mtl_req_date');
496: END IF;
497:
498: IF l_batch_header.batch_type = 0 AND NVL (l_batch_header.update_inventory_ind, 'Y') = 'Y' THEN

Line 495: gme_debug.put_line('After mtl_req_date');

491: END IF;
492: END LOOP;
493:
494: IF (g_debug <= gme_debug.g_log_statement) THEN
495: gme_debug.put_line('After mtl_req_date');
496: END IF;
497:
498: IF l_batch_header.batch_type = 0 AND NVL (l_batch_header.update_inventory_ind, 'Y') = 'Y' THEN
499: gme_move_orders_pvt.create_move_order_hdr

Line 520: IF (g_debug <= gme_debug.g_log_statement) THEN

516: RAISE create_mo_line_err;
517: END IF;
518: END IF;
519: END IF;
520: IF (g_debug <= gme_debug.g_log_statement) THEN
521: gme_debug.put_line('After create move order');
522: END IF;
523:
524: UPDATE gme_batch_header

Line 521: gme_debug.put_line('After create move order');

517: END IF;
518: END IF;
519: END IF;
520: IF (g_debug <= gme_debug.g_log_statement) THEN
521: gme_debug.put_line('After create move order');
522: END IF;
523:
524: UPDATE gme_batch_header
525: SET move_order_header_id = l_batch_header.move_order_header_id

Line 534: IF (g_debug <= gme_debug.g_log_statement) THEN

530: SET move_order_line_id = l_mtl_dtl_tbl(a).move_order_line_id,
531: material_requirement_date = l_mtl_dtl_tbl(a).material_requirement_date
532: WHERE material_detail_id = l_mtl_dtl_tbl(a).material_detail_id;
533: END LOOP;
534: IF (g_debug <= gme_debug.g_log_statement) THEN
535: gme_debug.put_line('After update material');
536: END IF;
537:
538: create_batch_mapping(p_batch_header_mig => get_batches,

Line 535: gme_debug.put_line('After update material');

531: material_requirement_date = l_mtl_dtl_tbl(a).material_requirement_date
532: WHERE material_detail_id = l_mtl_dtl_tbl(a).material_detail_id;
533: END LOOP;
534: IF (g_debug <= gme_debug.g_log_statement) THEN
535: gme_debug.put_line('After update material');
536: END IF;
537:
538: create_batch_mapping(p_batch_header_mig => get_batches,
539: p_batch_header => l_batch_header);

Line 545: IF (g_debug <= gme_debug.g_log_statement) THEN

541: UPDATE gme_batch_header_mig
542: SET migrated_batch_ind = 'M'
543: WHERE batch_id = get_batches.batch_id;
544:
545: IF (g_debug <= gme_debug.g_log_statement) THEN
546: gme_debug.put_line('Done batch basic processing');
547: END IF;
548:
549: EXCEPTION

Line 546: gme_debug.put_line('Done batch basic processing');

542: SET migrated_batch_ind = 'M'
543: WHERE batch_id = get_batches.batch_id;
544:
545: IF (g_debug <= gme_debug.g_log_statement) THEN
546: gme_debug.put_line('Done batch basic processing');
547: END IF;
548:
549: EXCEPTION
550: WHEN item_not_defined THEN

Line 582: IF (g_debug <= gme_debug.g_log_unexpected) THEN

578: p_param1 => get_batches.plant_code||'-'||get_batches.batch_no,
579: p_token2 => 'MSG',
580: p_param2 => l_msg_data);
581: WHEN OTHERS THEN
582: IF (g_debug <= gme_debug.g_log_unexpected) THEN
583: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
584: END IF;
585: ROLLBACK;
586: gma_common_logging.gma_migration_central_log

Line 583: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

579: p_token2 => 'MSG',
580: p_param2 => l_msg_data);
581: WHEN OTHERS THEN
582: IF (g_debug <= gme_debug.g_log_unexpected) THEN
583: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
584: END IF;
585: ROLLBACK;
586: gma_common_logging.gma_migration_central_log
587: (p_run_id => g_migration_run_id,

Line 601: IF (g_debug <= gme_debug.g_log_statement) THEN

597: END;
598: COMMIT;
599: END LOOP;
600:
601: IF (g_debug <= gme_debug.g_log_statement) THEN
602: gme_debug.put_line('Create phantom links');
603: END IF;
604: create_phantom_links;
605:

Line 602: gme_debug.put_line('Create phantom links');

598: COMMIT;
599: END LOOP;
600:
601: IF (g_debug <= gme_debug.g_log_statement) THEN
602: gme_debug.put_line('Create phantom links');
603: END IF;
604: create_phantom_links;
605:
606: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 606: IF (g_debug <= gme_debug.g_log_statement) THEN

602: gme_debug.put_line('Create phantom links');
603: END IF;
604: create_phantom_links;
605:
606: IF (g_debug <= gme_debug.g_log_statement) THEN
607: gme_debug.put_line('Create Reservations/Pending Lots');
608: END IF;
609:
610: /* Bug 5620671 Added param completed ind */

Line 607: gme_debug.put_line('Create Reservations/Pending Lots');

603: END IF;
604: create_phantom_links;
605:
606: IF (g_debug <= gme_debug.g_log_statement) THEN
607: gme_debug.put_line('Create Reservations/Pending Lots');
608: END IF;
609:
610: /* Bug 5620671 Added param completed ind */
611: create_txns_reservations(0);

Line 613: IF (g_debug <= gme_debug.g_log_statement) THEN

609:
610: /* Bug 5620671 Added param completed ind */
611: create_txns_reservations(0);
612:
613: IF (g_debug <= gme_debug.g_log_statement) THEN
614: gme_debug.put_line('Release batches');
615: END IF;
616:
617: gme_common_pvt.g_transaction_header_id := NULL;

Line 614: gme_debug.put_line('Release batches');

610: /* Bug 5620671 Added param completed ind */
611: create_txns_reservations(0);
612:
613: IF (g_debug <= gme_debug.g_log_statement) THEN
614: gme_debug.put_line('Release batches');
615: END IF;
616:
617: gme_common_pvt.g_transaction_header_id := NULL;
618: release_batches;

Line 620: IF (g_debug <= gme_debug.g_log_statement) THEN

616:
617: gme_common_pvt.g_transaction_header_id := NULL;
618: release_batches;
619:
620: IF (g_debug <= gme_debug.g_log_statement) THEN
621: gme_debug.put_line('Create transactions');
622: END IF;
623:
624: /* Bug 5620671 Added param completed ind */

Line 621: gme_debug.put_line('Create transactions');

617: gme_common_pvt.g_transaction_header_id := NULL;
618: release_batches;
619:
620: IF (g_debug <= gme_debug.g_log_statement) THEN
621: gme_debug.put_line('Create transactions');
622: END IF;
623:
624: /* Bug 5620671 Added param completed ind */
625: create_txns_reservations(1);

Line 626: IF (g_debug <= gme_debug.g_log_statement) THEN

622: END IF;
623:
624: /* Bug 5620671 Added param completed ind */
625: create_txns_reservations(1);
626: IF (g_debug <= gme_debug.g_log_statement) THEN
627: gme_debug.put_line('Insert lab lots');
628: END IF;
629:
630: insert_lab_lots;

Line 627: gme_debug.put_line('Insert lab lots');

623:
624: /* Bug 5620671 Added param completed ind */
625: create_txns_reservations(1);
626: IF (g_debug <= gme_debug.g_log_statement) THEN
627: gme_debug.put_line('Insert lab lots');
628: END IF;
629:
630: insert_lab_lots;
631: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 631: IF (g_debug <= gme_debug.g_log_statement) THEN

627: gme_debug.put_line('Insert lab lots');
628: END IF;
629:
630: insert_lab_lots;
631: IF (g_debug <= gme_debug.g_log_statement) THEN
632: gme_debug.put_line('Close Steps');
633: END IF;
634:
635: close_steps;

Line 632: gme_debug.put_line('Close Steps');

628: END IF;
629:
630: insert_lab_lots;
631: IF (g_debug <= gme_debug.g_log_statement) THEN
632: gme_debug.put_line('Close Steps');
633: END IF;
634:
635: close_steps;
636: /* Bug 5703541 Added update stmt and loop for mtl_lot_conv_audit */

Line 637: IF (g_debug <= gme_debug.g_log_statement) THEN

633: END IF;
634:
635: close_steps;
636: /* Bug 5703541 Added update stmt and loop for mtl_lot_conv_audit */
637: IF (g_debug <= gme_debug.g_log_statement) THEN
638: gme_debug.put_line('Update mtl_lot_conv_audit');
639: END IF;
640: FOR get_rec IN (SELECT old_batch_id, new_batch_id FROM gme_batch_mapping_mig
641: WHERE old_batch_id IN (SELECT DISTINCT(batch_id) FROM mtl_lot_conv_audit)) LOOP

Line 638: gme_debug.put_line('Update mtl_lot_conv_audit');

634:
635: close_steps;
636: /* Bug 5703541 Added update stmt and loop for mtl_lot_conv_audit */
637: IF (g_debug <= gme_debug.g_log_statement) THEN
638: gme_debug.put_line('Update mtl_lot_conv_audit');
639: END IF;
640: FOR get_rec IN (SELECT old_batch_id, new_batch_id FROM gme_batch_mapping_mig
641: WHERE old_batch_id IN (SELECT DISTINCT(batch_id) FROM mtl_lot_conv_audit)) LOOP
642: UPDATE mtl_lot_conv_audit

Line 647: IF (g_debug <= gme_debug.g_log_statement) THEN

643: SET batch_id = get_rec.new_batch_id
644: WHERE batch_id = get_rec.old_batch_id;
645: END LOOP;
646:
647: IF (g_debug <= gme_debug.g_log_statement) THEN
648: gme_debug.put_line('Call QM');
649: END IF;
650:
651: gmd_qc_migb12.gmd_qc_migrate_batch_id(p_migration_run_id => g_migration_run_id,

Line 648: gme_debug.put_line('Call QM');

644: WHERE batch_id = get_rec.old_batch_id;
645: END LOOP;
646:
647: IF (g_debug <= gme_debug.g_log_statement) THEN
648: gme_debug.put_line('Call QM');
649: END IF;
650:
651: gmd_qc_migb12.gmd_qc_migrate_batch_id(p_migration_run_id => g_migration_run_id,
652: p_commit => FND_API.G_TRUE,

Line 654: IF (g_debug <= gme_debug.g_log_procedure) THEN

650:
651: gmd_qc_migb12.gmd_qc_migrate_batch_id(p_migration_run_id => g_migration_run_id,
652: p_commit => FND_API.G_TRUE,
653: x_exception_count => l_msg_count);
654: IF (g_debug <= gme_debug.g_log_procedure) THEN
655: gme_debug.put_line('End procedure '||l_api_name);
656: END IF;
657:
658: gma_migration.gma_migration_end (l_run_id => g_migration_run_id);

Line 655: gme_debug.put_line('End procedure '||l_api_name);

651: gmd_qc_migb12.gmd_qc_migrate_batch_id(p_migration_run_id => g_migration_run_id,
652: p_commit => FND_API.G_TRUE,
653: x_exception_count => l_msg_count);
654: IF (g_debug <= gme_debug.g_log_procedure) THEN
655: gme_debug.put_line('End procedure '||l_api_name);
656: END IF;
657:
658: gma_migration.gma_migration_end (l_run_id => g_migration_run_id);
659: EXCEPTION

Line 661: IF (g_debug <= gme_debug.g_log_unexpected) THEN

657:
658: gma_migration.gma_migration_end (l_run_id => g_migration_run_id);
659: EXCEPTION
660: WHEN OTHERS THEN
661: IF (g_debug <= gme_debug.g_log_unexpected) THEN
662: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
663: END IF;
664: gma_common_logging.gma_migration_central_log
665: (p_run_id => g_migration_run_id,

Line 662: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

658: gma_migration.gma_migration_end (l_run_id => g_migration_run_id);
659: EXCEPTION
660: WHEN OTHERS THEN
661: IF (g_debug <= gme_debug.g_log_unexpected) THEN
662: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
663: END IF;
664: gma_common_logging.gma_migration_central_log
665: (p_run_id => g_migration_run_id,
666: p_log_level => fnd_log.level_unexpected,

Line 1272: IF (g_debug <= gme_debug.g_log_procedure) THEN

1268: TYPE step_dep_tab IS TABLE OF gme_batch_step_dependencies%ROWTYPE INDEX BY BINARY_INTEGER;
1269: l_step_dep_tbl step_dep_tab;
1270: l_api_name VARCHAR2(30) := 'create_step_dependencies';
1271: BEGIN
1272: IF (g_debug <= gme_debug.g_log_procedure) THEN
1273: gme_debug.put_line('Start procedure '||l_api_name);
1274: END IF;
1275: OPEN Cur_get_deps(p_old_batch_id);
1276: FETCH Cur_get_deps BULK COLLECT INTO l_step_dep_mig_tbl;

Line 1273: gme_debug.put_line('Start procedure '||l_api_name);

1269: l_step_dep_tbl step_dep_tab;
1270: l_api_name VARCHAR2(30) := 'create_step_dependencies';
1271: BEGIN
1272: IF (g_debug <= gme_debug.g_log_procedure) THEN
1273: gme_debug.put_line('Start procedure '||l_api_name);
1274: END IF;
1275: OPEN Cur_get_deps(p_old_batch_id);
1276: FETCH Cur_get_deps BULK COLLECT INTO l_step_dep_mig_tbl;
1277: CLOSE Cur_get_deps;

Line 1331: IF (g_debug <= gme_debug.g_log_procedure) THEN

1327: l_step_dep_tbl(i).chargeable_ind := l_step_dep_mig_tbl(i).chargeable_ind;
1328: END LOOP;
1329: FORALL a IN 1..l_step_dep_tbl.count
1330: INSERT INTO gme_batch_step_dependencies VALUES l_step_dep_tbl(a);
1331: IF (g_debug <= gme_debug.g_log_procedure) THEN
1332: gme_debug.put_line('End procedure '||l_api_name);
1333: END IF;
1334: END create_step_dependencies;
1335:

Line 1332: gme_debug.put_line('End procedure '||l_api_name);

1328: END LOOP;
1329: FORALL a IN 1..l_step_dep_tbl.count
1330: INSERT INTO gme_batch_step_dependencies VALUES l_step_dep_tbl(a);
1331: IF (g_debug <= gme_debug.g_log_procedure) THEN
1332: gme_debug.put_line('End procedure '||l_api_name);
1333: END IF;
1334: END create_step_dependencies;
1335:
1336: PROCEDURE create_item_step_assoc(p_old_batch_id IN NUMBER,

Line 1348: IF (g_debug <= gme_debug.g_log_procedure) THEN

1344: TYPE item_step_tab IS TABLE OF gme_batch_step_items%ROWTYPE INDEX BY BINARY_INTEGER;
1345: l_item_step_tbl item_step_tab;
1346: l_api_name VARCHAR2(30) := 'create_item_step_assoc';
1347: BEGIN
1348: IF (g_debug <= gme_debug.g_log_procedure) THEN
1349: gme_debug.put_line('Start procedure '||l_api_name);
1350: END IF;
1351: OPEN Cur_item_assocs;
1352: FETCH Cur_item_assocs BULK COLLECT INTO l_item_step_mig_tbl;

Line 1349: gme_debug.put_line('Start procedure '||l_api_name);

1345: l_item_step_tbl item_step_tab;
1346: l_api_name VARCHAR2(30) := 'create_item_step_assoc';
1347: BEGIN
1348: IF (g_debug <= gme_debug.g_log_procedure) THEN
1349: gme_debug.put_line('Start procedure '||l_api_name);
1350: END IF;
1351: OPEN Cur_item_assocs;
1352: FETCH Cur_item_assocs BULK COLLECT INTO l_item_step_mig_tbl;
1353: CLOSE Cur_item_assocs;

Line 1370: IF (g_debug <= gme_debug.g_log_procedure) THEN

1366: l_item_step_tbl(i).minimum_transfer_qty := l_item_step_mig_tbl(i).minimum_transfer_qty;
1367: END LOOP;
1368: FORALL a IN 1..l_item_step_tbl.count
1369: INSERT INTO gme_batch_step_items VALUES l_item_step_tbl(a);
1370: IF (g_debug <= gme_debug.g_log_procedure) THEN
1371: gme_debug.put_line('End procedure '||l_api_name);
1372: END IF;
1373: END create_item_step_assoc;
1374:

Line 1371: gme_debug.put_line('End procedure '||l_api_name);

1367: END LOOP;
1368: FORALL a IN 1..l_item_step_tbl.count
1369: INSERT INTO gme_batch_step_items VALUES l_item_step_tbl(a);
1370: IF (g_debug <= gme_debug.g_log_procedure) THEN
1371: gme_debug.put_line('End procedure '||l_api_name);
1372: END IF;
1373: END create_item_step_assoc;
1374:
1375: PROCEDURE create_batch_step_charges(p_old_batch_id IN NUMBER,

Line 1387: IF (g_debug <= gme_debug.g_log_procedure) THEN

1383: TYPE step_chrg_tab IS TABLE OF gme_batch_step_charges%ROWTYPE INDEX BY BINARY_INTEGER;
1384: l_step_chrg_tbl step_chrg_tab;
1385: l_api_name VARCHAR2(30) := 'create_batch_step_charges';
1386: BEGIN
1387: IF (g_debug <= gme_debug.g_log_procedure) THEN
1388: gme_debug.put_line('Start procedure '||l_api_name);
1389: END IF;
1390: OPEN Cur_step_charges;
1391: FETCH Cur_step_charges BULK COLLECT INTO l_step_chrg_mig_tbl;

Line 1388: gme_debug.put_line('Start procedure '||l_api_name);

1384: l_step_chrg_tbl step_chrg_tab;
1385: l_api_name VARCHAR2(30) := 'create_batch_step_charges';
1386: BEGIN
1387: IF (g_debug <= gme_debug.g_log_procedure) THEN
1388: gme_debug.put_line('Start procedure '||l_api_name);
1389: END IF;
1390: OPEN Cur_step_charges;
1391: FETCH Cur_step_charges BULK COLLECT INTO l_step_chrg_mig_tbl;
1392: CLOSE Cur_step_charges;

Line 1410: IF (g_debug <= gme_debug.g_log_procedure) THEN

1406: l_step_chrg_tbl(i).last_update_date := l_step_chrg_mig_tbl(i).last_update_date;
1407: END LOOP;
1408: FORALL a IN 1..l_step_chrg_tbl.count
1409: INSERT INTO gme_batch_step_charges VALUES l_step_chrg_tbl(a);
1410: IF (g_debug <= gme_debug.g_log_procedure) THEN
1411: gme_debug.put_line('End procedure '||l_api_name);
1412: END IF;
1413: END create_batch_step_charges;
1414:

Line 1411: gme_debug.put_line('End procedure '||l_api_name);

1407: END LOOP;
1408: FORALL a IN 1..l_step_chrg_tbl.count
1409: INSERT INTO gme_batch_step_charges VALUES l_step_chrg_tbl(a);
1410: IF (g_debug <= gme_debug.g_log_procedure) THEN
1411: gme_debug.put_line('End procedure '||l_api_name);
1412: END IF;
1413: END create_batch_step_charges;
1414:
1415: PROCEDURE create_batch_step_transfers(p_old_batch_id IN NUMBER,

Line 1427: IF (g_debug <= gme_debug.g_log_procedure) THEN

1423: TYPE step_txfrs_tab IS TABLE OF gme_batch_step_transfers%ROWTYPE INDEX BY BINARY_INTEGER;
1424: l_step_txfrs_tbl step_txfrs_tab;
1425: l_api_name VARCHAR2(30) := 'create_batch_step_transfers';
1426: BEGIN
1427: IF (g_debug <= gme_debug.g_log_procedure) THEN
1428: gme_debug.put_line('Start procedure '||l_api_name);
1429: END IF;
1430: OPEN Cur_step_txfrs;
1431: FETCH Cur_step_txfrs BULK COLLECT INTO l_step_txfrs_mig_tbl;

Line 1428: gme_debug.put_line('Start procedure '||l_api_name);

1424: l_step_txfrs_tbl step_txfrs_tab;
1425: l_api_name VARCHAR2(30) := 'create_batch_step_transfers';
1426: BEGIN
1427: IF (g_debug <= gme_debug.g_log_procedure) THEN
1428: gme_debug.put_line('Start procedure '||l_api_name);
1429: END IF;
1430: OPEN Cur_step_txfrs;
1431: FETCH Cur_step_txfrs BULK COLLECT INTO l_step_txfrs_mig_tbl;
1432: CLOSE Cur_step_txfrs;

Line 1484: IF (g_debug <= gme_debug.g_log_procedure) THEN

1480: l_step_txfrs_tbl(i).trans_qty_um := l_step_txfrs_mig_tbl(i).trans_qty_um;
1481: END LOOP;
1482: FORALL a IN 1..l_step_txfrs_tbl.count
1483: INSERT INTO gme_batch_step_transfers VALUES l_step_txfrs_tbl(a);
1484: IF (g_debug <= gme_debug.g_log_procedure) THEN
1485: gme_debug.put_line('End procedure '||l_api_name);
1486: END IF;
1487: END create_batch_step_transfers;
1488:

Line 1485: gme_debug.put_line('End procedure '||l_api_name);

1481: END LOOP;
1482: FORALL a IN 1..l_step_txfrs_tbl.count
1483: INSERT INTO gme_batch_step_transfers VALUES l_step_txfrs_tbl(a);
1484: IF (g_debug <= gme_debug.g_log_procedure) THEN
1485: gme_debug.put_line('End procedure '||l_api_name);
1486: END IF;
1487: END create_batch_step_transfers;
1488:
1489: PROCEDURE create_batch_mapping(p_batch_header_mig IN gme_batch_header_mig%ROWTYPE,

Line 1543: IF (g_debug <= gme_debug.g_log_procedure) THEN

1539: l_new_prod_line_id NUMBER;
1540: new_phant_batch_not_found EXCEPTION;
1541: new_phant_prod_not_found EXCEPTION;
1542: BEGIN
1543: IF (g_debug <= gme_debug.g_log_procedure) THEN
1544: gme_debug.put_line('Start procedure '||l_api_name);
1545: END IF;
1546: FOR get_phantoms IN Cur_get_phantoms LOOP
1547: BEGIN

Line 1544: gme_debug.put_line('Start procedure '||l_api_name);

1540: new_phant_batch_not_found EXCEPTION;
1541: new_phant_prod_not_found EXCEPTION;
1542: BEGIN
1543: IF (g_debug <= gme_debug.g_log_procedure) THEN
1544: gme_debug.put_line('Start procedure '||l_api_name);
1545: END IF;
1546: FOR get_phantoms IN Cur_get_phantoms LOOP
1547: BEGIN
1548: /* Get new phantom batch ID */

Line 1601: IF (g_debug <= gme_debug.g_log_unexpected) THEN

1597: p_app_short_name => 'GME',
1598: p_token1 => 'BATCH_NO',
1599: p_param1 => get_phantoms.plant_code||'-'||get_phantoms.new_batch_no);
1600: WHEN OTHERS THEN
1601: IF (g_debug <= gme_debug.g_log_unexpected) THEN
1602: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
1603: END IF;
1604: ROLLBACK;
1605: gma_common_logging.gma_migration_central_log

Line 1602: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

1598: p_token1 => 'BATCH_NO',
1599: p_param1 => get_phantoms.plant_code||'-'||get_phantoms.new_batch_no);
1600: WHEN OTHERS THEN
1601: IF (g_debug <= gme_debug.g_log_unexpected) THEN
1602: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
1603: END IF;
1604: ROLLBACK;
1605: gma_common_logging.gma_migration_central_log
1606: (p_run_id => g_migration_run_id,

Line 1619: IF (g_debug <= gme_debug.g_log_procedure) THEN

1615: p_param2 => SQLERRM);
1616: END;
1617: COMMIT;
1618: END LOOP;
1619: IF (g_debug <= gme_debug.g_log_procedure) THEN
1620: gme_debug.put_line('End procedure '||l_api_name);
1621: END IF;
1622: END create_phantom_links;
1623:

Line 1620: gme_debug.put_line('End procedure '||l_api_name);

1616: END;
1617: COMMIT;
1618: END LOOP;
1619: IF (g_debug <= gme_debug.g_log_procedure) THEN
1620: gme_debug.put_line('End procedure '||l_api_name);
1621: END IF;
1622: END create_phantom_links;
1623:
1624: PROCEDURE release_batches IS

Line 1693: IF (g_debug <= gme_debug.g_log_procedure) THEN

1689: step_cmplt_err EXCEPTION;
1690: release_batch_err EXCEPTION;
1691: inv_phantoms_found EXCEPTION;
1692: BEGIN
1693: IF (g_debug <= gme_debug.g_log_procedure) THEN
1694: gme_debug.put_line('Start procedure '||l_api_name);
1695: END IF;
1696: gme_release_batch_pvt.g_bypass_txn_creation := 1;
1697: FOR get_wip_batches IN Cur_wip_batches LOOP

Line 1694: gme_debug.put_line('Start procedure '||l_api_name);

1690: release_batch_err EXCEPTION;
1691: inv_phantoms_found EXCEPTION;
1692: BEGIN
1693: IF (g_debug <= gme_debug.g_log_procedure) THEN
1694: gme_debug.put_line('Start procedure '||l_api_name);
1695: END IF;
1696: gme_release_batch_pvt.g_bypass_txn_creation := 1;
1697: FOR get_wip_batches IN Cur_wip_batches LOOP
1698: BEGIN

Line 1893: IF (g_debug <= gme_debug.g_log_unexpected) THEN

1889: p_param2 => get_steps.batchstep_no,
1890: p_token3 => 'MSG',
1891: p_param3 => l_msg_data);
1892: WHEN OTHERS THEN
1893: IF (g_debug <= gme_debug.g_log_unexpected) THEN
1894: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
1895: END IF;
1896: gma_common_logging.gma_migration_central_log
1897: (p_run_id => g_migration_run_id,

Line 1894: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

1890: p_token3 => 'MSG',
1891: p_param3 => l_msg_data);
1892: WHEN OTHERS THEN
1893: IF (g_debug <= gme_debug.g_log_unexpected) THEN
1894: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
1895: END IF;
1896: gma_common_logging.gma_migration_central_log
1897: (p_run_id => g_migration_run_id,
1898: p_log_level => fnd_log.level_error,

Line 1937: IF (g_debug <= gme_debug.g_log_unexpected) THEN

1933: p_param1 => get_wip_batches.plant_code||'-'||get_wip_batches.new_batch_no,
1934: p_token2 => 'MSG',
1935: p_param2 => l_msg_data);
1936: WHEN OTHERS THEN
1937: IF (g_debug <= gme_debug.g_log_unexpected) THEN
1938: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
1939: END IF;
1940: gma_common_logging.gma_migration_central_log
1941: (p_run_id => g_migration_run_id,

Line 1938: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

1934: p_token2 => 'MSG',
1935: p_param2 => l_msg_data);
1936: WHEN OTHERS THEN
1937: IF (g_debug <= gme_debug.g_log_unexpected) THEN
1938: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
1939: END IF;
1940: gma_common_logging.gma_migration_central_log
1941: (p_run_id => g_migration_run_id,
1942: p_log_level => fnd_log.level_error,

Line 1953: IF (g_debug <= gme_debug.g_log_procedure) THEN

1949: p_token2 => 'MSG',
1950: p_param2 => SQLERRM);
1951: END;
1952: END LOOP;
1953: IF (g_debug <= gme_debug.g_log_procedure) THEN
1954: gme_debug.put_line('End procedure '||l_api_name);
1955: END IF;
1956: END release_batches;
1957:

Line 1954: gme_debug.put_line('End procedure '||l_api_name);

1950: p_param2 => SQLERRM);
1951: END;
1952: END LOOP;
1953: IF (g_debug <= gme_debug.g_log_procedure) THEN
1954: gme_debug.put_line('End procedure '||l_api_name);
1955: END IF;
1956: END release_batches;
1957:
1958: PROCEDURE check_date(p_organization_id IN NUMBER,

Line 2124: IF (g_debug <= gme_debug.g_log_procedure) THEN

2120: WHERE location = p_location;
2121: l_loc_rec ic_loct_mst%ROWTYPE;
2122: l_api_name VARCHAR2(30) := 'create_locator';
2123: BEGIN
2124: IF (g_debug <= gme_debug.g_log_procedure) THEN
2125: gme_debug.put_line('Start procedure '||l_api_name);
2126: END IF;
2127: IF (g_debug <= gme_debug.g_log_statement) THEN
2128: gme_debug.put_line('creating locator '||p_location||'->'||p_organization_id||'-'||p_subinventory_code);

Line 2125: gme_debug.put_line('Start procedure '||l_api_name);

2121: l_loc_rec ic_loct_mst%ROWTYPE;
2122: l_api_name VARCHAR2(30) := 'create_locator';
2123: BEGIN
2124: IF (g_debug <= gme_debug.g_log_procedure) THEN
2125: gme_debug.put_line('Start procedure '||l_api_name);
2126: END IF;
2127: IF (g_debug <= gme_debug.g_log_statement) THEN
2128: gme_debug.put_line('creating locator '||p_location||'->'||p_organization_id||'-'||p_subinventory_code);
2129: END IF;

Line 2127: IF (g_debug <= gme_debug.g_log_statement) THEN

2123: BEGIN
2124: IF (g_debug <= gme_debug.g_log_procedure) THEN
2125: gme_debug.put_line('Start procedure '||l_api_name);
2126: END IF;
2127: IF (g_debug <= gme_debug.g_log_statement) THEN
2128: gme_debug.put_line('creating locator '||p_location||'->'||p_organization_id||'-'||p_subinventory_code);
2129: END IF;
2130: OPEN Cur_loc_details;
2131: FETCH Cur_loc_details INTO l_loc_rec;

Line 2128: gme_debug.put_line('creating locator '||p_location||'->'||p_organization_id||'-'||p_subinventory_code);

2124: IF (g_debug <= gme_debug.g_log_procedure) THEN
2125: gme_debug.put_line('Start procedure '||l_api_name);
2126: END IF;
2127: IF (g_debug <= gme_debug.g_log_statement) THEN
2128: gme_debug.put_line('creating locator '||p_location||'->'||p_organization_id||'-'||p_subinventory_code);
2129: END IF;
2130: OPEN Cur_loc_details;
2131: FETCH Cur_loc_details INTO l_loc_rec;
2132: CLOSE Cur_loc_details;

Line 2162: IF (g_debug <= gme_debug.g_log_procedure) THEN

2158: p_segment17 => NULL,
2159: p_segment18 => NULL,
2160: p_segment19 => NULL,
2161: p_segment20 => NULL);
2162: IF (g_debug <= gme_debug.g_log_procedure) THEN
2163: gme_debug.put_line('End procedure '||l_api_name);
2164: END IF;
2165: END create_locator;
2166:

Line 2163: gme_debug.put_line('End procedure '||l_api_name);

2159: p_segment18 => NULL,
2160: p_segment19 => NULL,
2161: p_segment20 => NULL);
2162: IF (g_debug <= gme_debug.g_log_procedure) THEN
2163: gme_debug.put_line('End procedure '||l_api_name);
2164: END IF;
2165: END create_locator;
2166:
2167: PROCEDURE get_subinv_locator_type(p_subinventory IN VARCHAR2,

Line 2263: IF (g_debug <= gme_debug.g_log_procedure) THEN

2259: expected_error EXCEPTION;
2260: defined_error EXCEPTION;
2261:
2262: BEGIN
2263: IF (g_debug <= gme_debug.g_log_procedure) THEN
2264: gme_debug.put_line('Start procedure '||l_api_name);
2265: END IF;
2266: /* Bug 5620671 Added param completed ind */
2267: OPEN Cur_get_txns(p_completed_ind);

Line 2264: gme_debug.put_line('Start procedure '||l_api_name);

2260: defined_error EXCEPTION;
2261:
2262: BEGIN
2263: IF (g_debug <= gme_debug.g_log_procedure) THEN
2264: gme_debug.put_line('Start procedure '||l_api_name);
2265: END IF;
2266: /* Bug 5620671 Added param completed ind */
2267: OPEN Cur_get_txns(p_completed_ind);
2268: FETCH Cur_get_txns BULK COLLECT INTO l_txns_tbl;

Line 2272: IF (g_debug <= gme_debug.g_log_statement) THEN

2268: FETCH Cur_get_txns BULK COLLECT INTO l_txns_tbl;
2269: CLOSE Cur_get_txns;
2270:
2271: l_count := l_txns_tbl.count;
2272: IF (g_debug <= gme_debug.g_log_statement) THEN
2273: gme_debug.put_line('No. of txns = '||l_count);
2274: END IF;
2275:
2276: FOR i IN 1..l_count LOOP

Line 2273: gme_debug.put_line('No. of txns = '||l_count);

2269: CLOSE Cur_get_txns;
2270:
2271: l_count := l_txns_tbl.count;
2272: IF (g_debug <= gme_debug.g_log_statement) THEN
2273: gme_debug.put_line('No. of txns = '||l_count);
2274: END IF;
2275:
2276: FOR i IN 1..l_count LOOP
2277: BEGIN

Line 2278: IF (g_debug <= gme_debug.g_log_statement) THEN

2274: END IF;
2275:
2276: FOR i IN 1..l_count LOOP
2277: BEGIN
2278: IF (g_debug <= gme_debug.g_log_statement) THEN
2279: gme_debug.put_line('Processing trans_id = '||l_txns_tbl(i).trans_id);
2280: gme_debug.put_line('l_curr_org_id = '||l_curr_org_id||' l_txns_tbl(i).organization_id = '||l_txns_tbl(i).organization_id);
2281: END IF;
2282: gme_common_pvt.g_transaction_header_id := NULL;

Line 2279: gme_debug.put_line('Processing trans_id = '||l_txns_tbl(i).trans_id);

2275:
2276: FOR i IN 1..l_count LOOP
2277: BEGIN
2278: IF (g_debug <= gme_debug.g_log_statement) THEN
2279: gme_debug.put_line('Processing trans_id = '||l_txns_tbl(i).trans_id);
2280: gme_debug.put_line('l_curr_org_id = '||l_curr_org_id||' l_txns_tbl(i).organization_id = '||l_txns_tbl(i).organization_id);
2281: END IF;
2282: gme_common_pvt.g_transaction_header_id := NULL;
2283: l_lot_number := NULL;

Line 2280: gme_debug.put_line('l_curr_org_id = '||l_curr_org_id||' l_txns_tbl(i).organization_id = '||l_txns_tbl(i).organization_id);

2276: FOR i IN 1..l_count LOOP
2277: BEGIN
2278: IF (g_debug <= gme_debug.g_log_statement) THEN
2279: gme_debug.put_line('Processing trans_id = '||l_txns_tbl(i).trans_id);
2280: gme_debug.put_line('l_curr_org_id = '||l_curr_org_id||' l_txns_tbl(i).organization_id = '||l_txns_tbl(i).organization_id);
2281: END IF;
2282: gme_common_pvt.g_transaction_header_id := NULL;
2283: l_lot_number := NULL;
2284: l_subinventory := NULL;

Line 2299: IF (g_debug <= gme_debug.g_log_statement) THEN

2295: IF NOT (gme_common_pvt.setup(p_org_id => l_txns_tbl(i).organization_id)) THEN
2296: RAISE setup_failed;
2297: END IF;
2298: l_curr_org_id := l_txns_tbl(i).organization_id;
2299: IF (g_debug <= gme_debug.g_log_statement) THEN
2300: gme_debug.put_line('gme_common_pvt.g_organization_id = '||gme_common_pvt.g_organization_id||' gme_common_pvt.g_organization_code = '||gme_common_pvt.g_organization_code);
2301: END IF;
2302: END IF;
2303:

Line 2300: gme_debug.put_line('gme_common_pvt.g_organization_id = '||gme_common_pvt.g_organization_id||' gme_common_pvt.g_organization_code = '||gme_common_pvt.g_organization_code);

2296: RAISE setup_failed;
2297: END IF;
2298: l_curr_org_id := l_txns_tbl(i).organization_id;
2299: IF (g_debug <= gme_debug.g_log_statement) THEN
2300: gme_debug.put_line('gme_common_pvt.g_organization_id = '||gme_common_pvt.g_organization_id||' gme_common_pvt.g_organization_code = '||gme_common_pvt.g_organization_code);
2301: END IF;
2302: END IF;
2303:
2304: IF (l_curr_batch_id <> l_txns_tbl(i).new_batch_id) THEN

Line 2321: IF (g_debug <= gme_debug.g_log_statement) THEN

2317: FETCH Cur_mtl_dtl INTO l_mtl_rec;
2318: CLOSE Cur_mtl_dtl;
2319: END IF;
2320:
2321: IF (g_debug <= gme_debug.g_log_statement) THEN
2322: gme_debug.put_line('Processing transaction for Batch = '||gme_common_pvt.g_organization_code||'-'||l_batch_hdr.batch_no||' Line Type = '||l_mtl_rec.line_type||' Line No = '||l_mtl_rec.line_no||' Phantom_type = '||l_mtl_rec.phantom_type);
2323: END IF;
2324:
2325: /* Do not create phantom ing txns these will be created by phantom prod txns */

Line 2322: gme_debug.put_line('Processing transaction for Batch = '||gme_common_pvt.g_organization_code||'-'||l_batch_hdr.batch_no||' Line Type = '||l_mtl_rec.line_type||' Line No = '||l_mtl_rec.line_no||' Phantom_type = '||l_mtl_rec.phantom_type);

2318: CLOSE Cur_mtl_dtl;
2319: END IF;
2320:
2321: IF (g_debug <= gme_debug.g_log_statement) THEN
2322: gme_debug.put_line('Processing transaction for Batch = '||gme_common_pvt.g_organization_code||'-'||l_batch_hdr.batch_no||' Line Type = '||l_mtl_rec.line_type||' Line No = '||l_mtl_rec.line_no||' Phantom_type = '||l_mtl_rec.phantom_type);
2323: END IF;
2324:
2325: /* Do not create phantom ing txns these will be created by phantom prod txns */
2326: IF NOT(l_mtl_rec.line_type = gme_common_pvt.g_line_type_ing AND l_mtl_rec.phantom_type IN (gme_common_pvt.g_auto_phantom, gme_common_pvt.g_manual_phantom)) THEN

Line 2327: IF (g_debug <= gme_debug.g_log_statement) THEN

2323: END IF;
2324:
2325: /* Do not create phantom ing txns these will be created by phantom prod txns */
2326: IF NOT(l_mtl_rec.line_type = gme_common_pvt.g_line_type_ing AND l_mtl_rec.phantom_type IN (gme_common_pvt.g_auto_phantom, gme_common_pvt.g_manual_phantom)) THEN
2327: IF (g_debug <= gme_debug.g_log_statement) THEN
2328: gme_debug.put_line('Not a phantom ing txn');
2329: END IF;
2330:
2331: IF (l_txns_tbl(i).completed_ind = 1) THEN

Line 2328: gme_debug.put_line('Not a phantom ing txn');

2324:
2325: /* Do not create phantom ing txns these will be created by phantom prod txns */
2326: IF NOT(l_mtl_rec.line_type = gme_common_pvt.g_line_type_ing AND l_mtl_rec.phantom_type IN (gme_common_pvt.g_auto_phantom, gme_common_pvt.g_manual_phantom)) THEN
2327: IF (g_debug <= gme_debug.g_log_statement) THEN
2328: gme_debug.put_line('Not a phantom ing txn');
2329: END IF;
2330:
2331: IF (l_txns_tbl(i).completed_ind = 1) THEN
2332: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 2332: IF (g_debug <= gme_debug.g_log_statement) THEN

2328: gme_debug.put_line('Not a phantom ing txn');
2329: END IF;
2330:
2331: IF (l_txns_tbl(i).completed_ind = 1) THEN
2332: IF (g_debug <= gme_debug.g_log_statement) THEN
2333: gme_debug.put_line('This is a completed txn');
2334: END IF;
2335:
2336: IF (l_batch_hdr.batch_status <= 1) THEN

Line 2333: gme_debug.put_line('This is a completed txn');

2329: END IF;
2330:
2331: IF (l_txns_tbl(i).completed_ind = 1) THEN
2332: IF (g_debug <= gme_debug.g_log_statement) THEN
2333: gme_debug.put_line('This is a completed txn');
2334: END IF;
2335:
2336: IF (l_batch_hdr.batch_status <= 1) THEN
2337: l_msg_name := 'GME_MIG_BATCH_INVALID_FOR_TXN';

Line 2347: IF (g_debug <= gme_debug.g_log_statement) THEN

2343: RAISE defined_error;
2344: END IF;
2345:
2346: SELECT mtl_material_transactions_s.NEXTVAL INTO gme_common_pvt.g_transaction_header_id FROM DUAL;
2347: IF (g_debug <= gme_debug.g_log_statement) THEN
2348: gme_debug.put_line('Transaction header ID = '||gme_common_pvt.g_transaction_header_id);
2349: END IF;
2350:
2351: l_mmti_rec.transaction_source_id := l_mtl_rec.batch_id;

Line 2348: gme_debug.put_line('Transaction header ID = '||gme_common_pvt.g_transaction_header_id);

2344: END IF;
2345:
2346: SELECT mtl_material_transactions_s.NEXTVAL INTO gme_common_pvt.g_transaction_header_id FROM DUAL;
2347: IF (g_debug <= gme_debug.g_log_statement) THEN
2348: gme_debug.put_line('Transaction header ID = '||gme_common_pvt.g_transaction_header_id);
2349: END IF;
2350:
2351: l_mmti_rec.transaction_source_id := l_mtl_rec.batch_id;
2352: l_mmti_rec.trx_source_line_id := l_mtl_rec.material_detail_id;

Line 2366: IF (g_debug <= gme_debug.g_log_statement) THEN

2362: ELSE
2363: l_mmti_rec.revision := NULL;
2364: END IF;
2365:
2366: IF (g_debug <= gme_debug.g_log_statement) THEN
2367: gme_debug.put_line('After revision before check date');
2368: END IF;
2369:
2370: check_date(p_organization_id => l_mtl_rec.organization_id,

Line 2367: gme_debug.put_line('After revision before check date');

2363: l_mmti_rec.revision := NULL;
2364: END IF;
2365:
2366: IF (g_debug <= gme_debug.g_log_statement) THEN
2367: gme_debug.put_line('After revision before check date');
2368: END IF;
2369:
2370: check_date(p_organization_id => l_mtl_rec.organization_id,
2371: p_date => l_txns_tbl(i).trans_date,

Line 2429: IF (g_debug <= gme_debug.g_log_statement) THEN

2425: p_param3 => l_txn_data,
2426: p_token4 => 'REASON_CODE',
2427: p_param4 => l_txns_tbl(i).reason_code);
2428: END IF;
2429: IF (g_debug <= gme_debug.g_log_statement) THEN
2430: gme_debug.put_line('After putting all values in l_mmti_rec');
2431: END IF;
2432:
2433: /* If item is location controlled then get locator/sub/org otherwise get sub/org */

Line 2430: gme_debug.put_line('After putting all values in l_mmti_rec');

2426: p_token4 => 'REASON_CODE',
2427: p_param4 => l_txns_tbl(i).reason_code);
2428: END IF;
2429: IF (g_debug <= gme_debug.g_log_statement) THEN
2430: gme_debug.put_line('After putting all values in l_mmti_rec');
2431: END IF;
2432:
2433: /* If item is location controlled then get locator/sub/org otherwise get sub/org */
2434: IF (NVL(l_txns_tbl(i).location, l_def_location) <> l_def_location) THEN

Line 2441: IF (g_debug <= gme_debug.g_log_statement) THEN

2437: x_organization_id => l_org_id,
2438: x_locator_id => l_locator_id,
2439: x_subinventory => l_subinventory);
2440: END IF;
2441: IF (g_debug <= gme_debug.g_log_statement) THEN
2442: gme_debug.put_line('One l_org_id = '||l_org_id||' l_subinventory = '||l_subinventory||' l_locator_id = '||l_locator_id );
2443: END IF;
2444:
2445: /* If we have sub it means locator exists otherwise get sub */

Line 2442: gme_debug.put_line('One l_org_id = '||l_org_id||' l_subinventory = '||l_subinventory||' l_locator_id = '||l_locator_id );

2438: x_locator_id => l_locator_id,
2439: x_subinventory => l_subinventory);
2440: END IF;
2441: IF (g_debug <= gme_debug.g_log_statement) THEN
2442: gme_debug.put_line('One l_org_id = '||l_org_id||' l_subinventory = '||l_subinventory||' l_locator_id = '||l_locator_id );
2443: END IF;
2444:
2445: /* If we have sub it means locator exists otherwise get sub */
2446: IF (l_subinventory IS NULL) THEN

Line 2455: IF (g_debug <= gme_debug.g_log_statement) THEN

2451: l_msg_name := 'GME_MIG_SUBINV_NOT_FOUND';
2452: RAISE defined_error;
2453: END IF;
2454: END IF;
2455: IF (g_debug <= gme_debug.g_log_statement) THEN
2456: gme_debug.put_line('Two l_org_id = '||l_org_id||' l_subinventory = '||l_subinventory||' l_locator_id = '||l_locator_id );
2457: gme_debug.put_line('l_org_id = '||l_org_id||' l_mmti_rec.organization_id = '||l_mmti_rec.organization_id);
2458: END IF;
2459:

Line 2456: gme_debug.put_line('Two l_org_id = '||l_org_id||' l_subinventory = '||l_subinventory||' l_locator_id = '||l_locator_id );

2452: RAISE defined_error;
2453: END IF;
2454: END IF;
2455: IF (g_debug <= gme_debug.g_log_statement) THEN
2456: gme_debug.put_line('Two l_org_id = '||l_org_id||' l_subinventory = '||l_subinventory||' l_locator_id = '||l_locator_id );
2457: gme_debug.put_line('l_org_id = '||l_org_id||' l_mmti_rec.organization_id = '||l_mmti_rec.organization_id);
2458: END IF;
2459:
2460: /* If subinventory is in same org as batch then it is fine or we have to do issue/receipt */

Line 2457: gme_debug.put_line('l_org_id = '||l_org_id||' l_mmti_rec.organization_id = '||l_mmti_rec.organization_id);

2453: END IF;
2454: END IF;
2455: IF (g_debug <= gme_debug.g_log_statement) THEN
2456: gme_debug.put_line('Two l_org_id = '||l_org_id||' l_subinventory = '||l_subinventory||' l_locator_id = '||l_locator_id );
2457: gme_debug.put_line('l_org_id = '||l_org_id||' l_mmti_rec.organization_id = '||l_mmti_rec.organization_id);
2458: END IF;
2459:
2460: /* If subinventory is in same org as batch then it is fine or we have to do issue/receipt */
2461: IF (l_org_id <> l_mmti_rec.organization_id) THEN

Line 2463: IF (g_debug <= gme_debug.g_log_statement) THEN

2459:
2460: /* If subinventory is in same org as batch then it is fine or we have to do issue/receipt */
2461: IF (l_org_id <> l_mmti_rec.organization_id) THEN
2462: /* Create a misc issue in l_org_id and a receipt in l_mmti_rec.organization_id */
2463: IF (g_debug <= gme_debug.g_log_statement) THEN
2464: gme_debug.put_line('creating issue/receipt from org = '||l_org_id||' to org = '||l_mmti_rec.organization_id);
2465: END IF;
2466: create_issue_receipt(p_curr_org_id => l_org_id,
2467: p_inventory_item_id => l_mtl_rec.inventory_item_id,

Line 2464: gme_debug.put_line('creating issue/receipt from org = '||l_org_id||' to org = '||l_mmti_rec.organization_id);

2460: /* If subinventory is in same org as batch then it is fine or we have to do issue/receipt */
2461: IF (l_org_id <> l_mmti_rec.organization_id) THEN
2462: /* Create a misc issue in l_org_id and a receipt in l_mmti_rec.organization_id */
2463: IF (g_debug <= gme_debug.g_log_statement) THEN
2464: gme_debug.put_line('creating issue/receipt from org = '||l_org_id||' to org = '||l_mmti_rec.organization_id);
2465: END IF;
2466: create_issue_receipt(p_curr_org_id => l_org_id,
2467: p_inventory_item_id => l_mtl_rec.inventory_item_id,
2468: p_txn_rec => l_txns_tbl(i),

Line 2493: IF (g_debug <= gme_debug.g_log_statement) THEN

2489: l_msg_name := 'GME_MIG_INV_TRANSFER_FAIL';
2490: RAISE create_txn_rsv_pp_err;
2491: END IF;
2492: ELSE
2493: IF (g_debug <= gme_debug.g_log_statement) THEN
2494: gme_debug.put_line('All in same org');
2495: END IF;
2496: IF NOT (gme_common_pvt.check_subinventory(p_organization_id => l_mtl_rec.organization_id
2497: ,p_subinventory => l_subinventory

Line 2494: gme_debug.put_line('All in same org');

2490: RAISE create_txn_rsv_pp_err;
2491: END IF;
2492: ELSE
2493: IF (g_debug <= gme_debug.g_log_statement) THEN
2494: gme_debug.put_line('All in same org');
2495: END IF;
2496: IF NOT (gme_common_pvt.check_subinventory(p_organization_id => l_mtl_rec.organization_id
2497: ,p_subinventory => l_subinventory
2498: ,p_inventory_item_id => l_mtl_rec.inventory_item_id

Line 2551: IF (g_debug <= gme_debug.g_log_statement) THEN

2547: l_mmti_rec.subinventory_code := l_subinventory;
2548: l_mmti_rec.locator_id := l_locator_id;
2549: END IF;
2550:
2551: IF (g_debug <= gme_debug.g_log_statement) THEN
2552: gme_debug.put_line('Lot control code is '||l_mtl_rec.lot_control_code);
2553: END IF;
2554:
2555: IF (l_mtl_rec.lot_control_code = 2) THEN

Line 2552: gme_debug.put_line('Lot control code is '||l_mtl_rec.lot_control_code);

2548: l_mmti_rec.locator_id := l_locator_id;
2549: END IF;
2550:
2551: IF (g_debug <= gme_debug.g_log_statement) THEN
2552: gme_debug.put_line('Lot control code is '||l_mtl_rec.lot_control_code);
2553: END IF;
2554:
2555: IF (l_mtl_rec.lot_control_code = 2) THEN
2556: IF (l_lot_number IS NULL) THEN

Line 2557: IF (g_debug <= gme_debug.g_log_statement) THEN

2553: END IF;
2554:
2555: IF (l_mtl_rec.lot_control_code = 2) THEN
2556: IF (l_lot_number IS NULL) THEN
2557: IF (g_debug <= gme_debug.g_log_statement) THEN
2558: gme_debug.put_line('CALL 1 to get_odm_lot. values passed in are:');
2559: gme_debug.put_line('loop i iteration is '||i);
2560: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2561: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);

Line 2558: gme_debug.put_line('CALL 1 to get_odm_lot. values passed in are:');

2554:
2555: IF (l_mtl_rec.lot_control_code = 2) THEN
2556: IF (l_lot_number IS NULL) THEN
2557: IF (g_debug <= gme_debug.g_log_statement) THEN
2558: gme_debug.put_line('CALL 1 to get_odm_lot. values passed in are:');
2559: gme_debug.put_line('loop i iteration is '||i);
2560: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2561: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2562: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);

Line 2559: gme_debug.put_line('loop i iteration is '||i);

2555: IF (l_mtl_rec.lot_control_code = 2) THEN
2556: IF (l_lot_number IS NULL) THEN
2557: IF (g_debug <= gme_debug.g_log_statement) THEN
2558: gme_debug.put_line('CALL 1 to get_odm_lot. values passed in are:');
2559: gme_debug.put_line('loop i iteration is '||i);
2560: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2561: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2562: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2563: gme_debug.put_line('p_orgn_code NULL');

Line 2560: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);

2556: IF (l_lot_number IS NULL) THEN
2557: IF (g_debug <= gme_debug.g_log_statement) THEN
2558: gme_debug.put_line('CALL 1 to get_odm_lot. values passed in are:');
2559: gme_debug.put_line('loop i iteration is '||i);
2560: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2561: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2562: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2563: gme_debug.put_line('p_orgn_code NULL');
2564: gme_debug.put_line('p_location '||l_txns_tbl(i).location);

Line 2561: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);

2557: IF (g_debug <= gme_debug.g_log_statement) THEN
2558: gme_debug.put_line('CALL 1 to get_odm_lot. values passed in are:');
2559: gme_debug.put_line('loop i iteration is '||i);
2560: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2561: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2562: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2563: gme_debug.put_line('p_orgn_code NULL');
2564: gme_debug.put_line('p_location '||l_txns_tbl(i).location);
2565: END IF;

Line 2562: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);

2558: gme_debug.put_line('CALL 1 to get_odm_lot. values passed in are:');
2559: gme_debug.put_line('loop i iteration is '||i);
2560: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2561: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2562: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2563: gme_debug.put_line('p_orgn_code NULL');
2564: gme_debug.put_line('p_location '||l_txns_tbl(i).location);
2565: END IF;
2566:

Line 2563: gme_debug.put_line('p_orgn_code NULL');

2559: gme_debug.put_line('loop i iteration is '||i);
2560: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2561: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2562: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2563: gme_debug.put_line('p_orgn_code NULL');
2564: gme_debug.put_line('p_location '||l_txns_tbl(i).location);
2565: END IF;
2566:
2567: inv_opm_lot_migration.get_odm_lot(p_migration_run_id => g_migration_run_id,

Line 2564: gme_debug.put_line('p_location '||l_txns_tbl(i).location);

2560: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2561: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2562: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2563: gme_debug.put_line('p_orgn_code NULL');
2564: gme_debug.put_line('p_location '||l_txns_tbl(i).location);
2565: END IF;
2566:
2567: inv_opm_lot_migration.get_odm_lot(p_migration_run_id => g_migration_run_id,
2568: p_item_id => l_txns_tbl(i).item_id,

Line 2578: IF (g_debug <= gme_debug.g_log_statement) THEN

2574: x_lot_number => l_lot_number,
2575: x_parent_lot_number => l_parent_lot_no,
2576: x_failure_count => l_failure_count);
2577:
2578: IF (g_debug <= gme_debug.g_log_statement) THEN
2579: gme_debug.put_line('RETURN from get_odm_lot.');
2580: gme_debug.put_line('l_failure_count is '||l_failure_count);
2581: gme_debug.put_line('l_lot_number '||l_lot_number);
2582: END IF;

Line 2579: gme_debug.put_line('RETURN from get_odm_lot.');

2575: x_parent_lot_number => l_parent_lot_no,
2576: x_failure_count => l_failure_count);
2577:
2578: IF (g_debug <= gme_debug.g_log_statement) THEN
2579: gme_debug.put_line('RETURN from get_odm_lot.');
2580: gme_debug.put_line('l_failure_count is '||l_failure_count);
2581: gme_debug.put_line('l_lot_number '||l_lot_number);
2582: END IF;
2583:

Line 2580: gme_debug.put_line('l_failure_count is '||l_failure_count);

2576: x_failure_count => l_failure_count);
2577:
2578: IF (g_debug <= gme_debug.g_log_statement) THEN
2579: gme_debug.put_line('RETURN from get_odm_lot.');
2580: gme_debug.put_line('l_failure_count is '||l_failure_count);
2581: gme_debug.put_line('l_lot_number '||l_lot_number);
2582: END IF;
2583:
2584: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN

Line 2581: gme_debug.put_line('l_lot_number '||l_lot_number);

2577:
2578: IF (g_debug <= gme_debug.g_log_statement) THEN
2579: gme_debug.put_line('RETURN from get_odm_lot.');
2580: gme_debug.put_line('l_failure_count is '||l_failure_count);
2581: gme_debug.put_line('l_lot_number '||l_lot_number);
2582: END IF;
2583:
2584: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
2585: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';

Line 2586: IF (g_debug <= gme_debug.g_log_statement) THEN

2582: END IF;
2583:
2584: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
2585: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';
2586: IF (g_debug <= gme_debug.g_log_statement) THEN
2587: gme_debug.put_line('ERROR is raised here');
2588: END IF;
2589: RAISE defined_error;
2590: END IF;

Line 2587: gme_debug.put_line('ERROR is raised here');

2583:
2584: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
2585: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';
2586: IF (g_debug <= gme_debug.g_log_statement) THEN
2587: gme_debug.put_line('ERROR is raised here');
2588: END IF;
2589: RAISE defined_error;
2590: END IF;
2591: END IF;

Line 2595: IF (g_debug <= gme_debug.g_log_statement) THEN

2591: END IF;
2592: l_mmli_tbl(1).lot_number := l_lot_number;
2593: END IF;
2594:
2595: IF (g_debug <= gme_debug.g_log_statement) THEN
2596: gme_debug.put_line('After Lot processing lot is '||l_lot_number);
2597: END IF;
2598:
2599: IF (l_mtl_rec.dtl_um <> l_mtl_rec.primary_uom_code) THEN

Line 2596: gme_debug.put_line('After Lot processing lot is '||l_lot_number);

2592: l_mmli_tbl(1).lot_number := l_lot_number;
2593: END IF;
2594:
2595: IF (g_debug <= gme_debug.g_log_statement) THEN
2596: gme_debug.put_line('After Lot processing lot is '||l_lot_number);
2597: END IF;
2598:
2599: IF (l_mtl_rec.dtl_um <> l_mtl_rec.primary_uom_code) THEN
2600: l_mmti_rec.transaction_quantity := inv_convert.inv_um_convert(item_id => l_mtl_rec.inventory_item_id

Line 2636: IF (g_debug <= gme_debug.g_log_statement) THEN

2632: 'locator id '||l_mmti_rec.locator_id||'->'||'lot_number '||l_lot_number||'->'||
2633: 'trans qty '||l_mmti_rec.transaction_quantity||'->'||'trans uom '||l_mmti_rec.transaction_uom||'->'||
2634: 'trans date '||to_char(l_mmti_rec.transaction_date, 'DD-MON-YYYY HH24:MI:SS');
2635:
2636: IF (g_debug <= gme_debug.g_log_statement) THEN
2637: gme_debug.put_line('Creating TXN with '||l_new_data);
2638: END IF;
2639: gme_api_pub.create_material_txn(p_api_version => 2.0,
2640: p_validation_level => gme_common_pvt.g_max_errors,

Line 2637: gme_debug.put_line('Creating TXN with '||l_new_data);

2633: 'trans qty '||l_mmti_rec.transaction_quantity||'->'||'trans uom '||l_mmti_rec.transaction_uom||'->'||
2634: 'trans date '||to_char(l_mmti_rec.transaction_date, 'DD-MON-YYYY HH24:MI:SS');
2635:
2636: IF (g_debug <= gme_debug.g_log_statement) THEN
2637: gme_debug.put_line('Creating TXN with '||l_new_data);
2638: END IF;
2639: gme_api_pub.create_material_txn(p_api_version => 2.0,
2640: p_validation_level => gme_common_pvt.g_max_errors,
2641: p_init_msg_list => fnd_api.g_false,

Line 2668: IF (g_debug <= gme_debug.g_log_statement) THEN

2664: -- SET OPM_COSTED_FLAG = NULL
2665: -- WHERE transaction_id = l_mmt_rec.transaction_id;
2666:
2667: ELSE /* IF (l_txns_tbl(i).completed_ind = 1) THEN */
2668: IF (g_debug <= gme_debug.g_log_statement) THEN
2669: gme_debug.put_line('This is a pending txn');
2670: END IF;
2671: l_mmti_rec.transaction_source_id := l_mtl_rec.batch_id;
2672: l_mmti_rec.trx_source_line_id := l_mtl_rec.material_detail_id;

Line 2669: gme_debug.put_line('This is a pending txn');

2665: -- WHERE transaction_id = l_mmt_rec.transaction_id;
2666:
2667: ELSE /* IF (l_txns_tbl(i).completed_ind = 1) THEN */
2668: IF (g_debug <= gme_debug.g_log_statement) THEN
2669: gme_debug.put_line('This is a pending txn');
2670: END IF;
2671: l_mmti_rec.transaction_source_id := l_mtl_rec.batch_id;
2672: l_mmti_rec.trx_source_line_id := l_mtl_rec.material_detail_id;
2673: l_mmti_rec.inventory_item_id := l_mtl_rec.inventory_item_id;

Line 2677: IF (g_debug <= gme_debug.g_log_statement) THEN

2673: l_mmti_rec.inventory_item_id := l_mtl_rec.inventory_item_id;
2674: l_mmti_rec.organization_id := l_mtl_rec.organization_id;
2675:
2676: IF (l_mtl_rec.line_type = gme_common_pvt.g_line_type_ing) THEN
2677: IF (g_debug <= gme_debug.g_log_statement) THEN
2678: gme_debug.put_line('Ing so we will create a reservation');
2679: END IF;
2680:
2681: IF (l_mtl_rec.reservable_type <> 1) THEN

Line 2678: gme_debug.put_line('Ing so we will create a reservation');

2674: l_mmti_rec.organization_id := l_mtl_rec.organization_id;
2675:
2676: IF (l_mtl_rec.line_type = gme_common_pvt.g_line_type_ing) THEN
2677: IF (g_debug <= gme_debug.g_log_statement) THEN
2678: gme_debug.put_line('Ing so we will create a reservation');
2679: END IF;
2680:
2681: IF (l_mtl_rec.reservable_type <> 1) THEN
2682: l_msg_name := 'GME_MIG_ITEM_NOT_RESV_ENABLED';

Line 2742: IF (g_debug <= gme_debug.g_log_statement) THEN

2738: ELSE
2739: l_mtl_dtl_rec.revision := NULL;
2740: END IF;
2741:
2742: IF (g_debug <= gme_debug.g_log_statement) THEN
2743: gme_debug.put_line('After defaulting ing');
2744: END IF;
2745:
2746: IF (NVL(l_txns_tbl(i).location, l_def_location) <> l_def_location) THEN

Line 2743: gme_debug.put_line('After defaulting ing');

2739: l_mtl_dtl_rec.revision := NULL;
2740: END IF;
2741:
2742: IF (g_debug <= gme_debug.g_log_statement) THEN
2743: gme_debug.put_line('After defaulting ing');
2744: END IF;
2745:
2746: IF (NVL(l_txns_tbl(i).location, l_def_location) <> l_def_location) THEN
2747: get_locator(p_location => l_txns_tbl(i).location,

Line 2753: IF (g_debug <= gme_debug.g_log_statement) THEN

2749: x_organization_id => l_org_id,
2750: x_locator_id => l_locator_id,
2751: x_subinventory => l_subinventory);
2752: END IF;
2753: IF (g_debug <= gme_debug.g_log_statement) THEN
2754: gme_debug.put_line('Three locator_id = '||l_locator_id||' subinventory = '||l_subinventory||' org_id = '||l_org_id);
2755: END IF;
2756: IF (l_subinventory IS NULL) THEN
2757: get_subinventory(p_whse_code => l_txns_tbl(i).whse_code,

Line 2754: gme_debug.put_line('Three locator_id = '||l_locator_id||' subinventory = '||l_subinventory||' org_id = '||l_org_id);

2750: x_locator_id => l_locator_id,
2751: x_subinventory => l_subinventory);
2752: END IF;
2753: IF (g_debug <= gme_debug.g_log_statement) THEN
2754: gme_debug.put_line('Three locator_id = '||l_locator_id||' subinventory = '||l_subinventory||' org_id = '||l_org_id);
2755: END IF;
2756: IF (l_subinventory IS NULL) THEN
2757: get_subinventory(p_whse_code => l_txns_tbl(i).whse_code,
2758: x_subinventory => l_subinventory,

Line 2763: IF (g_debug <= gme_debug.g_log_statement) THEN

2759: x_organization_id => l_org_id);
2760: END IF;
2761:
2762: /* If this txn is in a different org than the batch org then do a issue and receipt */
2763: IF (g_debug <= gme_debug.g_log_statement) THEN
2764: gme_debug.put_line('Four l_subinventory = '||l_subinventory||' l_org_id = '||l_org_id||' l_mmti_rec.organization_id = '||l_mmti_rec.organization_id);
2765: gme_debug.put_line('creating issue/receipt from org = '||l_org_id||' to org = '||l_mmti_rec.organization_id);
2766: END IF;
2767:

Line 2764: gme_debug.put_line('Four l_subinventory = '||l_subinventory||' l_org_id = '||l_org_id||' l_mmti_rec.organization_id = '||l_mmti_rec.organization_id);

2760: END IF;
2761:
2762: /* If this txn is in a different org than the batch org then do a issue and receipt */
2763: IF (g_debug <= gme_debug.g_log_statement) THEN
2764: gme_debug.put_line('Four l_subinventory = '||l_subinventory||' l_org_id = '||l_org_id||' l_mmti_rec.organization_id = '||l_mmti_rec.organization_id);
2765: gme_debug.put_line('creating issue/receipt from org = '||l_org_id||' to org = '||l_mmti_rec.organization_id);
2766: END IF;
2767:
2768: IF (l_org_id <> l_mmti_rec.organization_id) THEN

Line 2765: gme_debug.put_line('creating issue/receipt from org = '||l_org_id||' to org = '||l_mmti_rec.organization_id);

2761:
2762: /* If this txn is in a different org than the batch org then do a issue and receipt */
2763: IF (g_debug <= gme_debug.g_log_statement) THEN
2764: gme_debug.put_line('Four l_subinventory = '||l_subinventory||' l_org_id = '||l_org_id||' l_mmti_rec.organization_id = '||l_mmti_rec.organization_id);
2765: gme_debug.put_line('creating issue/receipt from org = '||l_org_id||' to org = '||l_mmti_rec.organization_id);
2766: END IF;
2767:
2768: IF (l_org_id <> l_mmti_rec.organization_id) THEN
2769: /* Create a misc issue in l_org_id and a receipt in l_mmti_rec.organization_id */

Line 2795: IF (g_debug <= gme_debug.g_log_statement) THEN

2791: END IF;
2792:
2793: l_mmti_rec.transaction_date := l_date;
2794: SELECT mtl_material_transactions_s.NEXTVAL INTO gme_common_pvt.g_transaction_header_id FROM DUAL;
2795: IF (g_debug <= gme_debug.g_log_statement) THEN
2796: gme_debug.put_line('Transaction header ID for reservation is '||gme_common_pvt.g_transaction_header_id);
2797: END IF;
2798:
2799: l_in_subinventory := l_subinventory;

Line 2796: gme_debug.put_line('Transaction header ID for reservation is '||gme_common_pvt.g_transaction_header_id);

2792:
2793: l_mmti_rec.transaction_date := l_date;
2794: SELECT mtl_material_transactions_s.NEXTVAL INTO gme_common_pvt.g_transaction_header_id FROM DUAL;
2795: IF (g_debug <= gme_debug.g_log_statement) THEN
2796: gme_debug.put_line('Transaction header ID for reservation is '||gme_common_pvt.g_transaction_header_id);
2797: END IF;
2798:
2799: l_in_subinventory := l_subinventory;
2800: create_issue_receipt(p_curr_org_id => l_org_id,

Line 2825: IF (g_debug <= gme_debug.g_log_statement) THEN

2821: l_msg_name := 'GME_MIG_INV_TRANSFER_FAIL';
2822: RAISE create_txn_rsv_pp_err;
2823: END IF;
2824: ELSE
2825: IF (g_debug <= gme_debug.g_log_statement) THEN
2826: gme_debug.put_line('No transfer for this reservation needed');
2827: END IF;
2828:
2829: IF (l_subinventory IS NOT NULL) THEN

Line 2826: gme_debug.put_line('No transfer for this reservation needed');

2822: RAISE create_txn_rsv_pp_err;
2823: END IF;
2824: ELSE
2825: IF (g_debug <= gme_debug.g_log_statement) THEN
2826: gme_debug.put_line('No transfer for this reservation needed');
2827: END IF;
2828:
2829: IF (l_subinventory IS NOT NULL) THEN
2830: IF NOT (gme_common_pvt.check_subinventory(p_organization_id => l_mtl_rec.organization_id

Line 2896: IF (g_debug <= gme_debug.g_log_statement) THEN

2892: l_msg_name := 'GME_MIG_ITEM_LOT_ENABLED';
2893: RAISE defined_error;
2894: END IF;
2895: END IF;
2896: IF (g_debug <= gme_debug.g_log_statement) THEN
2897: gme_debug.put_line('Lot control is for this reservation = '||l_mtl_rec.lot_control_code);
2898: END IF;
2899:
2900: IF (l_mtl_rec.lot_control_code = 2) THEN

Line 2897: gme_debug.put_line('Lot control is for this reservation = '||l_mtl_rec.lot_control_code);

2893: RAISE defined_error;
2894: END IF;
2895: END IF;
2896: IF (g_debug <= gme_debug.g_log_statement) THEN
2897: gme_debug.put_line('Lot control is for this reservation = '||l_mtl_rec.lot_control_code);
2898: END IF;
2899:
2900: IF (l_mtl_rec.lot_control_code = 2) THEN
2901: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 2901: IF (g_debug <= gme_debug.g_log_statement) THEN

2897: gme_debug.put_line('Lot control is for this reservation = '||l_mtl_rec.lot_control_code);
2898: END IF;
2899:
2900: IF (l_mtl_rec.lot_control_code = 2) THEN
2901: IF (g_debug <= gme_debug.g_log_statement) THEN
2902: gme_debug.put_line('CALL 2 to get_odm_lot. values passed in are:');
2903: gme_debug.put_line('loop i iteration is '||i);
2904: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2905: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);

Line 2902: gme_debug.put_line('CALL 2 to get_odm_lot. values passed in are:');

2898: END IF;
2899:
2900: IF (l_mtl_rec.lot_control_code = 2) THEN
2901: IF (g_debug <= gme_debug.g_log_statement) THEN
2902: gme_debug.put_line('CALL 2 to get_odm_lot. values passed in are:');
2903: gme_debug.put_line('loop i iteration is '||i);
2904: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2905: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2906: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);

Line 2903: gme_debug.put_line('loop i iteration is '||i);

2899:
2900: IF (l_mtl_rec.lot_control_code = 2) THEN
2901: IF (g_debug <= gme_debug.g_log_statement) THEN
2902: gme_debug.put_line('CALL 2 to get_odm_lot. values passed in are:');
2903: gme_debug.put_line('loop i iteration is '||i);
2904: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2905: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2906: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2907: gme_debug.put_line('p_orgn_code NULL');

Line 2904: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);

2900: IF (l_mtl_rec.lot_control_code = 2) THEN
2901: IF (g_debug <= gme_debug.g_log_statement) THEN
2902: gme_debug.put_line('CALL 2 to get_odm_lot. values passed in are:');
2903: gme_debug.put_line('loop i iteration is '||i);
2904: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2905: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2906: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2907: gme_debug.put_line('p_orgn_code NULL');
2908: gme_debug.put_line('p_location '||l_txns_tbl(i).location);

Line 2905: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);

2901: IF (g_debug <= gme_debug.g_log_statement) THEN
2902: gme_debug.put_line('CALL 2 to get_odm_lot. values passed in are:');
2903: gme_debug.put_line('loop i iteration is '||i);
2904: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2905: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2906: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2907: gme_debug.put_line('p_orgn_code NULL');
2908: gme_debug.put_line('p_location '||l_txns_tbl(i).location);
2909: END IF;

Line 2906: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);

2902: gme_debug.put_line('CALL 2 to get_odm_lot. values passed in are:');
2903: gme_debug.put_line('loop i iteration is '||i);
2904: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2905: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2906: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2907: gme_debug.put_line('p_orgn_code NULL');
2908: gme_debug.put_line('p_location '||l_txns_tbl(i).location);
2909: END IF;
2910:

Line 2907: gme_debug.put_line('p_orgn_code NULL');

2903: gme_debug.put_line('loop i iteration is '||i);
2904: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2905: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2906: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2907: gme_debug.put_line('p_orgn_code NULL');
2908: gme_debug.put_line('p_location '||l_txns_tbl(i).location);
2909: END IF;
2910:
2911: inv_opm_lot_migration.get_odm_lot(p_migration_run_id => g_migration_run_id,

Line 2908: gme_debug.put_line('p_location '||l_txns_tbl(i).location);

2904: gme_debug.put_line('p_item_id '||l_txns_tbl(i).item_id);
2905: gme_debug.put_line('p_lot_id '||l_txns_tbl(i).lot_id);
2906: gme_debug.put_line('p_whse_code '||l_txns_tbl(i).whse_code);
2907: gme_debug.put_line('p_orgn_code NULL');
2908: gme_debug.put_line('p_location '||l_txns_tbl(i).location);
2909: END IF;
2910:
2911: inv_opm_lot_migration.get_odm_lot(p_migration_run_id => g_migration_run_id,
2912: p_item_id => l_txns_tbl(i).item_id,

Line 2922: IF (g_debug <= gme_debug.g_log_statement) THEN

2918: x_lot_number => l_lot_number,
2919: x_parent_lot_number => l_parent_lot_no,
2920: x_failure_count => l_failure_count);
2921:
2922: IF (g_debug <= gme_debug.g_log_statement) THEN
2923: gme_debug.put_line('RETURN from get_odm_lot.');
2924: gme_debug.put_line('l_failure_count is '||l_failure_count);
2925: gme_debug.put_line('l_lot_number '||l_lot_number);
2926: END IF;

Line 2923: gme_debug.put_line('RETURN from get_odm_lot.');

2919: x_parent_lot_number => l_parent_lot_no,
2920: x_failure_count => l_failure_count);
2921:
2922: IF (g_debug <= gme_debug.g_log_statement) THEN
2923: gme_debug.put_line('RETURN from get_odm_lot.');
2924: gme_debug.put_line('l_failure_count is '||l_failure_count);
2925: gme_debug.put_line('l_lot_number '||l_lot_number);
2926: END IF;
2927:

Line 2924: gme_debug.put_line('l_failure_count is '||l_failure_count);

2920: x_failure_count => l_failure_count);
2921:
2922: IF (g_debug <= gme_debug.g_log_statement) THEN
2923: gme_debug.put_line('RETURN from get_odm_lot.');
2924: gme_debug.put_line('l_failure_count is '||l_failure_count);
2925: gme_debug.put_line('l_lot_number '||l_lot_number);
2926: END IF;
2927:
2928: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN

Line 2925: gme_debug.put_line('l_lot_number '||l_lot_number);

2921:
2922: IF (g_debug <= gme_debug.g_log_statement) THEN
2923: gme_debug.put_line('RETURN from get_odm_lot.');
2924: gme_debug.put_line('l_failure_count is '||l_failure_count);
2925: gme_debug.put_line('l_lot_number '||l_lot_number);
2926: END IF;
2927:
2928: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
2929: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';

Line 2930: IF (g_debug <= gme_debug.g_log_statement) THEN

2926: END IF;
2927:
2928: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
2929: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';
2930: IF (g_debug <= gme_debug.g_log_statement) THEN
2931: gme_debug.put_line('ERROR is raised here');
2932: END IF;
2933: RAISE defined_error;
2934: END IF;

Line 2931: gme_debug.put_line('ERROR is raised here');

2927:
2928: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
2929: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';
2930: IF (g_debug <= gme_debug.g_log_statement) THEN
2931: gme_debug.put_line('ERROR is raised here');
2932: END IF;
2933: RAISE defined_error;
2934: END IF;
2935: END IF;

Line 2937: IF (g_debug <= gme_debug.g_log_statement) THEN

2933: RAISE defined_error;
2934: END IF;
2935: END IF;
2936: END IF;
2937: IF (g_debug <= gme_debug.g_log_statement) THEN
2938: gme_debug.put_line('Lot is '||l_lot_number);
2939: END IF;
2940:
2941: l_mtl_dtl_rec.revision := l_mmti_rec.revision;

Line 2938: gme_debug.put_line('Lot is '||l_lot_number);

2934: END IF;
2935: END IF;
2936: END IF;
2937: IF (g_debug <= gme_debug.g_log_statement) THEN
2938: gme_debug.put_line('Lot is '||l_lot_number);
2939: END IF;
2940:
2941: l_mtl_dtl_rec.revision := l_mmti_rec.revision;
2942:

Line 2948: IF (g_debug <= gme_debug.g_log_statement) THEN

2944: 'rev '||l_mmti_rec.revision||'->'||'subinventory '||l_subinventory||'->'||
2945: 'locator id '||l_locator_id||'->'||'lot_number '||l_lot_number||'->'||
2946: 'trans qty '||ABS(l_txns_tbl(i).trans_qty)||'->'||'primary uom '||l_mtl_rec.primary_uom_code;
2947:
2948: IF (g_debug <= gme_debug.g_log_statement) THEN
2949: gme_debug.put_line('Creating reservation with '||l_new_data);
2950: END IF;
2951: gme_reservations_pvt.create_material_reservation(p_matl_dtl_rec => l_mtl_dtl_rec,
2952: p_resv_qty => ABS(l_txns_tbl(i).trans_qty),

Line 2949: gme_debug.put_line('Creating reservation with '||l_new_data);

2945: 'locator id '||l_locator_id||'->'||'lot_number '||l_lot_number||'->'||
2946: 'trans qty '||ABS(l_txns_tbl(i).trans_qty)||'->'||'primary uom '||l_mtl_rec.primary_uom_code;
2947:
2948: IF (g_debug <= gme_debug.g_log_statement) THEN
2949: gme_debug.put_line('Creating reservation with '||l_new_data);
2950: END IF;
2951: gme_reservations_pvt.create_material_reservation(p_matl_dtl_rec => l_mtl_dtl_rec,
2952: p_resv_qty => ABS(l_txns_tbl(i).trans_qty),
2953: p_sec_resv_qty => ABS(l_txns_tbl(i).trans_qty2),

Line 2965: IF (g_debug <= gme_debug.g_log_statement) THEN

2961: RAISE create_txn_rsv_pp_err;
2962: END IF;
2963: END IF;
2964: ELSE /* products and byproducts create pending product lots */
2965: IF (g_debug <= gme_debug.g_log_statement) THEN
2966: gme_debug.put_line('Creating pending product lot');
2967: END IF;
2968: l_mtl_dtl_rec.material_requirement_date := l_mtl_rec.material_requirement_date;
2969: l_mtl_dtl_rec.organization_id := l_mtl_rec.organization_id;

Line 2966: gme_debug.put_line('Creating pending product lot');

2962: END IF;
2963: END IF;
2964: ELSE /* products and byproducts create pending product lots */
2965: IF (g_debug <= gme_debug.g_log_statement) THEN
2966: gme_debug.put_line('Creating pending product lot');
2967: END IF;
2968: l_mtl_dtl_rec.material_requirement_date := l_mtl_rec.material_requirement_date;
2969: l_mtl_dtl_rec.organization_id := l_mtl_rec.organization_id;
2970: l_mtl_dtl_rec.inventory_item_id := l_mtl_rec.inventory_item_id;

Line 2997: IF (g_debug <= gme_debug.g_log_statement) THEN

2993: OPEN Cur_lot_mst(l_txns_tbl(i).lot_id);
2994: FETCH Cur_lot_mst INTO l_lot_no, l_sublot_no;
2995: CLOSE Cur_lot_mst;
2996:
2997: IF (g_debug <= gme_debug.g_log_statement) THEN
2998: gme_debug.put_line('CALL 3 to get_odm_lot. values passed in are:');
2999: gme_debug.put_line('p_inventory_item_id '||l_mtl_dtl_rec.inventory_item_id);
3000: gme_debug.put_line('p_lot_no '||l_lot_no);
3001: gme_debug.put_line('p_sublot_no '||l_sublot_no);

Line 2998: gme_debug.put_line('CALL 3 to get_odm_lot. values passed in are:');

2994: FETCH Cur_lot_mst INTO l_lot_no, l_sublot_no;
2995: CLOSE Cur_lot_mst;
2996:
2997: IF (g_debug <= gme_debug.g_log_statement) THEN
2998: gme_debug.put_line('CALL 3 to get_odm_lot. values passed in are:');
2999: gme_debug.put_line('p_inventory_item_id '||l_mtl_dtl_rec.inventory_item_id);
3000: gme_debug.put_line('p_lot_no '||l_lot_no);
3001: gme_debug.put_line('p_sublot_no '||l_sublot_no);
3002: gme_debug.put_line('p_organization_id '||l_mtl_dtl_rec.organization_id);

Line 2999: gme_debug.put_line('p_inventory_item_id '||l_mtl_dtl_rec.inventory_item_id);

2995: CLOSE Cur_lot_mst;
2996:
2997: IF (g_debug <= gme_debug.g_log_statement) THEN
2998: gme_debug.put_line('CALL 3 to get_odm_lot. values passed in are:');
2999: gme_debug.put_line('p_inventory_item_id '||l_mtl_dtl_rec.inventory_item_id);
3000: gme_debug.put_line('p_lot_no '||l_lot_no);
3001: gme_debug.put_line('p_sublot_no '||l_sublot_no);
3002: gme_debug.put_line('p_organization_id '||l_mtl_dtl_rec.organization_id);
3003: gme_debug.put_line('p_locator_id NULL');

Line 3000: gme_debug.put_line('p_lot_no '||l_lot_no);

2996:
2997: IF (g_debug <= gme_debug.g_log_statement) THEN
2998: gme_debug.put_line('CALL 3 to get_odm_lot. values passed in are:');
2999: gme_debug.put_line('p_inventory_item_id '||l_mtl_dtl_rec.inventory_item_id);
3000: gme_debug.put_line('p_lot_no '||l_lot_no);
3001: gme_debug.put_line('p_sublot_no '||l_sublot_no);
3002: gme_debug.put_line('p_organization_id '||l_mtl_dtl_rec.organization_id);
3003: gme_debug.put_line('p_locator_id NULL');
3004: END IF;

Line 3001: gme_debug.put_line('p_sublot_no '||l_sublot_no);

2997: IF (g_debug <= gme_debug.g_log_statement) THEN
2998: gme_debug.put_line('CALL 3 to get_odm_lot. values passed in are:');
2999: gme_debug.put_line('p_inventory_item_id '||l_mtl_dtl_rec.inventory_item_id);
3000: gme_debug.put_line('p_lot_no '||l_lot_no);
3001: gme_debug.put_line('p_sublot_no '||l_sublot_no);
3002: gme_debug.put_line('p_organization_id '||l_mtl_dtl_rec.organization_id);
3003: gme_debug.put_line('p_locator_id NULL');
3004: END IF;
3005:

Line 3002: gme_debug.put_line('p_organization_id '||l_mtl_dtl_rec.organization_id);

2998: gme_debug.put_line('CALL 3 to get_odm_lot. values passed in are:');
2999: gme_debug.put_line('p_inventory_item_id '||l_mtl_dtl_rec.inventory_item_id);
3000: gme_debug.put_line('p_lot_no '||l_lot_no);
3001: gme_debug.put_line('p_sublot_no '||l_sublot_no);
3002: gme_debug.put_line('p_organization_id '||l_mtl_dtl_rec.organization_id);
3003: gme_debug.put_line('p_locator_id NULL');
3004: END IF;
3005:
3006: inv_opm_lot_migration.get_odm_lot(p_migration_run_id => g_migration_run_id,

Line 3003: gme_debug.put_line('p_locator_id NULL');

2999: gme_debug.put_line('p_inventory_item_id '||l_mtl_dtl_rec.inventory_item_id);
3000: gme_debug.put_line('p_lot_no '||l_lot_no);
3001: gme_debug.put_line('p_sublot_no '||l_sublot_no);
3002: gme_debug.put_line('p_organization_id '||l_mtl_dtl_rec.organization_id);
3003: gme_debug.put_line('p_locator_id NULL');
3004: END IF;
3005:
3006: inv_opm_lot_migration.get_odm_lot(p_migration_run_id => g_migration_run_id,
3007: p_inventory_item_id => l_mtl_dtl_rec.inventory_item_id,

Line 3017: IF (g_debug <= gme_debug.g_log_statement) THEN

3013: x_lot_number => l_lot_number,
3014: x_parent_lot_number => l_parent_lot_no,
3015: x_failure_count => l_failure_count);
3016:
3017: IF (g_debug <= gme_debug.g_log_statement) THEN
3018: gme_debug.put_line('RETURN from get_odm_lot.');
3019: gme_debug.put_line('l_failure_count is '||l_failure_count);
3020: gme_debug.put_line('l_lot_number '||l_lot_number);
3021: END IF;

Line 3018: gme_debug.put_line('RETURN from get_odm_lot.');

3014: x_parent_lot_number => l_parent_lot_no,
3015: x_failure_count => l_failure_count);
3016:
3017: IF (g_debug <= gme_debug.g_log_statement) THEN
3018: gme_debug.put_line('RETURN from get_odm_lot.');
3019: gme_debug.put_line('l_failure_count is '||l_failure_count);
3020: gme_debug.put_line('l_lot_number '||l_lot_number);
3021: END IF;
3022:

Line 3019: gme_debug.put_line('l_failure_count is '||l_failure_count);

3015: x_failure_count => l_failure_count);
3016:
3017: IF (g_debug <= gme_debug.g_log_statement) THEN
3018: gme_debug.put_line('RETURN from get_odm_lot.');
3019: gme_debug.put_line('l_failure_count is '||l_failure_count);
3020: gme_debug.put_line('l_lot_number '||l_lot_number);
3021: END IF;
3022:
3023: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN

Line 3020: gme_debug.put_line('l_lot_number '||l_lot_number);

3016:
3017: IF (g_debug <= gme_debug.g_log_statement) THEN
3018: gme_debug.put_line('RETURN from get_odm_lot.');
3019: gme_debug.put_line('l_failure_count is '||l_failure_count);
3020: gme_debug.put_line('l_lot_number '||l_lot_number);
3021: END IF;
3022:
3023: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
3024: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';

Line 3025: IF (g_debug <= gme_debug.g_log_statement) THEN

3021: END IF;
3022:
3023: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
3024: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';
3025: IF (g_debug <= gme_debug.g_log_statement) THEN
3026: gme_debug.put_line('ERROR is raised here');
3027: END IF;
3028: RAISE defined_error;
3029: END IF;

Line 3026: gme_debug.put_line('ERROR is raised here');

3022:
3023: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
3024: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';
3025: IF (g_debug <= gme_debug.g_log_statement) THEN
3026: gme_debug.put_line('ERROR is raised here');
3027: END IF;
3028: RAISE defined_error;
3029: END IF;
3030:

Line 3057: IF (g_debug <= gme_debug.g_log_statement) THEN

3053: l_new_data := 'PPL org '||gme_common_pvt.g_organization_code||'->'||'item no '||l_mtl_rec.item_no||'->'||
3054: 'rev '||l_plot_in_rec.revision||'->'||'lot_number '||l_plot_in_rec.lot_number||'->'||
3055: 'trans qty '||l_plot_in_rec.quantity||'->'||'matl uom '||l_mtl_dtl_rec.dtl_um;
3056:
3057: IF (g_debug <= gme_debug.g_log_statement) THEN
3058: gme_debug.put_line('Creating pending product lot with '||l_new_data);
3059: END IF;
3060:
3061: gme_api_pub.create_pending_product_lot(p_api_version => 2.0,

Line 3058: gme_debug.put_line('Creating pending product lot with '||l_new_data);

3054: 'rev '||l_plot_in_rec.revision||'->'||'lot_number '||l_plot_in_rec.lot_number||'->'||
3055: 'trans qty '||l_plot_in_rec.quantity||'->'||'matl uom '||l_mtl_dtl_rec.dtl_um;
3056:
3057: IF (g_debug <= gme_debug.g_log_statement) THEN
3058: gme_debug.put_line('Creating pending product lot with '||l_new_data);
3059: END IF;
3060:
3061: gme_api_pub.create_pending_product_lot(p_api_version => 2.0,
3062: p_validation_level => gme_common_pvt.g_max_errors,

Line 3092: IF (g_debug <= gme_debug.g_log_statement) THEN

3088: SET migrated_ind = 1
3089: WHERE trans_id = l_txns_tbl(i).trans_id
3090: AND batch_id = l_txns_tbl(i).doc_id; -- This is the 11i batch id.
3091:
3092: IF (g_debug <= gme_debug.g_log_statement) THEN
3093: gme_debug.put_line('Done transaction');
3094: END IF;
3095: COMMIT;
3096: EXCEPTION

Line 3093: gme_debug.put_line('Done transaction');

3089: WHERE trans_id = l_txns_tbl(i).trans_id
3090: AND batch_id = l_txns_tbl(i).doc_id; -- This is the 11i batch id.
3091:
3092: IF (g_debug <= gme_debug.g_log_statement) THEN
3093: gme_debug.put_line('Done transaction');
3094: END IF;
3095: COMMIT;
3096: EXCEPTION
3097: WHEN setup_failed OR batch_fetch_err THEN

Line 3213: IF (g_debug <= gme_debug.g_log_unexpected) THEN

3209: p_token5 => 'NEW_DATA',
3210: p_param5 => l_new_data);
3211: ROLLBACK;
3212: WHEN OTHERS THEN
3213: IF (g_debug <= gme_debug.g_log_unexpected) THEN
3214: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
3215: END IF;
3216:
3217: l_txn_data := 'item no '||l_mtl_rec.item_no||'->'||'whse code '||l_txns_tbl(i).whse_code||'->'||

Line 3214: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

3210: p_param5 => l_new_data);
3211: ROLLBACK;
3212: WHEN OTHERS THEN
3213: IF (g_debug <= gme_debug.g_log_unexpected) THEN
3214: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
3215: END IF;
3216:
3217: l_txn_data := 'item no '||l_mtl_rec.item_no||'->'||'whse code '||l_txns_tbl(i).whse_code||'->'||
3218: 'location '||l_txns_tbl(i).location||'->'||'lot id '||l_txns_tbl(i).lot_id||'->'||

Line 3241: IF (g_debug <= gme_debug.g_log_procedure) THEN

3237: p_param4 => l_txn_data);
3238: ROLLBACK;
3239: END;
3240: END LOOP;
3241: IF (g_debug <= gme_debug.g_log_procedure) THEN
3242: gme_debug.put_line('End procedure '||l_api_name);
3243: END IF;
3244: END create_txns_reservations;
3245:

Line 3242: gme_debug.put_line('End procedure '||l_api_name);

3238: ROLLBACK;
3239: END;
3240: END LOOP;
3241: IF (g_debug <= gme_debug.g_log_procedure) THEN
3242: gme_debug.put_line('End procedure '||l_api_name);
3243: END IF;
3244: END create_txns_reservations;
3245:
3246: PROCEDURE create_issue_receipt(p_curr_org_id IN NUMBER,

Line 3317: IF (g_debug <= gme_debug.g_log_procedure) THEN

3313: expected_error EXCEPTION;
3314: item_not_defined EXCEPTION;
3315: no_open_period_err EXCEPTION;
3316: BEGIN
3317: IF (g_debug <= gme_debug.g_log_procedure) THEN
3318: gme_debug.put_line('Start procedure '||l_api_name);
3319: END IF;
3320: IF (g_debug <= gme_debug.g_log_statement) THEN
3321: gme_debug.put_line('Moving from org = '||p_curr_org_id||' to org = '||p_batch_org_id);

Line 3318: gme_debug.put_line('Start procedure '||l_api_name);

3314: item_not_defined EXCEPTION;
3315: no_open_period_err EXCEPTION;
3316: BEGIN
3317: IF (g_debug <= gme_debug.g_log_procedure) THEN
3318: gme_debug.put_line('Start procedure '||l_api_name);
3319: END IF;
3320: IF (g_debug <= gme_debug.g_log_statement) THEN
3321: gme_debug.put_line('Moving from org = '||p_curr_org_id||' to org = '||p_batch_org_id);
3322: END IF;

Line 3320: IF (g_debug <= gme_debug.g_log_statement) THEN

3316: BEGIN
3317: IF (g_debug <= gme_debug.g_log_procedure) THEN
3318: gme_debug.put_line('Start procedure '||l_api_name);
3319: END IF;
3320: IF (g_debug <= gme_debug.g_log_statement) THEN
3321: gme_debug.put_line('Moving from org = '||p_curr_org_id||' to org = '||p_batch_org_id);
3322: END IF;
3323:
3324: x_return_status := FND_API.G_RET_STS_SUCCESS;

Line 3321: gme_debug.put_line('Moving from org = '||p_curr_org_id||' to org = '||p_batch_org_id);

3317: IF (g_debug <= gme_debug.g_log_procedure) THEN
3318: gme_debug.put_line('Start procedure '||l_api_name);
3319: END IF;
3320: IF (g_debug <= gme_debug.g_log_statement) THEN
3321: gme_debug.put_line('Moving from org = '||p_curr_org_id||' to org = '||p_batch_org_id);
3322: END IF;
3323:
3324: x_return_status := FND_API.G_RET_STS_SUCCESS;
3325: OPEN Cur_get_org_params(p_curr_org_id);

Line 3334: IF (g_debug <= gme_debug.g_log_statement) THEN

3330: 'location '||p_txn_rec.location||'->'||'lot id '||p_txn_rec.lot_id||'->'||
3331: 'trans qty '||p_txn_rec.trans_qty||'->'||'trans um '||p_txn_rec.trans_um||'->'||
3332: 'trans date '||to_char(p_txn_rec.trans_date, 'DD-MON-YYYY HH24:MI:SS');
3333:
3334: IF (g_debug <= gme_debug.g_log_statement) THEN
3335: gme_debug.put_line('TXN Data = '||l_txn_data);
3336: END IF;
3337:
3338: gma_common_logging.gma_migration_central_log

Line 3335: gme_debug.put_line('TXN Data = '||l_txn_data);

3331: 'trans qty '||p_txn_rec.trans_qty||'->'||'trans um '||p_txn_rec.trans_um||'->'||
3332: 'trans date '||to_char(p_txn_rec.trans_date, 'DD-MON-YYYY HH24:MI:SS');
3333:
3334: IF (g_debug <= gme_debug.g_log_statement) THEN
3335: gme_debug.put_line('TXN Data = '||l_txn_data);
3336: END IF;
3337:
3338: gma_common_logging.gma_migration_central_log
3339: (p_run_id => g_migration_run_id,

Line 3379: IF (g_debug <= gme_debug.g_log_statement) THEN

3375: RAISE defined_error;
3376: END IF;
3377: END IF;
3378:
3379: IF (g_debug <= gme_debug.g_log_statement) THEN
3380: gme_debug.put_line('Before subinventory');
3381: END IF;
3382:
3383: /* Validate if sub found is valid in this org */

Line 3380: gme_debug.put_line('Before subinventory');

3376: END IF;
3377: END IF;
3378:
3379: IF (g_debug <= gme_debug.g_log_statement) THEN
3380: gme_debug.put_line('Before subinventory');
3381: END IF;
3382:
3383: /* Validate if sub found is valid in this org */
3384: IF NOT (gme_common_pvt.check_subinventory(p_organization_id => p_curr_org_id

Line 3438: IF (g_debug <= gme_debug.g_log_statement) THEN

3434: END IF;
3435:
3436: IF (l_item_rec.lot_control_code = 2) THEN
3437:
3438: IF (g_debug <= gme_debug.g_log_statement) THEN
3439: gme_debug.put_line('CALL 4 to get_odm_lot. values passed in are:');
3440: gme_debug.put_line('p_item_id '||p_txn_rec.item_id);
3441: gme_debug.put_line('p_lot_id '||p_txn_rec.lot_id);
3442: gme_debug.put_line('p_whse_code '||p_txn_rec.whse_code);

Line 3439: gme_debug.put_line('CALL 4 to get_odm_lot. values passed in are:');

3435:
3436: IF (l_item_rec.lot_control_code = 2) THEN
3437:
3438: IF (g_debug <= gme_debug.g_log_statement) THEN
3439: gme_debug.put_line('CALL 4 to get_odm_lot. values passed in are:');
3440: gme_debug.put_line('p_item_id '||p_txn_rec.item_id);
3441: gme_debug.put_line('p_lot_id '||p_txn_rec.lot_id);
3442: gme_debug.put_line('p_whse_code '||p_txn_rec.whse_code);
3443: gme_debug.put_line('p_orgn_code NULL');

Line 3440: gme_debug.put_line('p_item_id '||p_txn_rec.item_id);

3436: IF (l_item_rec.lot_control_code = 2) THEN
3437:
3438: IF (g_debug <= gme_debug.g_log_statement) THEN
3439: gme_debug.put_line('CALL 4 to get_odm_lot. values passed in are:');
3440: gme_debug.put_line('p_item_id '||p_txn_rec.item_id);
3441: gme_debug.put_line('p_lot_id '||p_txn_rec.lot_id);
3442: gme_debug.put_line('p_whse_code '||p_txn_rec.whse_code);
3443: gme_debug.put_line('p_orgn_code NULL');
3444: gme_debug.put_line('p_location '||p_txn_rec.location);

Line 3441: gme_debug.put_line('p_lot_id '||p_txn_rec.lot_id);

3437:
3438: IF (g_debug <= gme_debug.g_log_statement) THEN
3439: gme_debug.put_line('CALL 4 to get_odm_lot. values passed in are:');
3440: gme_debug.put_line('p_item_id '||p_txn_rec.item_id);
3441: gme_debug.put_line('p_lot_id '||p_txn_rec.lot_id);
3442: gme_debug.put_line('p_whse_code '||p_txn_rec.whse_code);
3443: gme_debug.put_line('p_orgn_code NULL');
3444: gme_debug.put_line('p_location '||p_txn_rec.location);
3445: END IF;

Line 3442: gme_debug.put_line('p_whse_code '||p_txn_rec.whse_code);

3438: IF (g_debug <= gme_debug.g_log_statement) THEN
3439: gme_debug.put_line('CALL 4 to get_odm_lot. values passed in are:');
3440: gme_debug.put_line('p_item_id '||p_txn_rec.item_id);
3441: gme_debug.put_line('p_lot_id '||p_txn_rec.lot_id);
3442: gme_debug.put_line('p_whse_code '||p_txn_rec.whse_code);
3443: gme_debug.put_line('p_orgn_code NULL');
3444: gme_debug.put_line('p_location '||p_txn_rec.location);
3445: END IF;
3446:

Line 3443: gme_debug.put_line('p_orgn_code NULL');

3439: gme_debug.put_line('CALL 4 to get_odm_lot. values passed in are:');
3440: gme_debug.put_line('p_item_id '||p_txn_rec.item_id);
3441: gme_debug.put_line('p_lot_id '||p_txn_rec.lot_id);
3442: gme_debug.put_line('p_whse_code '||p_txn_rec.whse_code);
3443: gme_debug.put_line('p_orgn_code NULL');
3444: gme_debug.put_line('p_location '||p_txn_rec.location);
3445: END IF;
3446:
3447: inv_opm_lot_migration.get_odm_lot(p_migration_run_id => g_migration_run_id,

Line 3444: gme_debug.put_line('p_location '||p_txn_rec.location);

3440: gme_debug.put_line('p_item_id '||p_txn_rec.item_id);
3441: gme_debug.put_line('p_lot_id '||p_txn_rec.lot_id);
3442: gme_debug.put_line('p_whse_code '||p_txn_rec.whse_code);
3443: gme_debug.put_line('p_orgn_code NULL');
3444: gme_debug.put_line('p_location '||p_txn_rec.location);
3445: END IF;
3446:
3447: inv_opm_lot_migration.get_odm_lot(p_migration_run_id => g_migration_run_id,
3448: p_item_id => p_txn_rec.item_id,

Line 3458: IF (g_debug <= gme_debug.g_log_statement) THEN

3454: x_lot_number => l_lot_number,
3455: x_parent_lot_number => l_parent_lot_no,
3456: x_failure_count => l_failure_count);
3457:
3458: IF (g_debug <= gme_debug.g_log_statement) THEN
3459: gme_debug.put_line('RETURN from get_odm_lot.');
3460: gme_debug.put_line('l_failure_count is '||l_failure_count);
3461: gme_debug.put_line('l_lot_number '||l_lot_number);
3462: END IF;

Line 3459: gme_debug.put_line('RETURN from get_odm_lot.');

3455: x_parent_lot_number => l_parent_lot_no,
3456: x_failure_count => l_failure_count);
3457:
3458: IF (g_debug <= gme_debug.g_log_statement) THEN
3459: gme_debug.put_line('RETURN from get_odm_lot.');
3460: gme_debug.put_line('l_failure_count is '||l_failure_count);
3461: gme_debug.put_line('l_lot_number '||l_lot_number);
3462: END IF;
3463:

Line 3460: gme_debug.put_line('l_failure_count is '||l_failure_count);

3456: x_failure_count => l_failure_count);
3457:
3458: IF (g_debug <= gme_debug.g_log_statement) THEN
3459: gme_debug.put_line('RETURN from get_odm_lot.');
3460: gme_debug.put_line('l_failure_count is '||l_failure_count);
3461: gme_debug.put_line('l_lot_number '||l_lot_number);
3462: END IF;
3463:
3464: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN

Line 3461: gme_debug.put_line('l_lot_number '||l_lot_number);

3457:
3458: IF (g_debug <= gme_debug.g_log_statement) THEN
3459: gme_debug.put_line('RETURN from get_odm_lot.');
3460: gme_debug.put_line('l_failure_count is '||l_failure_count);
3461: gme_debug.put_line('l_lot_number '||l_lot_number);
3462: END IF;
3463:
3464: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
3465: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';

Line 3466: IF (g_debug <= gme_debug.g_log_statement) THEN

3462: END IF;
3463:
3464: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
3465: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';
3466: IF (g_debug <= gme_debug.g_log_statement) THEN
3467: gme_debug.put_line('ERROR is raised here');
3468: END IF;
3469:
3470: RAISE defined_error;

Line 3467: gme_debug.put_line('ERROR is raised here');

3463:
3464: IF (l_failure_count > 0 OR l_lot_number IS NULL) THEN
3465: l_msg_name := 'GME_MIG_LOT_NOT_FOUND';
3466: IF (g_debug <= gme_debug.g_log_statement) THEN
3467: gme_debug.put_line('ERROR is raised here');
3468: END IF;
3469:
3470: RAISE defined_error;
3471: END IF;

Line 3535: IF (g_debug <= gme_debug.g_log_statement) THEN

3531: l_issue_lot_rec.transaction_quantity := -1 * ABS(p_mmti_rec.primary_quantity);
3532: l_issue_lot_rec.secondary_transaction_quantity := -1 * ABS(p_mmti_rec.secondary_transaction_quantity);
3533: END IF;
3534:
3535: IF (g_debug <= gme_debug.g_log_statement) THEN
3536: gme_debug.put_line('Issue record '||l_issue_rec.organization_id||'->'||p_item_no||'->'||l_issue_rec.subinventory_code||'->'||
3537: l_issue_rec.locator_id||'->'||l_lot_number||'->'||l_issue_rec.transaction_quantity||'->'||l_issue_rec.transaction_uom||'->'||to_char(l_issue_rec.transaction_date, 'DD-MON-YYYY HH24:MI:SS'));
3538: END IF;
3539:

Line 3536: gme_debug.put_line('Issue record '||l_issue_rec.organization_id||'->'||p_item_no||'->'||l_issue_rec.subinventory_code||'->'||

3532: l_issue_lot_rec.secondary_transaction_quantity := -1 * ABS(p_mmti_rec.secondary_transaction_quantity);
3533: END IF;
3534:
3535: IF (g_debug <= gme_debug.g_log_statement) THEN
3536: gme_debug.put_line('Issue record '||l_issue_rec.organization_id||'->'||p_item_no||'->'||l_issue_rec.subinventory_code||'->'||
3537: l_issue_rec.locator_id||'->'||l_lot_number||'->'||l_issue_rec.transaction_quantity||'->'||l_issue_rec.transaction_uom||'->'||to_char(l_issue_rec.transaction_date, 'DD-MON-YYYY HH24:MI:SS'));
3538: END IF;
3539:
3540: insert_interface_recs(p_mti_rec => l_issue_rec,

Line 3650: IF (g_debug <= gme_debug.g_log_statement) THEN

3646: CLOSE Cur_new_loc;
3647: END IF;
3648: END IF;
3649:
3650: IF (g_debug <= gme_debug.g_log_statement) THEN
3651: gme_debug.put_line('create_issue_receipt l_item_rec.lot_control_code '||l_item_rec.lot_control_code );
3652: END IF;
3653:
3654: IF (l_item_rec.lot_control_code = 2) THEN

Line 3651: gme_debug.put_line('create_issue_receipt l_item_rec.lot_control_code '||l_item_rec.lot_control_code );

3647: END IF;
3648: END IF;
3649:
3650: IF (g_debug <= gme_debug.g_log_statement) THEN
3651: gme_debug.put_line('create_issue_receipt l_item_rec.lot_control_code '||l_item_rec.lot_control_code );
3652: END IF;
3653:
3654: IF (l_item_rec.lot_control_code = 2) THEN
3655: l_receipt_lot_rec.transaction_interface_id := l_receipt_rec.transaction_interface_id;

Line 3690: IF g_debug <= gme_debug.g_log_statement and l_exp_date IS NOT NULL THEN

3686: END IF;
3687: CLOSE cur_get_lot_dates;
3688: l_receipt_lot_rec.lot_expiration_date := l_exp_date;
3689:
3690: IF g_debug <= gme_debug.g_log_statement and l_exp_date IS NOT NULL THEN
3691: gme_debug.put_line('Exp date for receipt will be: '||TO_CHAR(l_exp_date, 'DD-MON-YYYY HH24:MI:SS');
3692: ELSE
3693: gme_debug.put_line('l_exp_date IS NULL');
3694: END IF;

Line 3691: gme_debug.put_line('Exp date for receipt will be: '||TO_CHAR(l_exp_date, 'DD-MON-YYYY HH24:MI:SS');

3687: CLOSE cur_get_lot_dates;
3688: l_receipt_lot_rec.lot_expiration_date := l_exp_date;
3689:
3690: IF g_debug <= gme_debug.g_log_statement and l_exp_date IS NOT NULL THEN
3691: gme_debug.put_line('Exp date for receipt will be: '||TO_CHAR(l_exp_date, 'DD-MON-YYYY HH24:MI:SS');
3692: ELSE
3693: gme_debug.put_line('l_exp_date IS NULL');
3694: END IF;
3695: END IF;

Line 3693: gme_debug.put_line('l_exp_date IS NULL');

3689:
3690: IF g_debug <= gme_debug.g_log_statement and l_exp_date IS NOT NULL THEN
3691: gme_debug.put_line('Exp date for receipt will be: '||TO_CHAR(l_exp_date, 'DD-MON-YYYY HH24:MI:SS');
3692: ELSE
3693: gme_debug.put_line('l_exp_date IS NULL');
3694: END IF;
3695: END IF;
3696: */
3697: END IF;

Line 3699: IF (g_debug <= gme_debug.g_log_statement) THEN

3695: END IF;
3696: */
3697: END IF;
3698:
3699: IF (g_debug <= gme_debug.g_log_statement) THEN
3700: gme_debug.put_line('Receipt record '||l_receipt_rec.organization_id||'->'||p_item_no||'->'||l_receipt_rec.subinventory_code||'->'||
3701: l_receipt_rec.locator_id||'->'||l_lot_number||'->'||l_receipt_rec.transaction_quantity||'->'||l_receipt_rec.transaction_uom||'->'||to_char(l_receipt_rec.transaction_date, 'DD-MON-YYYY HH24:MI:SS'));
3702: END IF;
3703:

Line 3700: gme_debug.put_line('Receipt record '||l_receipt_rec.organization_id||'->'||p_item_no||'->'||l_receipt_rec.subinventory_code||'->'||

3696: */
3697: END IF;
3698:
3699: IF (g_debug <= gme_debug.g_log_statement) THEN
3700: gme_debug.put_line('Receipt record '||l_receipt_rec.organization_id||'->'||p_item_no||'->'||l_receipt_rec.subinventory_code||'->'||
3701: l_receipt_rec.locator_id||'->'||l_lot_number||'->'||l_receipt_rec.transaction_quantity||'->'||l_receipt_rec.transaction_uom||'->'||to_char(l_receipt_rec.transaction_date, 'DD-MON-YYYY HH24:MI:SS'));
3702: END IF;
3703:
3704: insert_interface_recs(p_mti_rec => l_receipt_rec,

Line 3715: IF (g_debug <= gme_debug.g_log_procedure) THEN

3711: x_subinventory := l_receipt_rec.subinventory_code;
3712: x_locator_id := l_receipt_rec.locator_id;
3713: x_lot_number := l_receipt_lot_rec.lot_number;
3714:
3715: IF (g_debug <= gme_debug.g_log_procedure) THEN
3716: gme_debug.put_line('End procedure '||l_api_name);
3717: END IF;
3718: EXCEPTION
3719: WHEN item_not_defined THEN

Line 3716: gme_debug.put_line('End procedure '||l_api_name);

3712: x_locator_id := l_receipt_rec.locator_id;
3713: x_lot_number := l_receipt_lot_rec.lot_number;
3714:
3715: IF (g_debug <= gme_debug.g_log_procedure) THEN
3716: gme_debug.put_line('End procedure '||l_api_name);
3717: END IF;
3718: EXCEPTION
3719: WHEN item_not_defined THEN
3720: gma_common_logging.gma_migration_central_log

Line 3800: IF (g_debug <= gme_debug.g_log_unexpected) THEN

3796: p_token3 => 'TXN_DATA',
3797: p_param3 => l_txn_data);
3798: x_return_status := FND_API.G_RET_STS_ERROR;
3799: WHEN OTHERS THEN
3800: IF (g_debug <= gme_debug.g_log_unexpected) THEN
3801: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
3802: END IF;
3803: l_txn_data := 'item no '||p_item_no||'->'||'whse code '||p_txn_rec.whse_code||'->'||
3804: 'location '||p_txn_rec.location||'->'||'lot id '||p_txn_rec.lot_id||'->'||

Line 3801: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

3797: p_param3 => l_txn_data);
3798: x_return_status := FND_API.G_RET_STS_ERROR;
3799: WHEN OTHERS THEN
3800: IF (g_debug <= gme_debug.g_log_unexpected) THEN
3801: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
3802: END IF;
3803: l_txn_data := 'item no '||p_item_no||'->'||'whse code '||p_txn_rec.whse_code||'->'||
3804: 'location '||p_txn_rec.location||'->'||'lot id '||p_txn_rec.lot_id||'->'||
3805: 'trans qty '||p_txn_rec.trans_qty||'->'||'trans um '||p_txn_rec.trans_um||'->'||

Line 3834: IF (g_debug <= gme_debug.g_log_procedure) THEN

3830: l_mti_tbl gme_common_pvt.mtl_tran_int_tbl;
3831: l_mtli_tbl gme_common_pvt.mtl_trans_lots_inter_tbl;
3832: l_api_name VARCHAR2(30) := 'insert_interface_recs';
3833: BEGIN
3834: IF (g_debug <= gme_debug.g_log_procedure) THEN
3835: gme_debug.put_line('Start procedure '||l_api_name);
3836: END IF;
3837: x_return_status := FND_API.G_RET_STS_SUCCESS;
3838: l_mti_tbl(1) := p_mti_rec;

Line 3835: gme_debug.put_line('Start procedure '||l_api_name);

3831: l_mtli_tbl gme_common_pvt.mtl_trans_lots_inter_tbl;
3832: l_api_name VARCHAR2(30) := 'insert_interface_recs';
3833: BEGIN
3834: IF (g_debug <= gme_debug.g_log_procedure) THEN
3835: gme_debug.put_line('Start procedure '||l_api_name);
3836: END IF;
3837: x_return_status := FND_API.G_RET_STS_SUCCESS;
3838: l_mti_tbl(1) := p_mti_rec;
3839: IF (p_mtli_rec.lot_number IS NOT NULL) THEN

Line 3846: IF (g_debug <= gme_debug.g_log_procedure) THEN

3842: FORALL a IN 1..l_mti_tbl.COUNT
3843: INSERT INTO mtl_transactions_interface VALUES l_mti_tbl(a);
3844: FORALL b IN 1..l_mtli_tbl.COUNT
3845: INSERT INTO mtl_transaction_lots_interface VALUES l_mtli_tbl(b);
3846: IF (g_debug <= gme_debug.g_log_procedure) THEN
3847: gme_debug.put_line('End procedure '||l_api_name);
3848: END IF;
3849: EXCEPTION
3850: WHEN OTHERS THEN

Line 3847: gme_debug.put_line('End procedure '||l_api_name);

3843: INSERT INTO mtl_transactions_interface VALUES l_mti_tbl(a);
3844: FORALL b IN 1..l_mtli_tbl.COUNT
3845: INSERT INTO mtl_transaction_lots_interface VALUES l_mtli_tbl(b);
3846: IF (g_debug <= gme_debug.g_log_procedure) THEN
3847: gme_debug.put_line('End procedure '||l_api_name);
3848: END IF;
3849: EXCEPTION
3850: WHEN OTHERS THEN
3851: IF (g_debug <= gme_debug.g_log_unexpected) THEN

Line 3851: IF (g_debug <= gme_debug.g_log_unexpected) THEN

3847: gme_debug.put_line('End procedure '||l_api_name);
3848: END IF;
3849: EXCEPTION
3850: WHEN OTHERS THEN
3851: IF (g_debug <= gme_debug.g_log_unexpected) THEN
3852: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
3853: END IF;
3854: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3855: gma_common_logging.gma_migration_central_log

Line 3852: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

3848: END IF;
3849: EXCEPTION
3850: WHEN OTHERS THEN
3851: IF (g_debug <= gme_debug.g_log_unexpected) THEN
3852: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
3853: END IF;
3854: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
3855: gma_common_logging.gma_migration_central_log
3856: (p_run_id => g_migration_run_id,

Line 3898: IF (g_debug <= gme_debug.g_log_procedure) THEN

3894: l_return_status VARCHAR2(1);
3895: l_api_name VARCHAR2(30) := 'close_steps';
3896: step_close_fail EXCEPTION;
3897: BEGIN
3898: IF (g_debug <= gme_debug.g_log_procedure) THEN
3899: gme_debug.put_line('Start procedure '||l_api_name);
3900: END IF;
3901: FOR get_steps IN Cur_get_steps LOOP
3902: BEGIN

Line 3899: gme_debug.put_line('Start procedure '||l_api_name);

3895: l_api_name VARCHAR2(30) := 'close_steps';
3896: step_close_fail EXCEPTION;
3897: BEGIN
3898: IF (g_debug <= gme_debug.g_log_procedure) THEN
3899: gme_debug.put_line('Start procedure '||l_api_name);
3900: END IF;
3901: FOR get_steps IN Cur_get_steps LOOP
3902: BEGIN
3903: l_step_rec.batchstep_id := get_steps.batchstep_id;

Line 3942: IF (g_debug <= gme_debug.g_log_unexpected) THEN

3938: p_param2 => get_steps.batchstep_no,
3939: p_token3 => 'MSG',
3940: p_param3 => l_msg_data);
3941: WHEN OTHERS THEN
3942: IF (g_debug <= gme_debug.g_log_unexpected) THEN
3943: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
3944: END IF;
3945: gma_common_logging.gma_migration_central_log
3946: (p_run_id => g_migration_run_id,

Line 3943: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

3939: p_token3 => 'MSG',
3940: p_param3 => l_msg_data);
3941: WHEN OTHERS THEN
3942: IF (g_debug <= gme_debug.g_log_unexpected) THEN
3943: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
3944: END IF;
3945: gma_common_logging.gma_migration_central_log
3946: (p_run_id => g_migration_run_id,
3947: p_log_level => fnd_log.level_error,

Line 3960: IF (g_debug <= gme_debug.g_log_procedure) THEN

3956: p_token3 => 'MSG',
3957: p_param3 => SQLERRM);
3958: END;
3959: END LOOP;
3960: IF (g_debug <= gme_debug.g_log_procedure) THEN
3961: gme_debug.put_line('End procedure '||l_api_name);
3962: END IF;
3963: END close_steps;
3964:

Line 3961: gme_debug.put_line('End procedure '||l_api_name);

3957: p_param3 => SQLERRM);
3958: END;
3959: END LOOP;
3960: IF (g_debug <= gme_debug.g_log_procedure) THEN
3961: gme_debug.put_line('End procedure '||l_api_name);
3962: END IF;
3963: END close_steps;
3964:
3965: PROCEDURE insert_lab_lots IS

Line 4000: IF (g_debug <= gme_debug.g_log_procedure) THEN

3996: l_plot_in_rec gme_pending_product_lots%ROWTYPE;
3997: batch_fetch_err EXCEPTION;
3998: create_pp_lot_err EXCEPTION;
3999: BEGIN
4000: IF (g_debug <= gme_debug.g_log_procedure) THEN
4001: gme_debug.put_line('Start procedure '||l_api_name);
4002: END IF;
4003: FOR get_lots IN Cur_lab_lots LOOP
4004: BEGIN

Line 4001: gme_debug.put_line('Start procedure '||l_api_name);

3997: batch_fetch_err EXCEPTION;
3998: create_pp_lot_err EXCEPTION;
3999: BEGIN
4000: IF (g_debug <= gme_debug.g_log_procedure) THEN
4001: gme_debug.put_line('Start procedure '||l_api_name);
4002: END IF;
4003: FOR get_lots IN Cur_lab_lots LOOP
4004: BEGIN
4005: l_lot_number := NULL;

Line 4106: IF (g_debug <= gme_debug.g_log_unexpected) THEN

4102: p_token5 => 'NEW_DATA',
4103: p_param5 => l_new_data);
4104: ROLLBACK;
4105: WHEN OTHERS THEN
4106: IF (g_debug <= gme_debug.g_log_unexpected) THEN
4107: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
4108: END IF;
4109: l_txn_data := l_item_rec.segment1||'->'||get_lots.lot_id||'->'||get_lots.qty||'->'||get_lots.qty2;
4110: gma_common_logging.gma_migration_central_log

Line 4107: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);

4103: p_param5 => l_new_data);
4104: ROLLBACK;
4105: WHEN OTHERS THEN
4106: IF (g_debug <= gme_debug.g_log_unexpected) THEN
4107: gme_debug.put_line('When others in '||l_api_name||' '||SQLERRM);
4108: END IF;
4109: l_txn_data := l_item_rec.segment1||'->'||get_lots.lot_id||'->'||get_lots.qty||'->'||get_lots.qty2;
4110: gma_common_logging.gma_migration_central_log
4111: (p_run_id => g_migration_run_id,

Line 4125: IF (g_debug <= gme_debug.g_log_procedure) THEN

4121: p_param2 => SQLERRM);
4122: ROLLBACK;
4123: END;
4124: END LOOP;
4125: IF (g_debug <= gme_debug.g_log_procedure) THEN
4126: gme_debug.put_line('End procedure '||l_api_name);
4127: END IF;
4128: END insert_lab_lots;
4129: END gme_post_migration;

Line 4126: gme_debug.put_line('End procedure '||l_api_name);

4122: ROLLBACK;
4123: END;
4124: END LOOP;
4125: IF (g_debug <= gme_debug.g_log_procedure) THEN
4126: gme_debug.put_line('End procedure '||l_api_name);
4127: END IF;
4128: END insert_lab_lots;
4129: END gme_post_migration;