DBA Data[Home] [Help]

APPS.GME_API_MAIN dependencies on GME_COMMON_PVT

Line 9: := gme_common_pvt.g_max_errors

5:
6: /*************************************************************************/
7: PROCEDURE create_batch (
8: p_validation_level IN NUMBER
9: := gme_common_pvt.g_max_errors
10: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
11: ,x_message_count OUT NOCOPY NUMBER
12: ,x_message_list OUT NOCOPY VARCHAR2
13: ,x_return_status OUT NOCOPY VARCHAR2

Line 29: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)

25: ,p_ignore_qty_below_cap IN VARCHAR2 := fnd_api.g_true
26: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true
27: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_false
28: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false
29: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)
30: IS
31: l_api_name CONSTANT VARCHAR2 (30) := 'CREATE_BATCH';
32: setup_failure EXCEPTION;
33: batch_creation_failure EXCEPTION;

Line 47: IF NOT gme_common_pvt.g_setup_done THEN

43: gme_debug.put_line ('Entering api ' || g_pkg_name || '.'
44: || l_api_name);
45: END IF;
46:
47: IF NOT gme_common_pvt.g_setup_done THEN
48: gme_common_pvt.g_setup_done :=
49: gme_common_pvt.setup (p_batch_header_rec.organization_id);
50:
51: IF NOT gme_common_pvt.g_setup_done THEN

Line 48: gme_common_pvt.g_setup_done :=

44: || l_api_name);
45: END IF;
46:
47: IF NOT gme_common_pvt.g_setup_done THEN
48: gme_common_pvt.g_setup_done :=
49: gme_common_pvt.setup (p_batch_header_rec.organization_id);
50:
51: IF NOT gme_common_pvt.g_setup_done THEN
52: x_return_status := fnd_api.g_ret_sts_error;

Line 49: gme_common_pvt.setup (p_batch_header_rec.organization_id);

45: END IF;
46:
47: IF NOT gme_common_pvt.g_setup_done THEN
48: gme_common_pvt.g_setup_done :=
49: gme_common_pvt.setup (p_batch_header_rec.organization_id);
50:
51: IF NOT gme_common_pvt.g_setup_done THEN
52: x_return_status := fnd_api.g_ret_sts_error;
53: RAISE setup_failure;

Line 51: IF NOT gme_common_pvt.g_setup_done THEN

47: IF NOT gme_common_pvt.g_setup_done THEN
48: gme_common_pvt.g_setup_done :=
49: gme_common_pvt.setup (p_batch_header_rec.organization_id);
50:
51: IF NOT gme_common_pvt.g_setup_done THEN
52: x_return_status := fnd_api.g_ret_sts_error;
53: RAISE setup_failure;
54: END IF;
55: END IF;

Line 63: gme_common_pvt.g_error_count := 0;

59:
60: -- Initialize message list and count if needed
61: IF p_init_msg_list = fnd_api.g_true THEN
62: fnd_msg_pub.initialize;
63: gme_common_pvt.g_error_count := 0;
64: END IF;
65:
66: gme_common_pvt.set_timestamp;
67: gme_create_batch_pvt.create_batch

Line 66: gme_common_pvt.set_timestamp;

62: fnd_msg_pub.initialize;
63: gme_common_pvt.g_error_count := 0;
64: END IF;
65:
66: gme_common_pvt.set_timestamp;
67: gme_create_batch_pvt.create_batch
68: (p_validation_level => p_validation_level
69: ,p_batch_header_rec => p_batch_header_rec
70: ,p_batch_size => p_batch_size

Line 87: gme_common_pvt.log_message ('GME_API_BATCH_CREATED');

83: RAISE batch_creation_failure;
84: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
85:
86: IF x_message_count = 0 THEN
87: gme_common_pvt.log_message ('GME_API_BATCH_CREATED');
88: END IF;
89:
90: gme_common_pvt.count_and_get (x_count => x_message_count
91: ,p_encoded => fnd_api.g_false

Line 90: gme_common_pvt.count_and_get (x_count => x_message_count

86: IF x_message_count = 0 THEN
87: gme_common_pvt.log_message ('GME_API_BATCH_CREATED');
88: END IF;
89:
90: gme_common_pvt.count_and_get (x_count => x_message_count
91: ,p_encoded => fnd_api.g_false
92: ,x_data => x_message_list);
93:
94: IF (g_debug IS NOT NULL) THEN

Line 106: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

102: gme_debug.put_line ('Exiting api ' || g_pkg_name || '.' || l_api_name);
103: END IF;
104: EXCEPTION
105: WHEN batch_creation_failure THEN
106: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
107: ROLLBACK TO SAVEPOINT create_batch;
108: x_batch_header_rec := NULL;
109: END IF;
110:

Line 111: gme_common_pvt.count_and_get (x_count => x_message_count

107: ROLLBACK TO SAVEPOINT create_batch;
108: x_batch_header_rec := NULL;
109: END IF;
110:
111: gme_common_pvt.count_and_get (x_count => x_message_count
112: ,p_encoded => fnd_api.g_false
113: ,x_data => x_message_list);
114: WHEN setup_failure THEN
115: ROLLBACK TO SAVEPOINT create_batch;

Line 117: gme_common_pvt.count_and_get (x_count => x_message_count

113: ,x_data => x_message_list);
114: WHEN setup_failure THEN
115: ROLLBACK TO SAVEPOINT create_batch;
116: x_batch_header_rec := NULL;
117: gme_common_pvt.count_and_get (x_count => x_message_count
118: ,p_encoded => fnd_api.g_false
119: ,x_data => x_message_list);
120: x_return_status := fnd_api.g_ret_sts_error;
121: WHEN OTHERS THEN

Line 133: gme_common_pvt.count_and_get (x_count => x_message_count

129: END IF;
130:
131: ROLLBACK TO SAVEPOINT create_batch;
132: x_batch_header_rec := NULL;
133: gme_common_pvt.count_and_get (x_count => x_message_count
134: ,p_encoded => fnd_api.g_false
135: ,x_data => x_message_list);
136: x_return_status := fnd_api.g_ret_sts_unexp_error;
137: END create_batch;

Line 142: := gme_common_pvt.g_max_errors

138:
139: /*************************************************************************/
140: PROCEDURE create_phantom (
141: p_validation_level IN NUMBER
142: := gme_common_pvt.g_max_errors
143: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
144: ,x_message_count OUT NOCOPY NUMBER
145: ,x_message_list OUT NOCOPY VARCHAR2
146: ,x_return_status OUT NOCOPY VARCHAR2

Line 155: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)

151: ,p_validity_rule_id IN NUMBER
152: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true
153: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_true
154: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false
155: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)
156: IS
157: l_api_name CONSTANT VARCHAR2 (30) := 'CREATE_PHANTOM';
158: setup_failure EXCEPTION;
159: phantom_creation_failure EXCEPTION;

Line 174: IF NOT gme_common_pvt.g_setup_done THEN

170: gme_debug.put_line ('Entering api ' || g_pkg_name || '.'
171: || l_api_name);
172: END IF;
173:
174: IF NOT gme_common_pvt.g_setup_done THEN
175: gme_common_pvt.g_setup_done :=
176: gme_common_pvt.setup (p_material_detail_rec.organization_id);
177:
178: IF NOT gme_common_pvt.g_setup_done THEN

Line 175: gme_common_pvt.g_setup_done :=

171: || l_api_name);
172: END IF;
173:
174: IF NOT gme_common_pvt.g_setup_done THEN
175: gme_common_pvt.g_setup_done :=
176: gme_common_pvt.setup (p_material_detail_rec.organization_id);
177:
178: IF NOT gme_common_pvt.g_setup_done THEN
179: x_return_status := fnd_api.g_ret_sts_error;

Line 176: gme_common_pvt.setup (p_material_detail_rec.organization_id);

172: END IF;
173:
174: IF NOT gme_common_pvt.g_setup_done THEN
175: gme_common_pvt.g_setup_done :=
176: gme_common_pvt.setup (p_material_detail_rec.organization_id);
177:
178: IF NOT gme_common_pvt.g_setup_done THEN
179: x_return_status := fnd_api.g_ret_sts_error;
180: RAISE setup_failure;

Line 178: IF NOT gme_common_pvt.g_setup_done THEN

174: IF NOT gme_common_pvt.g_setup_done THEN
175: gme_common_pvt.g_setup_done :=
176: gme_common_pvt.setup (p_material_detail_rec.organization_id);
177:
178: IF NOT gme_common_pvt.g_setup_done THEN
179: x_return_status := fnd_api.g_ret_sts_error;
180: RAISE setup_failure;
181: END IF;
182: END IF;

Line 187: gme_common_pvt.g_error_count := 0;

183:
184: -- Initialize message list and count if needed
185: IF p_init_msg_list = fnd_api.g_true THEN
186: fnd_msg_pub.initialize;
187: gme_common_pvt.g_error_count := 0;
188: END IF;
189:
190: /* Set the return status to success initially */
191: x_return_status := fnd_api.g_ret_sts_success;

Line 192: gme_common_pvt.set_timestamp;

188: END IF;
189:
190: /* Set the return status to success initially */
191: x_return_status := fnd_api.g_ret_sts_success;
192: gme_common_pvt.set_timestamp;
193: gme_phantom_pvt.create_phantom
194: (p_material_detail_rec => p_material_detail_rec
195: ,p_batch_header_rec => p_batch_header_rec --Bug#6738476
196: ,p_batch_no => p_batch_no

Line 219: gme_common_pvt.count_and_get (x_count => x_message_count

215: EXCEPTION
216: WHEN phantom_creation_failure OR setup_failure THEN
217: ROLLBACK TO SAVEPOINT create_phantom;
218: x_material_detail_rec := NULL;
219: gme_common_pvt.count_and_get (x_count => x_message_count
220: ,p_encoded => fnd_api.g_false
221: ,x_data => x_message_list);
222: WHEN OTHERS THEN
223: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 235: gme_common_pvt.count_and_get (x_count => x_message_count

231:
232: ROLLBACK TO SAVEPOINT create_phantom;
233: x_material_detail_rec := NULL;
234: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
235: gme_common_pvt.count_and_get (x_count => x_message_count
236: ,p_encoded => fnd_api.g_false
237: ,x_data => x_message_list);
238: x_return_status := fnd_api.g_ret_sts_unexp_error;
239: END create_phantom;

Line 251: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab

247: ,p_qty_type IN NUMBER
248: ,p_recalc_dates IN VARCHAR2
249: ,p_use_workday_cal IN VARCHAR2
250: ,p_contiguity_override IN VARCHAR2
251: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab
252: ,x_batch_header_rec OUT NOCOPY gme_batch_header%ROWTYPE
253: ,x_message_count OUT NOCOPY NUMBER
254: ,x_message_list OUT NOCOPY VARCHAR2
255: ,x_return_status OUT NOCOPY VARCHAR2)

Line 276: IF NOT gme_common_pvt.g_setup_done THEN

272: || l_api_name);
273: END IF;
274:
275: /* Setup the common constants used accross the apis */
276: IF NOT gme_common_pvt.g_setup_done THEN
277: gme_common_pvt.g_setup_done :=
278: gme_common_pvt.setup (p_batch_header_rec.organization_id);
279:
280: IF NOT gme_common_pvt.g_setup_done THEN

Line 277: gme_common_pvt.g_setup_done :=

273: END IF;
274:
275: /* Setup the common constants used accross the apis */
276: IF NOT gme_common_pvt.g_setup_done THEN
277: gme_common_pvt.g_setup_done :=
278: gme_common_pvt.setup (p_batch_header_rec.organization_id);
279:
280: IF NOT gme_common_pvt.g_setup_done THEN
281: x_return_status := fnd_api.g_ret_sts_error;

Line 278: gme_common_pvt.setup (p_batch_header_rec.organization_id);

274:
275: /* Setup the common constants used accross the apis */
276: IF NOT gme_common_pvt.g_setup_done THEN
277: gme_common_pvt.g_setup_done :=
278: gme_common_pvt.setup (p_batch_header_rec.organization_id);
279:
280: IF NOT gme_common_pvt.g_setup_done THEN
281: x_return_status := fnd_api.g_ret_sts_error;
282: RAISE setup_failure;

Line 280: IF NOT gme_common_pvt.g_setup_done THEN

276: IF NOT gme_common_pvt.g_setup_done THEN
277: gme_common_pvt.g_setup_done :=
278: gme_common_pvt.setup (p_batch_header_rec.organization_id);
279:
280: IF NOT gme_common_pvt.g_setup_done THEN
281: x_return_status := fnd_api.g_ret_sts_error;
282: RAISE setup_failure;
283: END IF;
284: END IF;

Line 290: gme_common_pvt.g_error_count := 0;

286:
287: /* Initialize message list and count if needed */
288: IF p_init_msg_list = fnd_api.g_true THEN
289: fnd_msg_pub.initialize;
290: gme_common_pvt.g_error_count := 0;
291: END IF;
292:
293: x_batch_header_rec := p_batch_header_rec;
294: gme_common_pvt.set_timestamp;

Line 294: gme_common_pvt.set_timestamp;

290: gme_common_pvt.g_error_count := 0;
291: END IF;
292:
293: x_batch_header_rec := p_batch_header_rec;
294: gme_common_pvt.set_timestamp;
295:
296: gme_scale_batch_pvt.scale_batch
297: (p_batch_header_rec => p_batch_header_rec
298: ,p_scale_factor => p_scale_factor

Line 312: gme_common_pvt.log_message ('GME_SCALE_SUCCESS');

308: -- pawan kumar bug 5358705 add condition for different return status 'c' and 'w'
309: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, 'C', 'W') THEN
310: RAISE scale_batch_failed;
311: END IF;
312: gme_common_pvt.log_message ('GME_SCALE_SUCCESS');
313: IF (g_debug <= gme_debug.g_log_procedure) THEN
314: gme_debug.put_line ( 'Completed '
315: || l_api_name
316: || ' at '

Line 324: gme_common_pvt.count_and_get (x_count => x_message_count

320: WHEN setup_failure THEN
321: ROLLBACK TO SAVEPOINT scale_batch;
322: x_batch_header_rec := NULL;
323: x_return_status := fnd_api.g_ret_sts_error;
324: gme_common_pvt.count_and_get (x_count => x_message_count
325: ,p_encoded => fnd_api.g_false
326: ,x_data => x_message_list);
327: WHEN scale_batch_failed THEN
328: ROLLBACK TO SAVEPOINT scale_batch;

Line 330: gme_common_pvt.count_and_get (x_count => x_message_count

326: ,x_data => x_message_list);
327: WHEN scale_batch_failed THEN
328: ROLLBACK TO SAVEPOINT scale_batch;
329: x_batch_header_rec := NULL;
330: gme_common_pvt.count_and_get (x_count => x_message_count
331: ,p_encoded => fnd_api.g_false
332: ,x_data => x_message_list);
333: WHEN batch_save_failed OR batch_fetch_error THEN
334: ROLLBACK TO SAVEPOINT scale_batch;

Line 336: gme_common_pvt.count_and_get (x_count => x_message_count

332: ,x_data => x_message_list);
333: WHEN batch_save_failed OR batch_fetch_error THEN
334: ROLLBACK TO SAVEPOINT scale_batch;
335: x_batch_header_rec := NULL;
336: gme_common_pvt.count_and_get (x_count => x_message_count
337: ,p_encoded => fnd_api.g_false
338: ,x_data => x_message_list);
339: WHEN OTHERS THEN
340: ROLLBACK TO SAVEPOINT scale_batch;

Line 343: gme_common_pvt.count_and_get (x_count => x_message_count

339: WHEN OTHERS THEN
340: ROLLBACK TO SAVEPOINT scale_batch;
341: x_batch_header_rec := NULL;
342: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
343: gme_common_pvt.count_and_get (x_count => x_message_count
344: ,p_encoded => fnd_api.g_false
345: ,x_data => x_message_list);
346: x_return_status := fnd_api.g_ret_sts_unexp_error;
347: END scale_batch;

Line 378: IF NOT gme_common_pvt.g_setup_done THEN

374: || l_api_name);
375: END IF;
376:
377: /* Setup the common constants used accross the apis */
378: IF NOT gme_common_pvt.g_setup_done THEN
379: gme_common_pvt.g_setup_done :=
380: gme_common_pvt.setup
381: (p_org_id => p_batch_header_rec.organization_id);
382:

Line 379: gme_common_pvt.g_setup_done :=

375: END IF;
376:
377: /* Setup the common constants used accross the apis */
378: IF NOT gme_common_pvt.g_setup_done THEN
379: gme_common_pvt.g_setup_done :=
380: gme_common_pvt.setup
381: (p_org_id => p_batch_header_rec.organization_id);
382:
383: IF NOT gme_common_pvt.g_setup_done THEN

Line 380: gme_common_pvt.setup

376:
377: /* Setup the common constants used accross the apis */
378: IF NOT gme_common_pvt.g_setup_done THEN
379: gme_common_pvt.g_setup_done :=
380: gme_common_pvt.setup
381: (p_org_id => p_batch_header_rec.organization_id);
382:
383: IF NOT gme_common_pvt.g_setup_done THEN
384: RAISE setup_failure;

Line 383: IF NOT gme_common_pvt.g_setup_done THEN

379: gme_common_pvt.g_setup_done :=
380: gme_common_pvt.setup
381: (p_org_id => p_batch_header_rec.organization_id);
382:
383: IF NOT gme_common_pvt.g_setup_done THEN
384: RAISE setup_failure;
385: END IF;
386: END IF;
387:

Line 391: gme_common_pvt.g_error_count := 0;

387:
388: /* Initialize message list and count if needed */
389: IF p_init_msg_list = fnd_api.g_true THEN
390: fnd_msg_pub.initialize;
391: gme_common_pvt.g_error_count := 0;
392: END IF;
393:
394: gme_common_pvt.set_timestamp;
395: gme_scale_batch_pvt.theoretical_yield_batch

Line 394: gme_common_pvt.set_timestamp;

390: fnd_msg_pub.initialize;
391: gme_common_pvt.g_error_count := 0;
392: END IF;
393:
394: gme_common_pvt.set_timestamp;
395: gme_scale_batch_pvt.theoretical_yield_batch
396: (p_batch_header_rec => p_batch_header_rec
397: ,p_scale_factor => p_scale_factor
398: ,x_return_status => x_return_status);

Line 404: gme_common_pvt.count_and_get (x_count => x_message_count

400: IF x_return_status <> fnd_api.g_ret_sts_success THEN
401: RAISE theoretical_yield_failed;
402: END IF;
403:
404: gme_common_pvt.count_and_get (x_count => x_message_count
405: ,p_encoded => fnd_api.g_false
406: ,x_data => x_message_list);
407:
408: IF (g_debug <= gme_debug.g_log_procedure) THEN

Line 418: gme_common_pvt.count_and_get (x_count => x_message_count

414: EXCEPTION
415: WHEN setup_failure THEN
416: ROLLBACK TO SAVEPOINT theoretical_yield_batch;
417: x_return_status := fnd_api.g_ret_sts_error;
418: gme_common_pvt.count_and_get (x_count => x_message_count
419: ,p_encoded => fnd_api.g_false
420: ,x_data => x_message_list);
421: WHEN theoretical_yield_failed OR batch_save_failed THEN
422: ROLLBACK TO SAVEPOINT theoretical_yield_batch;

Line 423: gme_common_pvt.count_and_get (x_count => x_message_count

419: ,p_encoded => fnd_api.g_false
420: ,x_data => x_message_list);
421: WHEN theoretical_yield_failed OR batch_save_failed THEN
422: ROLLBACK TO SAVEPOINT theoretical_yield_batch;
423: gme_common_pvt.count_and_get (x_count => x_message_count
424: ,p_encoded => fnd_api.g_false
425: ,x_data => x_message_list);
426: WHEN OTHERS THEN
427: ROLLBACK TO SAVEPOINT theoretical_yield_batch;

Line 429: gme_common_pvt.count_and_get (x_count => x_message_count

425: ,x_data => x_message_list);
426: WHEN OTHERS THEN
427: ROLLBACK TO SAVEPOINT theoretical_yield_batch;
428: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
429: gme_common_pvt.count_and_get (x_count => x_message_count
430: ,p_encoded => fnd_api.g_false
431: ,x_data => x_message_list);
432: x_return_status := fnd_api.g_ret_sts_unexp_error;
433: END theoretical_yield_batch;

Line 438: := gme_common_pvt.g_max_errors

434:
435: /*************************************************************************/
436: PROCEDURE insert_material_line (
437: p_validation_level IN NUMBER
438: := gme_common_pvt.g_max_errors
439: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
440: ,x_message_count OUT NOCOPY NUMBER
441: ,x_message_list OUT NOCOPY VARCHAR2
442: ,x_return_status OUT NOCOPY VARCHAR2

Line 476: IF NOT gme_common_pvt.g_setup_done THEN

472: gme_debug.put_line ('Entering api ' || g_pkg_name || '.'
473: || l_api_name);
474: END IF;
475:
476: IF NOT gme_common_pvt.g_setup_done THEN
477: gme_common_pvt.g_setup_done :=
478: gme_common_pvt.setup (p_batch_header_rec.organization_id);
479:
480: IF NOT gme_common_pvt.g_setup_done THEN

Line 477: gme_common_pvt.g_setup_done :=

473: || l_api_name);
474: END IF;
475:
476: IF NOT gme_common_pvt.g_setup_done THEN
477: gme_common_pvt.g_setup_done :=
478: gme_common_pvt.setup (p_batch_header_rec.organization_id);
479:
480: IF NOT gme_common_pvt.g_setup_done THEN
481: x_return_status := fnd_api.g_ret_sts_error;

Line 478: gme_common_pvt.setup (p_batch_header_rec.organization_id);

474: END IF;
475:
476: IF NOT gme_common_pvt.g_setup_done THEN
477: gme_common_pvt.g_setup_done :=
478: gme_common_pvt.setup (p_batch_header_rec.organization_id);
479:
480: IF NOT gme_common_pvt.g_setup_done THEN
481: x_return_status := fnd_api.g_ret_sts_error;
482: RAISE setup_failure;

Line 480: IF NOT gme_common_pvt.g_setup_done THEN

476: IF NOT gme_common_pvt.g_setup_done THEN
477: gme_common_pvt.g_setup_done :=
478: gme_common_pvt.setup (p_batch_header_rec.organization_id);
479:
480: IF NOT gme_common_pvt.g_setup_done THEN
481: x_return_status := fnd_api.g_ret_sts_error;
482: RAISE setup_failure;
483: END IF;
484: END IF;

Line 489: gme_common_pvt.g_error_count := 0;

485:
486: -- Initialize message list and count if needed
487: IF p_init_msg_list = fnd_api.g_true THEN
488: fnd_msg_pub.initialize;
489: gme_common_pvt.g_error_count := 0;
490: END IF;
491:
492: gme_common_pvt.set_timestamp;
493:

Line 492: gme_common_pvt.set_timestamp;

488: fnd_msg_pub.initialize;
489: gme_common_pvt.g_error_count := 0;
490: END IF;
491:
492: gme_common_pvt.set_timestamp;
493:
494: IF p_batch_step_id IS NOT NULL THEN
495: l_batch_step_rec.batchstep_id := p_batch_step_id;
496:

Line 520: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_ADDED

516: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
517:
518:
519: -- NEW
520: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_ADDED
521: ,P_EVENT_KEY => x_material_detail_rec.batch_id||'-'||x_material_detail_rec.material_detail_id
522: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_MATL_LABEL')
523: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
524: '-'||p_batch_header_rec.batch_no||'-'|| x_material_detail_rec.Line_no

Line 523: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||

519: -- NEW
520: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_ADDED
521: ,P_EVENT_KEY => x_material_detail_rec.batch_id||'-'||x_material_detail_rec.material_detail_id
522: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_MATL_LABEL')
523: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
524: '-'||p_batch_header_rec.batch_no||'-'|| x_material_detail_rec.Line_no
525: ||'-'||GME_ERES_PKG.GET_ITEM_NUMBER(x_material_detail_rec.organization_id,x_material_detail_rec.inventory_item_id)
526: ,P_POST_OP_API => 'NONE'
527: ,P_PARENT_EVENT => NULL

Line 551: gme_common_pvt.count_and_get (x_count => x_message_count

547: THEN
548: RAISE gmf_cost_failure;
549: END IF;
550:
551: gme_common_pvt.count_and_get (x_count => x_message_count
552: ,p_encoded => fnd_api.g_false
553: ,x_data => x_message_list);
554:
555: IF (g_debug IS NOT NULL) THEN

Line 568: x_return_status := gme_common_pvt.g_gmf_vib_err ;

564: EXCEPTION
565: WHEN gmf_cost_failure THEN
566: -- Bug 5903208
567: -- Bug 13070352 - Return g_gmf_vib_err instead of ERROR.
568: x_return_status := gme_common_pvt.g_gmf_vib_err ;
569: gme_debug.put_line ( g_pkg_name
570: || '.'
571: || l_api_name
572: || ':'

Line 576: gme_debug.put_line('gme_common_pvt.g_gmf_vib_err is:' || gme_common_pvt.g_gmf_vib_err);

572: || ':'
573: || 'gmf_cost_failure in insert'
574: || SQLERRM);
575:
576: gme_debug.put_line('gme_common_pvt.g_gmf_vib_err is:' || gme_common_pvt.g_gmf_vib_err);
577:
578: WHEN ins_mtl_line_failure THEN
579: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
580: ROLLBACK TO SAVEPOINT insert_material_line1;

Line 579: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

575:
576: gme_debug.put_line('gme_common_pvt.g_gmf_vib_err is:' || gme_common_pvt.g_gmf_vib_err);
577:
578: WHEN ins_mtl_line_failure THEN
579: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
580: ROLLBACK TO SAVEPOINT insert_material_line1;
581: x_material_detail_rec := NULL;
582: END IF;
583:

Line 584: gme_common_pvt.count_and_get (x_count => x_message_count

580: ROLLBACK TO SAVEPOINT insert_material_line1;
581: x_material_detail_rec := NULL;
582: END IF;
583:
584: gme_common_pvt.count_and_get (x_count => x_message_count
585: ,p_encoded => fnd_api.g_false
586: ,x_data => x_message_list);
587: WHEN setup_failure THEN
588: ROLLBACK TO SAVEPOINT insert_material_line1;

Line 590: gme_common_pvt.count_and_get (x_count => x_message_count

586: ,x_data => x_message_list);
587: WHEN setup_failure THEN
588: ROLLBACK TO SAVEPOINT insert_material_line1;
589: x_material_detail_rec := NULL;
590: gme_common_pvt.count_and_get (x_count => x_message_count
591: ,p_encoded => fnd_api.g_false
592: ,x_data => x_message_list);
593: x_return_status := fnd_api.g_ret_sts_error;
594: WHEN OTHERS THEN

Line 607: gme_common_pvt.count_and_get (x_count => x_message_count

603: || 'When others exception:'
604: || SQLERRM);
605: END IF;
606:
607: gme_common_pvt.count_and_get (x_count => x_message_count
608: ,p_encoded => fnd_api.g_false
609: ,x_data => x_message_list);
610: x_return_status := fnd_api.g_ret_sts_unexp_error;
611: END insert_material_line;

Line 616: := gme_common_pvt.g_max_errors

612:
613: /*************************************************************************/
614: PROCEDURE insert_material_line (
615: p_validation_level IN NUMBER
616: := gme_common_pvt.g_max_errors
617: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
618: ,x_message_count OUT NOCOPY NUMBER
619: ,x_message_list OUT NOCOPY VARCHAR2
620: ,x_return_status OUT NOCOPY VARCHAR2

Line 647: IF NOT gme_common_pvt.g_setup_done THEN

643: gme_debug.put_line ('Entering api ' || g_pkg_name || '.'
644: || l_api_name);
645: END IF;
646:
647: IF NOT gme_common_pvt.g_setup_done THEN
648: gme_common_pvt.g_setup_done :=
649: gme_common_pvt.setup (p_batch_header_rec.organization_id);
650:
651: IF NOT gme_common_pvt.g_setup_done THEN

Line 648: gme_common_pvt.g_setup_done :=

644: || l_api_name);
645: END IF;
646:
647: IF NOT gme_common_pvt.g_setup_done THEN
648: gme_common_pvt.g_setup_done :=
649: gme_common_pvt.setup (p_batch_header_rec.organization_id);
650:
651: IF NOT gme_common_pvt.g_setup_done THEN
652: x_return_status := fnd_api.g_ret_sts_error;

Line 649: gme_common_pvt.setup (p_batch_header_rec.organization_id);

645: END IF;
646:
647: IF NOT gme_common_pvt.g_setup_done THEN
648: gme_common_pvt.g_setup_done :=
649: gme_common_pvt.setup (p_batch_header_rec.organization_id);
650:
651: IF NOT gme_common_pvt.g_setup_done THEN
652: x_return_status := fnd_api.g_ret_sts_error;
653: RAISE setup_failure;

Line 651: IF NOT gme_common_pvt.g_setup_done THEN

647: IF NOT gme_common_pvt.g_setup_done THEN
648: gme_common_pvt.g_setup_done :=
649: gme_common_pvt.setup (p_batch_header_rec.organization_id);
650:
651: IF NOT gme_common_pvt.g_setup_done THEN
652: x_return_status := fnd_api.g_ret_sts_error;
653: RAISE setup_failure;
654: END IF;
655: END IF;

Line 660: gme_common_pvt.g_error_count := 0;

656:
657: -- Initialize message list and count if needed
658: IF p_init_msg_list = fnd_api.g_true THEN
659: fnd_msg_pub.initialize;
660: gme_common_pvt.g_error_count := 0;
661: END IF;
662:
663: gme_common_pvt.set_timestamp;
664:

Line 663: gme_common_pvt.set_timestamp;

659: fnd_msg_pub.initialize;
660: gme_common_pvt.g_error_count := 0;
661: END IF;
662:
663: gme_common_pvt.set_timestamp;
664:
665: gme_material_detail_pvt.insert_material_line
666: (p_batch_header_rec => p_batch_header_rec
667: ,p_material_detail_rec => p_material_detail_rec

Line 678: gme_common_pvt.log_message ('GME_MTL_LINE_INSERTED');

674: IF x_return_status <> fnd_api.g_ret_sts_success THEN
675: RAISE ins_mtl_line_failure;
676: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
677:
678: gme_common_pvt.log_message ('GME_MTL_LINE_INSERTED');
679:
680:
681: gme_common_pvt.count_and_get (x_count => x_message_count
682: ,p_encoded => fnd_api.g_false

Line 681: gme_common_pvt.count_and_get (x_count => x_message_count

677:
678: gme_common_pvt.log_message ('GME_MTL_LINE_INSERTED');
679:
680:
681: gme_common_pvt.count_and_get (x_count => x_message_count
682: ,p_encoded => fnd_api.g_false
683: ,x_data => x_message_list);
684:
685: IF (g_debug IS NOT NULL) THEN

Line 696: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

692: x_return_status := fnd_api.g_ret_sts_success;
693: END IF;
694: EXCEPTION
695: WHEN ins_mtl_line_failure THEN
696: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
697: ROLLBACK TO SAVEPOINT insert_material_line;
698: x_material_detail_rec := NULL;
699: END IF;
700:

Line 701: gme_common_pvt.count_and_get (x_count => x_message_count

697: ROLLBACK TO SAVEPOINT insert_material_line;
698: x_material_detail_rec := NULL;
699: END IF;
700:
701: gme_common_pvt.count_and_get (x_count => x_message_count
702: ,p_encoded => fnd_api.g_false
703: ,x_data => x_message_list);
704: WHEN setup_failure THEN
705: ROLLBACK TO SAVEPOINT insert_material_line;

Line 707: gme_common_pvt.count_and_get (x_count => x_message_count

703: ,x_data => x_message_list);
704: WHEN setup_failure THEN
705: ROLLBACK TO SAVEPOINT insert_material_line;
706: x_material_detail_rec := NULL;
707: gme_common_pvt.count_and_get (x_count => x_message_count
708: ,p_encoded => fnd_api.g_false
709: ,x_data => x_message_list);
710: x_return_status := fnd_api.g_ret_sts_error;
711: WHEN OTHERS THEN

Line 724: gme_common_pvt.count_and_get (x_count => x_message_count

720: || 'When others exception:'
721: || SQLERRM);
722: END IF;
723:
724: gme_common_pvt.count_and_get (x_count => x_message_count
725: ,p_encoded => fnd_api.g_false
726: ,x_data => x_message_list);
727: x_return_status := fnd_api.g_ret_sts_unexp_error;
728: END insert_material_line;

Line 733: := gme_common_pvt.g_max_errors

729:
730: /*************************************************************************/
731: PROCEDURE update_material_line (
732: p_validation_level IN NUMBER
733: := gme_common_pvt.g_max_errors
734: ,p_init_msg_list IN VARCHAR2
735: := fnd_api.g_false
736: ,x_message_count OUT NOCOPY NUMBER
737: ,x_message_list OUT NOCOPY VARCHAR2

Line 775: IF NOT gme_common_pvt.g_setup_done THEN

771: gme_debug.put_line ('Entering api ' || g_pkg_name || '.'
772: || l_api_name);
773: END IF;
774:
775: IF NOT gme_common_pvt.g_setup_done THEN
776: gme_common_pvt.g_setup_done :=
777: gme_common_pvt.setup (p_batch_header_rec.organization_id);
778:
779: IF NOT gme_common_pvt.g_setup_done THEN

Line 776: gme_common_pvt.g_setup_done :=

772: || l_api_name);
773: END IF;
774:
775: IF NOT gme_common_pvt.g_setup_done THEN
776: gme_common_pvt.g_setup_done :=
777: gme_common_pvt.setup (p_batch_header_rec.organization_id);
778:
779: IF NOT gme_common_pvt.g_setup_done THEN
780: x_return_status := fnd_api.g_ret_sts_error;

Line 777: gme_common_pvt.setup (p_batch_header_rec.organization_id);

773: END IF;
774:
775: IF NOT gme_common_pvt.g_setup_done THEN
776: gme_common_pvt.g_setup_done :=
777: gme_common_pvt.setup (p_batch_header_rec.organization_id);
778:
779: IF NOT gme_common_pvt.g_setup_done THEN
780: x_return_status := fnd_api.g_ret_sts_error;
781: RAISE setup_failure;

Line 779: IF NOT gme_common_pvt.g_setup_done THEN

775: IF NOT gme_common_pvt.g_setup_done THEN
776: gme_common_pvt.g_setup_done :=
777: gme_common_pvt.setup (p_batch_header_rec.organization_id);
778:
779: IF NOT gme_common_pvt.g_setup_done THEN
780: x_return_status := fnd_api.g_ret_sts_error;
781: RAISE setup_failure;
782: END IF;
783: END IF;

Line 788: gme_common_pvt.g_error_count := 0;

784:
785: -- Initialize message list and count if needed
786: IF p_init_msg_list = fnd_api.g_true THEN
787: fnd_msg_pub.initialize;
788: gme_common_pvt.g_error_count := 0;
789: END IF;
790:
791: gme_common_pvt.set_timestamp;
792:

Line 791: gme_common_pvt.set_timestamp;

787: fnd_msg_pub.initialize;
788: gme_common_pvt.g_error_count := 0;
789: END IF;
790:
791: gme_common_pvt.set_timestamp;
792:
793: IF p_batch_step_id IS NOT NULL THEN
794: l_batch_step_rec.batchstep_id := p_batch_step_id;
795:

Line 828: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_UPDATED

824: RAISE upd_mtl_line_failure;
825: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
826:
827: -- NEW
828: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_UPDATED
829: ,P_EVENT_KEY => p_material_detail_rec.batch_id||'-'||p_material_detail_rec.material_detail_id
830: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_MATL_LABEL')
831: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
832: '-'||p_batch_header_rec.batch_no||'-'|| p_material_detail_rec.Line_no

Line 831: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||

827: -- NEW
828: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_UPDATED
829: ,P_EVENT_KEY => p_material_detail_rec.batch_id||'-'||p_material_detail_rec.material_detail_id
830: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_MATL_LABEL')
831: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
832: '-'||p_batch_header_rec.batch_no||'-'|| p_material_detail_rec.Line_no
833: ||'-'||GME_ERES_PKG.GET_ITEM_NUMBER(p_material_detail_rec.organization_id,p_material_detail_rec.inventory_item_id)
834: ,P_POST_OP_API => 'NONE'
835: ,P_PARENT_EVENT => NULL

Line 860: gme_common_pvt.count_and_get (x_count => x_message_count

856: THEN
857: RAISE gmf_cost_failure;
858: END IF;
859:
860: gme_common_pvt.count_and_get (x_count => x_message_count
861: ,p_encoded => fnd_api.g_false
862: ,x_data => x_message_list);
863:
864: IF (g_debug IS NOT NULL) THEN

Line 883: gme_debug.put_line('gme_common_pvt.g_gmf_vib_err is:' || gme_common_pvt.g_gmf_vib_err);

879: || l_api_name
880: || ':'
881: || 'gmf_cost_failure update'
882: || SQLERRM);
883: gme_debug.put_line('gme_common_pvt.g_gmf_vib_err is:' || gme_common_pvt.g_gmf_vib_err);
884:
885: x_return_status := gme_common_pvt.g_gmf_vib_err;
886:
887:

Line 885: x_return_status := gme_common_pvt.g_gmf_vib_err;

881: || 'gmf_cost_failure update'
882: || SQLERRM);
883: gme_debug.put_line('gme_common_pvt.g_gmf_vib_err is:' || gme_common_pvt.g_gmf_vib_err);
884:
885: x_return_status := gme_common_pvt.g_gmf_vib_err;
886:
887:
888: WHEN upd_mtl_line_failure THEN
889: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

Line 889: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

885: x_return_status := gme_common_pvt.g_gmf_vib_err;
886:
887:
888: WHEN upd_mtl_line_failure THEN
889: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
890: ROLLBACK TO SAVEPOINT update_material_line1;
891:
892: -- Bug 13743650 - Clear the cache just in case any transactions hit the tree.
893: inv_quantity_tree_pub.clear_quantity_cache;

Line 897: gme_common_pvt.count_and_get (x_count => x_message_count

893: inv_quantity_tree_pub.clear_quantity_cache;
894: x_material_detail_rec := NULL;
895: END IF;
896:
897: gme_common_pvt.count_and_get (x_count => x_message_count
898: ,p_encoded => fnd_api.g_false
899: ,x_data => x_message_list);
900: WHEN setup_failure THEN
901: ROLLBACK TO SAVEPOINT update_material_line1;

Line 903: gme_common_pvt.count_and_get (x_count => x_message_count

899: ,x_data => x_message_list);
900: WHEN setup_failure THEN
901: ROLLBACK TO SAVEPOINT update_material_line1;
902: x_material_detail_rec := NULL;
903: gme_common_pvt.count_and_get (x_count => x_message_count
904: ,p_encoded => fnd_api.g_false
905: ,x_data => x_message_list);
906: x_return_status := fnd_api.g_ret_sts_error;
907: WHEN OTHERS THEN

Line 920: gme_common_pvt.count_and_get (x_count => x_message_count

916: || 'When others exception:'
917: || SQLERRM);
918: END IF;
919:
920: gme_common_pvt.count_and_get (x_count => x_message_count
921: ,p_encoded => fnd_api.g_false
922: ,x_data => x_message_list);
923: x_return_status := fnd_api.g_ret_sts_unexp_error;
924: END update_material_line;

Line 929: := gme_common_pvt.g_max_errors

925:
926: /*************************************************************************/
927: PROCEDURE update_material_line (
928: p_validation_level IN NUMBER
929: := gme_common_pvt.g_max_errors
930: ,p_init_msg_list IN VARCHAR2
931: := fnd_api.g_false
932: ,x_message_count OUT NOCOPY NUMBER
933: ,x_message_list OUT NOCOPY VARCHAR2

Line 960: IF NOT gme_common_pvt.g_setup_done THEN

956: gme_debug.put_line ('Entering api ' || g_pkg_name || '.'
957: || l_api_name);
958: END IF;
959:
960: IF NOT gme_common_pvt.g_setup_done THEN
961: gme_common_pvt.g_setup_done :=
962: gme_common_pvt.setup (p_batch_header_rec.organization_id);
963:
964: IF NOT gme_common_pvt.g_setup_done THEN

Line 961: gme_common_pvt.g_setup_done :=

957: || l_api_name);
958: END IF;
959:
960: IF NOT gme_common_pvt.g_setup_done THEN
961: gme_common_pvt.g_setup_done :=
962: gme_common_pvt.setup (p_batch_header_rec.organization_id);
963:
964: IF NOT gme_common_pvt.g_setup_done THEN
965: x_return_status := fnd_api.g_ret_sts_error;

Line 962: gme_common_pvt.setup (p_batch_header_rec.organization_id);

958: END IF;
959:
960: IF NOT gme_common_pvt.g_setup_done THEN
961: gme_common_pvt.g_setup_done :=
962: gme_common_pvt.setup (p_batch_header_rec.organization_id);
963:
964: IF NOT gme_common_pvt.g_setup_done THEN
965: x_return_status := fnd_api.g_ret_sts_error;
966: RAISE setup_failure;

Line 964: IF NOT gme_common_pvt.g_setup_done THEN

960: IF NOT gme_common_pvt.g_setup_done THEN
961: gme_common_pvt.g_setup_done :=
962: gme_common_pvt.setup (p_batch_header_rec.organization_id);
963:
964: IF NOT gme_common_pvt.g_setup_done THEN
965: x_return_status := fnd_api.g_ret_sts_error;
966: RAISE setup_failure;
967: END IF;
968: END IF;

Line 976: gme_common_pvt.g_error_count := 0;

972:
973: -- Initialize message list and count if needed
974: IF p_init_msg_list = fnd_api.g_true THEN
975: fnd_msg_pub.initialize;
976: gme_common_pvt.g_error_count := 0;
977: END IF;
978:
979: gme_common_pvt.set_timestamp;
980: gme_material_detail_pvt.update_material_line

Line 979: gme_common_pvt.set_timestamp;

975: fnd_msg_pub.initialize;
976: gme_common_pvt.g_error_count := 0;
977: END IF;
978:
979: gme_common_pvt.set_timestamp;
980: gme_material_detail_pvt.update_material_line
981: (p_batch_header_rec => p_batch_header_rec
982: ,p_material_detail_rec => p_material_detail_rec
983: ,p_stored_material_detail_rec => p_stored_material_detail_rec

Line 995: gme_common_pvt.log_message ('GME_MTL_LINE_UPDATED');

991: IF x_return_status <> fnd_api.g_ret_sts_success THEN
992: RAISE upd_mtl_line_failure;
993: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
994:
995: gme_common_pvt.log_message ('GME_MTL_LINE_UPDATED');
996:
997:
998: gme_common_pvt.count_and_get (x_count => x_message_count
999: ,p_encoded => fnd_api.g_false

Line 998: gme_common_pvt.count_and_get (x_count => x_message_count

994:
995: gme_common_pvt.log_message ('GME_MTL_LINE_UPDATED');
996:
997:
998: gme_common_pvt.count_and_get (x_count => x_message_count
999: ,p_encoded => fnd_api.g_false
1000: ,x_data => x_message_list);
1001:
1002: IF (g_debug IS NOT NULL) THEN

Line 1013: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

1009: x_return_status := fnd_api.g_ret_sts_success;
1010: END IF;
1011: EXCEPTION
1012: WHEN upd_mtl_line_failure THEN
1013: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
1014: ROLLBACK TO SAVEPOINT update_material_line;
1015: x_material_detail_rec := NULL;
1016: END IF;
1017:

Line 1018: gme_common_pvt.count_and_get (x_count => x_message_count

1014: ROLLBACK TO SAVEPOINT update_material_line;
1015: x_material_detail_rec := NULL;
1016: END IF;
1017:
1018: gme_common_pvt.count_and_get (x_count => x_message_count
1019: ,p_encoded => fnd_api.g_false
1020: ,x_data => x_message_list);
1021: WHEN setup_failure THEN
1022: ROLLBACK TO SAVEPOINT update_material_line;

Line 1024: gme_common_pvt.count_and_get (x_count => x_message_count

1020: ,x_data => x_message_list);
1021: WHEN setup_failure THEN
1022: ROLLBACK TO SAVEPOINT update_material_line;
1023: x_material_detail_rec := NULL;
1024: gme_common_pvt.count_and_get (x_count => x_message_count
1025: ,p_encoded => fnd_api.g_false
1026: ,x_data => x_message_list);
1027: x_return_status := fnd_api.g_ret_sts_error;
1028: WHEN OTHERS THEN

Line 1041: gme_common_pvt.count_and_get (x_count => x_message_count

1037: || 'When others exception:'
1038: || SQLERRM);
1039: END IF;
1040:
1041: gme_common_pvt.count_and_get (x_count => x_message_count
1042: ,p_encoded => fnd_api.g_false
1043: ,x_data => x_message_list);
1044: x_return_status := fnd_api.g_ret_sts_unexp_error;
1045: END update_material_line;

Line 1050: := gme_common_pvt.g_max_errors

1046:
1047: /*************************************************************************/
1048: PROCEDURE delete_material_line (
1049: p_validation_level IN NUMBER
1050: := gme_common_pvt.g_max_errors
1051: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1052: ,x_message_count OUT NOCOPY NUMBER
1053: ,x_message_list OUT NOCOPY VARCHAR2
1054: ,x_return_status OUT NOCOPY VARCHAR2

Line 1089: IF NOT gme_common_pvt.g_setup_done THEN

1085: gme_debug.put_line ('Entering api ' || g_pkg_name || '.'
1086: || l_api_name);
1087: END IF;
1088:
1089: IF NOT gme_common_pvt.g_setup_done THEN
1090: gme_common_pvt.g_setup_done :=
1091: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1092:
1093: IF NOT gme_common_pvt.g_setup_done THEN

Line 1090: gme_common_pvt.g_setup_done :=

1086: || l_api_name);
1087: END IF;
1088:
1089: IF NOT gme_common_pvt.g_setup_done THEN
1090: gme_common_pvt.g_setup_done :=
1091: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1092:
1093: IF NOT gme_common_pvt.g_setup_done THEN
1094: x_return_status := fnd_api.g_ret_sts_error;

Line 1091: gme_common_pvt.setup (p_batch_header_rec.organization_id);

1087: END IF;
1088:
1089: IF NOT gme_common_pvt.g_setup_done THEN
1090: gme_common_pvt.g_setup_done :=
1091: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1092:
1093: IF NOT gme_common_pvt.g_setup_done THEN
1094: x_return_status := fnd_api.g_ret_sts_error;
1095: RAISE setup_failure;

Line 1093: IF NOT gme_common_pvt.g_setup_done THEN

1089: IF NOT gme_common_pvt.g_setup_done THEN
1090: gme_common_pvt.g_setup_done :=
1091: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1092:
1093: IF NOT gme_common_pvt.g_setup_done THEN
1094: x_return_status := fnd_api.g_ret_sts_error;
1095: RAISE setup_failure;
1096: END IF;
1097: END IF;

Line 1102: gme_common_pvt.g_error_count := 0;

1098:
1099: -- Initialize message list and count if needed
1100: IF p_init_msg_list = fnd_api.g_true THEN
1101: fnd_msg_pub.initialize;
1102: gme_common_pvt.g_error_count := 0;
1103: END IF;
1104:
1105: gme_common_pvt.set_timestamp;
1106:

Line 1105: gme_common_pvt.set_timestamp;

1101: fnd_msg_pub.initialize;
1102: gme_common_pvt.g_error_count := 0;
1103: END IF;
1104:
1105: gme_common_pvt.set_timestamp;
1106:
1107: IF p_batch_step_id IS NOT NULL THEN
1108: l_batch_step_rec.batchstep_id := p_batch_step_id;
1109:

Line 1150: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_REMOVED

1146: END IF;
1147: -- End Bug 5903208
1148:
1149: -- NEW
1150: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_REMOVED
1151: ,P_EVENT_KEY => p_material_detail_rec.batch_id||'-'||p_material_detail_rec.material_detail_id
1152: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_MATL_LABEL')
1153: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
1154: '-'||p_batch_header_rec.batch_no||'-'|| p_material_detail_rec.Line_no

Line 1153: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||

1149: -- NEW
1150: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_REMOVED
1151: ,P_EVENT_KEY => p_material_detail_rec.batch_id||'-'||p_material_detail_rec.material_detail_id
1152: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_MATL_LABEL')
1153: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
1154: '-'||p_batch_header_rec.batch_no||'-'|| p_material_detail_rec.Line_no
1155: ||'-'||GME_ERES_PKG.GET_ITEM_NUMBER(p_material_detail_rec.organization_id,p_material_detail_rec.inventory_item_id)
1156: ,P_POST_OP_API => 'NONE'
1157: ,P_PARENT_EVENT => NULL

Line 1167: gme_common_pvt.count_and_get (x_count => x_message_count

1163: RAISE del_mtl_line_failure;
1164: END IF;
1165: END IF; -- IF p_bypass_gmf
1166:
1167: gme_common_pvt.count_and_get (x_count => x_message_count
1168: ,p_encoded => fnd_api.g_false
1169: ,x_data => x_message_list);
1170:
1171: IF (g_debug IS NOT NULL) THEN

Line 1187: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

1183: -- Bug 5903208
1184: x_return_status := FND_API.G_RET_STS_ERROR;
1185:
1186: WHEN del_mtl_line_failure THEN
1187: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
1188: ROLLBACK TO SAVEPOINT delete_material_line1;
1189: END IF;
1190:
1191: gme_common_pvt.count_and_get (x_count => x_message_count

Line 1191: gme_common_pvt.count_and_get (x_count => x_message_count

1187: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
1188: ROLLBACK TO SAVEPOINT delete_material_line1;
1189: END IF;
1190:
1191: gme_common_pvt.count_and_get (x_count => x_message_count
1192: ,p_encoded => fnd_api.g_false
1193: ,x_data => x_message_list);
1194: WHEN setup_failure THEN
1195: ROLLBACK TO SAVEPOINT delete_material_line1;

Line 1196: gme_common_pvt.count_and_get (x_count => x_message_count

1192: ,p_encoded => fnd_api.g_false
1193: ,x_data => x_message_list);
1194: WHEN setup_failure THEN
1195: ROLLBACK TO SAVEPOINT delete_material_line1;
1196: gme_common_pvt.count_and_get (x_count => x_message_count
1197: ,p_encoded => fnd_api.g_false
1198: ,x_data => x_message_list);
1199: x_return_status := fnd_api.g_ret_sts_error;
1200: WHEN OTHERS THEN

Line 1212: gme_common_pvt.count_and_get (x_count => x_message_count

1208: || 'When others exception:'
1209: || SQLERRM);
1210: END IF;
1211:
1212: gme_common_pvt.count_and_get (x_count => x_message_count
1213: ,p_encoded => fnd_api.g_false
1214: ,x_data => x_message_list);
1215: x_return_status := fnd_api.g_ret_sts_unexp_error;
1216: END delete_material_line;

Line 1221: := gme_common_pvt.g_max_errors

1217:
1218: /*************************************************************************/
1219: PROCEDURE delete_material_line (
1220: p_validation_level IN NUMBER
1221: := gme_common_pvt.g_max_errors
1222: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1223: ,x_message_count OUT NOCOPY NUMBER
1224: ,x_message_list OUT NOCOPY VARCHAR2
1225: ,x_return_status OUT NOCOPY VARCHAR2

Line 1250: IF NOT gme_common_pvt.g_setup_done THEN

1246: gme_debug.put_line ('Entering api ' || g_pkg_name || '.'
1247: || l_api_name);
1248: END IF;
1249:
1250: IF NOT gme_common_pvt.g_setup_done THEN
1251: gme_common_pvt.g_setup_done :=
1252: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1253:
1254: IF NOT gme_common_pvt.g_setup_done THEN

Line 1251: gme_common_pvt.g_setup_done :=

1247: || l_api_name);
1248: END IF;
1249:
1250: IF NOT gme_common_pvt.g_setup_done THEN
1251: gme_common_pvt.g_setup_done :=
1252: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1253:
1254: IF NOT gme_common_pvt.g_setup_done THEN
1255: x_return_status := fnd_api.g_ret_sts_error;

Line 1252: gme_common_pvt.setup (p_batch_header_rec.organization_id);

1248: END IF;
1249:
1250: IF NOT gme_common_pvt.g_setup_done THEN
1251: gme_common_pvt.g_setup_done :=
1252: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1253:
1254: IF NOT gme_common_pvt.g_setup_done THEN
1255: x_return_status := fnd_api.g_ret_sts_error;
1256: RAISE setup_failure;

Line 1254: IF NOT gme_common_pvt.g_setup_done THEN

1250: IF NOT gme_common_pvt.g_setup_done THEN
1251: gme_common_pvt.g_setup_done :=
1252: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1253:
1254: IF NOT gme_common_pvt.g_setup_done THEN
1255: x_return_status := fnd_api.g_ret_sts_error;
1256: RAISE setup_failure;
1257: END IF;
1258: END IF;

Line 1263: gme_common_pvt.g_error_count := 0;

1259:
1260: -- Initialize message list and count if needed
1261: IF p_init_msg_list = fnd_api.g_true THEN
1262: fnd_msg_pub.initialize;
1263: gme_common_pvt.g_error_count := 0;
1264: END IF;
1265:
1266: gme_common_pvt.set_timestamp;
1267: gme_material_detail_pvt.delete_material_line

Line 1266: gme_common_pvt.set_timestamp;

1262: fnd_msg_pub.initialize;
1263: gme_common_pvt.g_error_count := 0;
1264: END IF;
1265:
1266: gme_common_pvt.set_timestamp;
1267: gme_material_detail_pvt.delete_material_line
1268: (p_batch_header_rec => p_batch_header_rec
1269: ,p_material_detail_rec => p_material_detail_rec
1270: ,p_batch_step_rec => p_batch_step_rec

Line 1278: gme_common_pvt.log_message ('GME_MTL_LINE_DELETED');

1274: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1275: RAISE del_mtl_line_failure;
1276: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
1277:
1278: gme_common_pvt.log_message ('GME_MTL_LINE_DELETED');
1279:
1280: gme_common_pvt.count_and_get (x_count => x_message_count
1281: ,p_encoded => fnd_api.g_false
1282: ,x_data => x_message_list);

Line 1280: gme_common_pvt.count_and_get (x_count => x_message_count

1276: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
1277:
1278: gme_common_pvt.log_message ('GME_MTL_LINE_DELETED');
1279:
1280: gme_common_pvt.count_and_get (x_count => x_message_count
1281: ,p_encoded => fnd_api.g_false
1282: ,x_data => x_message_list);
1283:
1284: IF (g_debug IS NOT NULL) THEN

Line 1295: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

1291: x_return_status := fnd_api.g_ret_sts_success;
1292: END IF;
1293: EXCEPTION
1294: WHEN del_mtl_line_failure THEN
1295: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
1296: ROLLBACK TO SAVEPOINT delete_material_line;
1297: END IF;
1298:
1299: gme_common_pvt.count_and_get (x_count => x_message_count

Line 1299: gme_common_pvt.count_and_get (x_count => x_message_count

1295: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
1296: ROLLBACK TO SAVEPOINT delete_material_line;
1297: END IF;
1298:
1299: gme_common_pvt.count_and_get (x_count => x_message_count
1300: ,p_encoded => fnd_api.g_false
1301: ,x_data => x_message_list);
1302: WHEN setup_failure THEN
1303: ROLLBACK TO SAVEPOINT delete_material_line;

Line 1304: gme_common_pvt.count_and_get (x_count => x_message_count

1300: ,p_encoded => fnd_api.g_false
1301: ,x_data => x_message_list);
1302: WHEN setup_failure THEN
1303: ROLLBACK TO SAVEPOINT delete_material_line;
1304: gme_common_pvt.count_and_get (x_count => x_message_count
1305: ,p_encoded => fnd_api.g_false
1306: ,x_data => x_message_list);
1307: x_return_status := fnd_api.g_ret_sts_error;
1308: WHEN OTHERS THEN

Line 1320: gme_common_pvt.count_and_get (x_count => x_message_count

1316: || 'When others exception:'
1317: || SQLERRM);
1318: END IF;
1319:
1320: gme_common_pvt.count_and_get (x_count => x_message_count
1321: ,p_encoded => fnd_api.g_false
1322: ,x_data => x_message_list);
1323: x_return_status := fnd_api.g_ret_sts_unexp_error;
1324: END delete_material_line;

Line 1355: IF NOT gme_common_pvt.g_setup_done THEN

1351: gme_debug.put_line (g_pkg_name || '.' || l_api_name || ':'
1352: || 'Entering');
1353: END IF;
1354:
1355: IF NOT gme_common_pvt.g_setup_done THEN
1356: gme_common_pvt.g_setup_done :=
1357: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1358:
1359: IF NOT gme_common_pvt.g_setup_done THEN

Line 1356: gme_common_pvt.g_setup_done :=

1352: || 'Entering');
1353: END IF;
1354:
1355: IF NOT gme_common_pvt.g_setup_done THEN
1356: gme_common_pvt.g_setup_done :=
1357: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1358:
1359: IF NOT gme_common_pvt.g_setup_done THEN
1360: x_return_status := fnd_api.g_ret_sts_error;

Line 1357: gme_common_pvt.setup (p_batch_header_rec.organization_id);

1353: END IF;
1354:
1355: IF NOT gme_common_pvt.g_setup_done THEN
1356: gme_common_pvt.g_setup_done :=
1357: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1358:
1359: IF NOT gme_common_pvt.g_setup_done THEN
1360: x_return_status := fnd_api.g_ret_sts_error;
1361: RAISE setup_failure;

Line 1359: IF NOT gme_common_pvt.g_setup_done THEN

1355: IF NOT gme_common_pvt.g_setup_done THEN
1356: gme_common_pvt.g_setup_done :=
1357: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1358:
1359: IF NOT gme_common_pvt.g_setup_done THEN
1360: x_return_status := fnd_api.g_ret_sts_error;
1361: RAISE setup_failure;
1362: END IF;
1363: END IF;

Line 1368: gme_common_pvt.g_error_count := 0;

1364:
1365: /* Initialize message list and count if needed */
1366: IF p_init_msg_list = fnd_api.g_true THEN
1367: fnd_msg_pub.initialize;
1368: gme_common_pvt.g_error_count := 0;
1369: END IF;
1370:
1371: gme_common_pvt.set_timestamp;
1372:

Line 1371: gme_common_pvt.set_timestamp;

1367: fnd_msg_pub.initialize;
1368: gme_common_pvt.g_error_count := 0;
1369: END IF;
1370:
1371: gme_common_pvt.set_timestamp;
1372:
1373: IF (NVL (g_debug, 0) = gme_debug.g_log_statement) THEN
1374: gme_debug.put_line ( g_pkg_name
1375: || '.'

Line 1397: gme_common_pvt.count_and_get (x_count => x_message_count

1393: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, 'C') THEN
1394: RAISE reschedule_batch_failed;
1395: END IF;
1396:
1397: gme_common_pvt.count_and_get (x_count => x_message_count
1398: ,p_encoded => fnd_api.g_false
1399: ,x_data => x_message_list);
1400:
1401: IF g_debug <= gme_debug.g_log_procedure THEN

Line 1416: gme_common_pvt.count_and_get (x_count => x_message_count

1412: WHEN setup_failure THEN
1413: ROLLBACK TO SAVEPOINT reschedule_batch;
1414: x_batch_header_rec := NULL;
1415: x_return_status := fnd_api.g_ret_sts_error;
1416: gme_common_pvt.count_and_get (x_count => x_message_count
1417: ,p_encoded => fnd_api.g_false
1418: ,x_data => x_message_list);
1419: WHEN reschedule_batch_failed THEN
1420: ROLLBACK TO SAVEPOINT reschedule_batch;

Line 1422: gme_common_pvt.count_and_get (x_count => x_message_count

1418: ,x_data => x_message_list);
1419: WHEN reschedule_batch_failed THEN
1420: ROLLBACK TO SAVEPOINT reschedule_batch;
1421: x_batch_header_rec := NULL;
1422: gme_common_pvt.count_and_get (x_count => x_message_count
1423: ,p_encoded => fnd_api.g_false
1424: ,x_data => x_message_list);
1425: WHEN OTHERS THEN
1426: ROLLBACK TO SAVEPOINT reschedule_batch;

Line 1429: gme_common_pvt.count_and_get (x_count => x_message_count

1425: WHEN OTHERS THEN
1426: ROLLBACK TO SAVEPOINT reschedule_batch;
1427: x_batch_header_rec := NULL;
1428: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
1429: gme_common_pvt.count_and_get (x_count => x_message_count
1430: ,p_encoded => fnd_api.g_false
1431: ,x_data => x_message_list);
1432: x_return_status := fnd_api.g_ret_sts_unexp_error;
1433: END reschedule_batch;

Line 1472: IF NOT gme_common_pvt.g_setup_done THEN

1468: gme_debug.put_line (g_pkg_name || '.' || l_api_name || ':'
1469: || 'Entering');
1470: END IF;
1471:
1472: IF NOT gme_common_pvt.g_setup_done THEN
1473: gme_common_pvt.g_setup_done :=
1474: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1475:
1476: IF NOT gme_common_pvt.g_setup_done THEN

Line 1473: gme_common_pvt.g_setup_done :=

1469: || 'Entering');
1470: END IF;
1471:
1472: IF NOT gme_common_pvt.g_setup_done THEN
1473: gme_common_pvt.g_setup_done :=
1474: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1475:
1476: IF NOT gme_common_pvt.g_setup_done THEN
1477: x_return_status := fnd_api.g_ret_sts_error;

Line 1474: gme_common_pvt.setup (p_batch_header_rec.organization_id);

1470: END IF;
1471:
1472: IF NOT gme_common_pvt.g_setup_done THEN
1473: gme_common_pvt.g_setup_done :=
1474: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1475:
1476: IF NOT gme_common_pvt.g_setup_done THEN
1477: x_return_status := fnd_api.g_ret_sts_error;
1478: RAISE setup_failure;

Line 1476: IF NOT gme_common_pvt.g_setup_done THEN

1472: IF NOT gme_common_pvt.g_setup_done THEN
1473: gme_common_pvt.g_setup_done :=
1474: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1475:
1476: IF NOT gme_common_pvt.g_setup_done THEN
1477: x_return_status := fnd_api.g_ret_sts_error;
1478: RAISE setup_failure;
1479: END IF;
1480: END IF;

Line 1485: gme_common_pvt.g_error_count := 0;

1481:
1482: /* Initialize message list and count if needed */
1483: IF p_init_msg_list = fnd_api.g_true THEN
1484: fnd_msg_pub.initialize;
1485: gme_common_pvt.g_error_count := 0;
1486: END IF;
1487:
1488: gme_common_pvt.set_timestamp;
1489:

Line 1488: gme_common_pvt.set_timestamp;

1484: fnd_msg_pub.initialize;
1485: gme_common_pvt.g_error_count := 0;
1486: END IF;
1487:
1488: gme_common_pvt.set_timestamp;
1489:
1490: IF (NVL (g_debug, 0) = gme_debug.g_log_statement) THEN
1491: gme_debug.put_line ( g_pkg_name
1492: || '.'

Line 1522: gme_common_pvt.log_message ('GME_API_STEP_RESCH');

1518: ELSE
1519: RAISE reschedule_step_failed;
1520: END IF;
1521:
1522: gme_common_pvt.log_message ('GME_API_STEP_RESCH');
1523:
1524:
1525: gme_common_pvt.count_and_get (x_count => x_message_count
1526: ,p_encoded => fnd_api.g_false

Line 1525: gme_common_pvt.count_and_get (x_count => x_message_count

1521:
1522: gme_common_pvt.log_message ('GME_API_STEP_RESCH');
1523:
1524:
1525: gme_common_pvt.count_and_get (x_count => x_message_count
1526: ,p_encoded => fnd_api.g_false
1527: ,x_data => x_message_list);
1528:
1529: IF g_debug <= gme_debug.g_log_procedure THEN

Line 1543: gme_common_pvt.count_and_get (x_count => x_message_count

1539: EXCEPTION
1540: WHEN reschedule_step_failed OR setup_failure THEN
1541: ROLLBACK TO SAVEPOINT reschedule_batch_step;
1542: x_batch_step_rec := NULL;
1543: gme_common_pvt.count_and_get (x_count => x_message_count
1544: ,p_encoded => fnd_api.g_false
1545: ,x_data => x_message_list);
1546: WHEN expected_error THEN
1547: ROLLBACK TO SAVEPOINT reschedule_batch_step;

Line 1554: gme_common_pvt.count_and_get (x_count => x_message_count

1550: WHEN OTHERS THEN
1551: ROLLBACK TO SAVEPOINT reschedule_batch_step;
1552: x_batch_step_rec := NULL;
1553: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
1554: gme_common_pvt.count_and_get (x_count => x_message_count
1555: ,p_encoded => fnd_api.g_false
1556: ,x_data => x_message_list);
1557: x_return_status := fnd_api.g_ret_sts_unexp_error;
1558: END reschedule_step;

Line 1584: IF NOT gme_common_pvt.g_setup_done THEN

1580: IF (g_debug IS NOT NULL) THEN
1581: gme_debug.log_initialize ('CreateBatchReservations');
1582: END IF;
1583:
1584: IF NOT gme_common_pvt.g_setup_done THEN
1585: gme_common_pvt.g_setup_done :=
1586: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1587:
1588: IF NOT gme_common_pvt.g_setup_done THEN

Line 1585: gme_common_pvt.g_setup_done :=

1581: gme_debug.log_initialize ('CreateBatchReservations');
1582: END IF;
1583:
1584: IF NOT gme_common_pvt.g_setup_done THEN
1585: gme_common_pvt.g_setup_done :=
1586: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1587:
1588: IF NOT gme_common_pvt.g_setup_done THEN
1589: RAISE setup_failure;

Line 1586: gme_common_pvt.setup (p_batch_header_rec.organization_id);

1582: END IF;
1583:
1584: IF NOT gme_common_pvt.g_setup_done THEN
1585: gme_common_pvt.g_setup_done :=
1586: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1587:
1588: IF NOT gme_common_pvt.g_setup_done THEN
1589: RAISE setup_failure;
1590: END IF;

Line 1588: IF NOT gme_common_pvt.g_setup_done THEN

1584: IF NOT gme_common_pvt.g_setup_done THEN
1585: gme_common_pvt.g_setup_done :=
1586: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1587:
1588: IF NOT gme_common_pvt.g_setup_done THEN
1589: RAISE setup_failure;
1590: END IF;
1591: END IF;
1592:

Line 1599: gme_common_pvt.g_error_count := 0;

1595:
1596: -- Initialize message list and count if needed
1597: IF p_init_msg_list = fnd_api.g_true THEN
1598: fnd_msg_pub.initialize;
1599: gme_common_pvt.g_error_count := 0;
1600: END IF;
1601:
1602: gme_common_pvt.set_timestamp;
1603: gme_reservations_pvt.create_batch_reservations

Line 1602: gme_common_pvt.set_timestamp;

1598: fnd_msg_pub.initialize;
1599: gme_common_pvt.g_error_count := 0;
1600: END IF;
1601:
1602: gme_common_pvt.set_timestamp;
1603: gme_reservations_pvt.create_batch_reservations
1604: (p_batch_id => p_batch_header_rec.batch_id
1605: ,p_timefence => 1000000
1606: ,x_return_status => x_return_status);

Line 1609: gme_common_pvt.log_message ('GME_BATCH_HL_RESERVATION_FAIL');

1605: ,p_timefence => 1000000
1606: ,x_return_status => x_return_status);
1607:
1608: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1609: gme_common_pvt.log_message ('GME_BATCH_HL_RESERVATION_FAIL');
1610: RAISE batch_reservations_failure;
1611: END IF;
1612:
1613: gme_common_pvt.log_message ('GME_BATCH_HI_RESR_CREATED');

Line 1613: gme_common_pvt.log_message ('GME_BATCH_HI_RESR_CREATED');

1609: gme_common_pvt.log_message ('GME_BATCH_HL_RESERVATION_FAIL');
1610: RAISE batch_reservations_failure;
1611: END IF;
1612:
1613: gme_common_pvt.log_message ('GME_BATCH_HI_RESR_CREATED');
1614:
1615: IF (g_debug IS NOT NULL) THEN
1616: gme_debug.put_line ( 'Completed '
1617: || l_api_name

Line 1628: gme_common_pvt.count_and_get (x_count => x_message_count

1624: END IF;
1625: EXCEPTION
1626: WHEN batch_reservations_failure THEN
1627: ROLLBACK TO SAVEPOINT create_batch_reservations;
1628: gme_common_pvt.count_and_get (x_count => x_message_count
1629: ,p_encoded => fnd_api.g_false
1630: ,x_data => x_message_list);
1631: WHEN OTHERS THEN
1632: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 1642: gme_common_pvt.count_and_get (x_count => x_message_count

1638: || SQLERRM);
1639: END IF;
1640:
1641: ROLLBACK TO SAVEPOINT create_batch_reservations;
1642: gme_common_pvt.count_and_get (x_count => x_message_count
1643: ,p_encoded => fnd_api.g_false
1644: ,x_data => x_message_list);
1645: x_return_status := fnd_api.g_ret_sts_unexp_error;
1646: END create_batch_reservations;

Line 1682: IF NOT gme_common_pvt.g_setup_done THEN

1678: IF (g_debug IS NOT NULL) THEN
1679: gme_debug.log_initialize ('CreateLineReservations');
1680: END IF;
1681:
1682: IF NOT gme_common_pvt.g_setup_done THEN
1683: gme_common_pvt.g_setup_done :=
1684: gme_common_pvt.setup (p_matl_dtl_rec.organization_id);
1685:
1686: IF NOT gme_common_pvt.g_setup_done THEN

Line 1683: gme_common_pvt.g_setup_done :=

1679: gme_debug.log_initialize ('CreateLineReservations');
1680: END IF;
1681:
1682: IF NOT gme_common_pvt.g_setup_done THEN
1683: gme_common_pvt.g_setup_done :=
1684: gme_common_pvt.setup (p_matl_dtl_rec.organization_id);
1685:
1686: IF NOT gme_common_pvt.g_setup_done THEN
1687: RAISE setup_failure;

Line 1684: gme_common_pvt.setup (p_matl_dtl_rec.organization_id);

1680: END IF;
1681:
1682: IF NOT gme_common_pvt.g_setup_done THEN
1683: gme_common_pvt.g_setup_done :=
1684: gme_common_pvt.setup (p_matl_dtl_rec.organization_id);
1685:
1686: IF NOT gme_common_pvt.g_setup_done THEN
1687: RAISE setup_failure;
1688: END IF;

Line 1686: IF NOT gme_common_pvt.g_setup_done THEN

1682: IF NOT gme_common_pvt.g_setup_done THEN
1683: gme_common_pvt.g_setup_done :=
1684: gme_common_pvt.setup (p_matl_dtl_rec.organization_id);
1685:
1686: IF NOT gme_common_pvt.g_setup_done THEN
1687: RAISE setup_failure;
1688: END IF;
1689: END IF;
1690:

Line 1697: gme_common_pvt.g_error_count := 0;

1693:
1694: -- Initialize message list and count if needed
1695: IF p_init_msg_list = fnd_api.g_true THEN
1696: fnd_msg_pub.initialize;
1697: gme_common_pvt.g_error_count := 0;
1698: END IF;
1699:
1700: gme_common_pvt.set_timestamp;
1701:

Line 1700: gme_common_pvt.set_timestamp;

1696: fnd_msg_pub.initialize;
1697: gme_common_pvt.g_error_count := 0;
1698: END IF;
1699:
1700: gme_common_pvt.set_timestamp;
1701:
1702: OPEN cur_get_item (p_matl_dtl_rec.organization_id
1703: ,p_matl_dtl_rec.inventory_item_id);
1704:

Line 1713: gme_common_pvt.get_open_qty

1709:
1710: -- Use Suggestions mode (S) in the called by param to assess the total
1711: -- unreserved quantity
1712: /* Bug 5441643 Added NVL condition for location control code*/
1713: gme_common_pvt.get_open_qty
1714: (p_mtl_dtl_rec => p_matl_dtl_rec
1715: ,p_called_by => 'S'
1716: ,p_item_location_control => NVL(l_location_control_code,1)
1717: ,p_item_restrict_locators => l_restrict_locators_code

Line 1755: --gme_common_pvt.log_message ('GME_LINE_HL_RESERVATION_FAIL');

1751: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1752: -- Bug 7261728
1753: -- Commented the line below so message - INV_INVALID_RESERVATION_QTY
1754: -- from inv_reservation_pub will be displayedd.
1755: --gme_common_pvt.log_message ('GME_LINE_HL_RESERVATION_FAIL');
1756: RAISE line_reservation_failure;
1757: END IF;
1758:
1759: gme_common_pvt.log_message ('GME_LINE_HI_RESR_CREATED');

Line 1759: gme_common_pvt.log_message ('GME_LINE_HI_RESR_CREATED');

1755: --gme_common_pvt.log_message ('GME_LINE_HL_RESERVATION_FAIL');
1756: RAISE line_reservation_failure;
1757: END IF;
1758:
1759: gme_common_pvt.log_message ('GME_LINE_HI_RESR_CREATED');
1760: IF (g_debug IS NOT NULL) THEN
1761: gme_debug.put_line ( 'Completed '
1762: || l_api_name
1763: || ' at '

Line 1773: gme_common_pvt.count_and_get (x_count => x_message_count

1769: END IF;
1770: EXCEPTION
1771: WHEN setup_failure OR get_open_qty_failure OR line_reservation_failure THEN
1772: ROLLBACK TO SAVEPOINT create_line_reservations;
1773: gme_common_pvt.count_and_get (x_count => x_message_count
1774: ,p_encoded => fnd_api.g_false
1775: ,x_data => x_message_list);
1776: x_return_status := fnd_api.g_ret_sts_error;
1777: WHEN OTHERS THEN

Line 1788: gme_common_pvt.count_and_get (x_count => x_message_count

1784: || SQLERRM);
1785: END IF;
1786:
1787: ROLLBACK TO SAVEPOINT create_line_reservations;
1788: gme_common_pvt.count_and_get (x_count => x_message_count
1789: ,p_encoded => fnd_api.g_false
1790: ,x_data => x_message_list);
1791: x_return_status := fnd_api.g_ret_sts_unexp_error;
1792: END create_line_reservations;

Line 1797: := gme_common_pvt.g_max_errors

1793:
1794: /*************************************************************************/
1795: PROCEDURE release_batch (
1796: p_validation_level IN NUMBER
1797: := gme_common_pvt.g_max_errors
1798: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1799: ,x_message_count OUT NOCOPY NUMBER
1800: ,x_message_list OUT NOCOPY VARCHAR2
1801: ,x_return_status OUT NOCOPY VARCHAR2

Line 1804: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab

1800: ,x_message_list OUT NOCOPY VARCHAR2
1801: ,x_return_status OUT NOCOPY VARCHAR2
1802: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
1803: ,x_batch_header_rec OUT NOCOPY gme_batch_header%ROWTYPE
1804: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab
1805: ,p_ignore_exception IN VARCHAR2 := NULL) --Bug#5186328
1806: IS
1807: l_api_name CONSTANT VARCHAR2 (30) := 'RELEASE_BATCH';
1808: setup_failure EXCEPTION;

Line 1823: IF NOT gme_common_pvt.g_setup_done THEN

1819: IF (g_debug IS NOT NULL) THEN
1820: gme_debug.log_initialize ('ReleaseBatch');
1821: END IF;
1822:
1823: IF NOT gme_common_pvt.g_setup_done THEN
1824: gme_common_pvt.g_setup_done :=
1825: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1826:
1827: IF NOT gme_common_pvt.g_setup_done THEN

Line 1824: gme_common_pvt.g_setup_done :=

1820: gme_debug.log_initialize ('ReleaseBatch');
1821: END IF;
1822:
1823: IF NOT gme_common_pvt.g_setup_done THEN
1824: gme_common_pvt.g_setup_done :=
1825: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1826:
1827: IF NOT gme_common_pvt.g_setup_done THEN
1828: x_return_status := fnd_api.g_ret_sts_error;

Line 1825: gme_common_pvt.setup (p_batch_header_rec.organization_id);

1821: END IF;
1822:
1823: IF NOT gme_common_pvt.g_setup_done THEN
1824: gme_common_pvt.g_setup_done :=
1825: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1826:
1827: IF NOT gme_common_pvt.g_setup_done THEN
1828: x_return_status := fnd_api.g_ret_sts_error;
1829: RAISE setup_failure;

Line 1827: IF NOT gme_common_pvt.g_setup_done THEN

1823: IF NOT gme_common_pvt.g_setup_done THEN
1824: gme_common_pvt.g_setup_done :=
1825: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1826:
1827: IF NOT gme_common_pvt.g_setup_done THEN
1828: x_return_status := fnd_api.g_ret_sts_error;
1829: RAISE setup_failure;
1830: END IF;
1831: END IF;

Line 1839: gme_common_pvt.g_error_count := 0;

1835:
1836: -- Initialize message list and count if needed
1837: IF p_init_msg_list = fnd_api.g_true THEN
1838: fnd_msg_pub.initialize;
1839: gme_common_pvt.g_error_count := 0;
1840: END IF;
1841:
1842: gme_common_pvt.set_timestamp;
1843: gme_release_batch_pvt.release_batch

Line 1842: gme_common_pvt.set_timestamp;

1838: fnd_msg_pub.initialize;
1839: gme_common_pvt.g_error_count := 0;
1840: END IF;
1841:
1842: gme_common_pvt.set_timestamp;
1843: gme_release_batch_pvt.release_batch
1844: (p_batch_header_rec => p_batch_header_rec
1845: ,p_phantom_product_id => NULL
1846: ,x_batch_header_rec => x_batch_header_rec

Line 1850: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN

1846: ,x_batch_header_rec => x_batch_header_rec
1847: ,x_return_status => x_return_status
1848: ,x_exception_material_tbl => x_exception_material_tbl);
1849:
1850: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
1851: RAISE batch_release_failure;
1852: END IF; /* IF x_return_status NOT IN */
1853:
1854: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/

Line 1856: x_return_status = gme_common_pvt.g_exceptions_err THEN

1852: END IF; /* IF x_return_status NOT IN */
1853:
1854: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
1855: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
1856: x_return_status = gme_common_pvt.g_exceptions_err THEN
1857: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
1858: ELSE
1859: gme_common_pvt.log_message ('GME_API_BATCH_RELEASED');
1860: END IF;

Line 1857: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');

1853:
1854: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
1855: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
1856: x_return_status = gme_common_pvt.g_exceptions_err THEN
1857: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
1858: ELSE
1859: gme_common_pvt.log_message ('GME_API_BATCH_RELEASED');
1860: END IF;
1861:

Line 1859: gme_common_pvt.log_message ('GME_API_BATCH_RELEASED');

1855: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
1856: x_return_status = gme_common_pvt.g_exceptions_err THEN
1857: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
1858: ELSE
1859: gme_common_pvt.log_message ('GME_API_BATCH_RELEASED');
1860: END IF;
1861:
1862:
1863: gme_common_pvt.count_and_get (x_count => x_message_count

Line 1863: gme_common_pvt.count_and_get (x_count => x_message_count

1859: gme_common_pvt.log_message ('GME_API_BATCH_RELEASED');
1860: END IF;
1861:
1862:
1863: gme_common_pvt.count_and_get (x_count => x_message_count
1864: ,p_encoded => fnd_api.g_false
1865: ,x_data => x_message_list);
1866:
1867: IF (g_debug IS NOT NULL) THEN

Line 1881: gme_common_pvt.count_and_get (x_count => x_message_count

1877: EXCEPTION
1878: WHEN batch_release_failure THEN
1879: ROLLBACK TO SAVEPOINT release_batch;
1880: x_batch_header_rec := NULL;
1881: gme_common_pvt.count_and_get (x_count => x_message_count
1882: ,p_encoded => fnd_api.g_false
1883: ,x_data => x_message_list);
1884: WHEN setup_failure THEN
1885: ROLLBACK TO SAVEPOINT release_batch;

Line 1887: gme_common_pvt.count_and_get (x_count => x_message_count

1883: ,x_data => x_message_list);
1884: WHEN setup_failure THEN
1885: ROLLBACK TO SAVEPOINT release_batch;
1886: x_batch_header_rec := NULL;
1887: gme_common_pvt.count_and_get (x_count => x_message_count
1888: ,p_encoded => fnd_api.g_false
1889: ,x_data => x_message_list);
1890: x_return_status := fnd_api.g_ret_sts_error;
1891: WHEN OTHERS THEN

Line 1903: gme_common_pvt.count_and_get (x_count => x_message_count

1899: END IF;
1900:
1901: ROLLBACK TO SAVEPOINT release_batch;
1902: x_batch_header_rec := NULL;
1903: gme_common_pvt.count_and_get (x_count => x_message_count
1904: ,p_encoded => fnd_api.g_false
1905: ,x_data => x_message_list);
1906: x_return_status := fnd_api.g_ret_sts_unexp_error;
1907: END release_batch;

Line 1912: := gme_common_pvt.g_max_errors

1908:
1909: /*************************************************************************/
1910: PROCEDURE release_step (
1911: p_validation_level IN NUMBER
1912: := gme_common_pvt.g_max_errors
1913: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1914: ,x_message_count OUT NOCOPY NUMBER
1915: ,x_message_list OUT NOCOPY VARCHAR2
1916: ,x_return_status OUT NOCOPY VARCHAR2

Line 1920: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab

1916: ,x_return_status OUT NOCOPY VARCHAR2
1917: ,p_batch_step_rec IN gme_batch_steps%ROWTYPE
1918: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
1919: ,x_batch_step_rec OUT NOCOPY gme_batch_steps%ROWTYPE
1920: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab
1921: ,p_ignore_exception IN VARCHAR2 := NULL) --Bug#5186328
1922: IS
1923: l_api_name CONSTANT VARCHAR2 (30) := 'RELEASE_STEP';
1924: setup_failure EXCEPTION;

Line 1939: IF NOT gme_common_pvt.g_setup_done THEN

1935: IF (g_debug IS NOT NULL) THEN
1936: gme_debug.log_initialize ('ReleaseStep');
1937: END IF;
1938:
1939: IF NOT gme_common_pvt.g_setup_done THEN
1940: gme_common_pvt.g_setup_done :=
1941: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1942:
1943: IF NOT gme_common_pvt.g_setup_done THEN

Line 1940: gme_common_pvt.g_setup_done :=

1936: gme_debug.log_initialize ('ReleaseStep');
1937: END IF;
1938:
1939: IF NOT gme_common_pvt.g_setup_done THEN
1940: gme_common_pvt.g_setup_done :=
1941: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1942:
1943: IF NOT gme_common_pvt.g_setup_done THEN
1944: x_return_status := fnd_api.g_ret_sts_error;

Line 1941: gme_common_pvt.setup (p_batch_header_rec.organization_id);

1937: END IF;
1938:
1939: IF NOT gme_common_pvt.g_setup_done THEN
1940: gme_common_pvt.g_setup_done :=
1941: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1942:
1943: IF NOT gme_common_pvt.g_setup_done THEN
1944: x_return_status := fnd_api.g_ret_sts_error;
1945: RAISE setup_failure;

Line 1943: IF NOT gme_common_pvt.g_setup_done THEN

1939: IF NOT gme_common_pvt.g_setup_done THEN
1940: gme_common_pvt.g_setup_done :=
1941: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1942:
1943: IF NOT gme_common_pvt.g_setup_done THEN
1944: x_return_status := fnd_api.g_ret_sts_error;
1945: RAISE setup_failure;
1946: END IF;
1947: END IF;

Line 1955: gme_common_pvt.g_error_count := 0;

1951:
1952: -- Initialize message list and count if needed
1953: IF p_init_msg_list = fnd_api.g_true THEN
1954: fnd_msg_pub.initialize;
1955: gme_common_pvt.g_error_count := 0;
1956: END IF;
1957:
1958: gme_common_pvt.set_timestamp;
1959: gme_release_batch_step_pvt.release_step

Line 1958: gme_common_pvt.set_timestamp;

1954: fnd_msg_pub.initialize;
1955: gme_common_pvt.g_error_count := 0;
1956: END IF;
1957:
1958: gme_common_pvt.set_timestamp;
1959: gme_release_batch_step_pvt.release_step
1960: (p_batch_step_rec => p_batch_step_rec
1961: ,p_batch_header_rec => p_batch_header_rec
1962: ,x_batch_step_rec => x_batch_step_rec

Line 1966: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN

1962: ,x_batch_step_rec => x_batch_step_rec
1963: ,x_exception_material_tbl => x_exception_material_tbl
1964: ,x_return_status => x_return_status);
1965:
1966: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
1967: RAISE step_release_failure;
1968: END IF; /* IF x_return_status NOT IN */
1969:
1970: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/

Line 1972: x_return_status = gme_common_pvt.g_exceptions_err THEN

1968: END IF; /* IF x_return_status NOT IN */
1969:
1970: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
1971: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
1972: x_return_status = gme_common_pvt.g_exceptions_err THEN
1973: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
1974: ELSE
1975: gme_common_pvt.log_message ('GME_API_STEP_RELEASED');
1976: END IF;

Line 1973: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');

1969:
1970: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
1971: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
1972: x_return_status = gme_common_pvt.g_exceptions_err THEN
1973: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
1974: ELSE
1975: gme_common_pvt.log_message ('GME_API_STEP_RELEASED');
1976: END IF;
1977:

Line 1975: gme_common_pvt.log_message ('GME_API_STEP_RELEASED');

1971: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
1972: x_return_status = gme_common_pvt.g_exceptions_err THEN
1973: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
1974: ELSE
1975: gme_common_pvt.log_message ('GME_API_STEP_RELEASED');
1976: END IF;
1977:
1978:
1979: gme_common_pvt.count_and_get (x_count => x_message_count

Line 1979: gme_common_pvt.count_and_get (x_count => x_message_count

1975: gme_common_pvt.log_message ('GME_API_STEP_RELEASED');
1976: END IF;
1977:
1978:
1979: gme_common_pvt.count_and_get (x_count => x_message_count
1980: ,p_encoded => fnd_api.g_false
1981: ,x_data => x_message_list);
1982:
1983: IF (g_debug IS NOT NULL) THEN

Line 1997: gme_common_pvt.count_and_get (x_count => x_message_count

1993: EXCEPTION
1994: WHEN step_release_failure THEN
1995: ROLLBACK TO SAVEPOINT release_step;
1996: x_batch_step_rec := NULL;
1997: gme_common_pvt.count_and_get (x_count => x_message_count
1998: ,p_encoded => fnd_api.g_false
1999: ,x_data => x_message_list);
2000: WHEN setup_failure THEN
2001: ROLLBACK TO SAVEPOINT release_step;

Line 2003: gme_common_pvt.count_and_get (x_count => x_message_count

1999: ,x_data => x_message_list);
2000: WHEN setup_failure THEN
2001: ROLLBACK TO SAVEPOINT release_step;
2002: x_batch_step_rec := NULL;
2003: gme_common_pvt.count_and_get (x_count => x_message_count
2004: ,p_encoded => fnd_api.g_false
2005: ,x_data => x_message_list);
2006: x_return_status := fnd_api.g_ret_sts_error;
2007: WHEN OTHERS THEN

Line 2019: gme_common_pvt.count_and_get (x_count => x_message_count

2015: END IF;
2016:
2017: ROLLBACK TO SAVEPOINT release_step;
2018: x_batch_step_rec := NULL;
2019: gme_common_pvt.count_and_get (x_count => x_message_count
2020: ,p_encoded => fnd_api.g_false
2021: ,x_data => x_message_list);
2022: x_return_status := fnd_api.g_ret_sts_unexp_error;
2023: END release_step;

Line 2028: := gme_common_pvt.g_max_errors

2024:
2025: /*************************************************************************/
2026: PROCEDURE complete_batch (
2027: p_validation_level IN NUMBER
2028: := gme_common_pvt.g_max_errors
2029: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2030: ,x_message_count OUT NOCOPY NUMBER
2031: ,x_message_list OUT NOCOPY VARCHAR2
2032: ,x_return_status OUT NOCOPY VARCHAR2

Line 2035: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab

2031: ,x_message_list OUT NOCOPY VARCHAR2
2032: ,x_return_status OUT NOCOPY VARCHAR2
2033: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
2034: ,x_batch_header_rec OUT NOCOPY gme_batch_header%ROWTYPE
2035: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab
2036: ,p_ignore_exception IN VARCHAR2 := NULL) --Bug#5186328
2037: IS
2038: l_api_name CONSTANT VARCHAR2 (30) := 'COMPLETE_BATCH';
2039: setup_failure EXCEPTION;

Line 2054: IF NOT gme_common_pvt.g_setup_done THEN

2050: IF (g_debug IS NOT NULL) THEN
2051: gme_debug.log_initialize ('CompleteBatch');
2052: END IF;
2053:
2054: IF NOT gme_common_pvt.g_setup_done THEN
2055: gme_common_pvt.g_setup_done :=
2056: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2057:
2058: IF NOT gme_common_pvt.g_setup_done THEN

Line 2055: gme_common_pvt.g_setup_done :=

2051: gme_debug.log_initialize ('CompleteBatch');
2052: END IF;
2053:
2054: IF NOT gme_common_pvt.g_setup_done THEN
2055: gme_common_pvt.g_setup_done :=
2056: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2057:
2058: IF NOT gme_common_pvt.g_setup_done THEN
2059: x_return_status := fnd_api.g_ret_sts_error;

Line 2056: gme_common_pvt.setup (p_batch_header_rec.organization_id);

2052: END IF;
2053:
2054: IF NOT gme_common_pvt.g_setup_done THEN
2055: gme_common_pvt.g_setup_done :=
2056: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2057:
2058: IF NOT gme_common_pvt.g_setup_done THEN
2059: x_return_status := fnd_api.g_ret_sts_error;
2060: RAISE setup_failure;

Line 2058: IF NOT gme_common_pvt.g_setup_done THEN

2054: IF NOT gme_common_pvt.g_setup_done THEN
2055: gme_common_pvt.g_setup_done :=
2056: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2057:
2058: IF NOT gme_common_pvt.g_setup_done THEN
2059: x_return_status := fnd_api.g_ret_sts_error;
2060: RAISE setup_failure;
2061: END IF;
2062: END IF;

Line 2070: gme_common_pvt.g_error_count := 0;

2066:
2067: -- Initialize message list and count if needed
2068: IF p_init_msg_list = fnd_api.g_true THEN
2069: fnd_msg_pub.initialize;
2070: gme_common_pvt.g_error_count := 0;
2071: END IF;
2072:
2073: gme_common_pvt.set_timestamp;
2074: gme_complete_batch_pvt.complete_batch

Line 2073: gme_common_pvt.set_timestamp;

2069: fnd_msg_pub.initialize;
2070: gme_common_pvt.g_error_count := 0;
2071: END IF;
2072:
2073: gme_common_pvt.set_timestamp;
2074: gme_complete_batch_pvt.complete_batch
2075: (p_batch_header_rec => p_batch_header_rec
2076: ,x_exception_material_tbl => x_exception_material_tbl
2077: ,x_batch_header_rec => x_batch_header_rec

Line 2080: IF x_return_status NOT IN(fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN

2076: ,x_exception_material_tbl => x_exception_material_tbl
2077: ,x_batch_header_rec => x_batch_header_rec
2078: ,x_return_status => x_return_status);
2079:
2080: IF x_return_status NOT IN(fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
2081: RAISE batch_complete_failure;
2082: END IF; /* IF x_return_status NOT IN */
2083:
2084: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/

Line 2086: x_return_status = gme_common_pvt.g_exceptions_err THEN

2082: END IF; /* IF x_return_status NOT IN */
2083:
2084: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
2085: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
2086: x_return_status = gme_common_pvt.g_exceptions_err THEN
2087: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
2088: ELSE
2089: gme_common_pvt.log_message ('GME_API_BATCH_COMPLETED');
2090: END IF;

Line 2087: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');

2083:
2084: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
2085: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
2086: x_return_status = gme_common_pvt.g_exceptions_err THEN
2087: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
2088: ELSE
2089: gme_common_pvt.log_message ('GME_API_BATCH_COMPLETED');
2090: END IF;
2091:

Line 2089: gme_common_pvt.log_message ('GME_API_BATCH_COMPLETED');

2085: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
2086: x_return_status = gme_common_pvt.g_exceptions_err THEN
2087: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
2088: ELSE
2089: gme_common_pvt.log_message ('GME_API_BATCH_COMPLETED');
2090: END IF;
2091:
2092: gme_common_pvt.count_and_get (x_count => x_message_count
2093: ,p_encoded => fnd_api.g_false

Line 2092: gme_common_pvt.count_and_get (x_count => x_message_count

2088: ELSE
2089: gme_common_pvt.log_message ('GME_API_BATCH_COMPLETED');
2090: END IF;
2091:
2092: gme_common_pvt.count_and_get (x_count => x_message_count
2093: ,p_encoded => fnd_api.g_false
2094: ,x_data => x_message_list);
2095:
2096: IF (g_debug IS NOT NULL) THEN

Line 2110: gme_common_pvt.count_and_get (x_count => x_message_count

2106: EXCEPTION
2107: WHEN batch_complete_failure THEN
2108: ROLLBACK TO SAVEPOINT complete_batch;
2109: x_batch_header_rec := NULL;
2110: gme_common_pvt.count_and_get (x_count => x_message_count
2111: ,p_encoded => fnd_api.g_false
2112: ,x_data => x_message_list);
2113: WHEN setup_failure THEN
2114: ROLLBACK TO SAVEPOINT complete_batch;

Line 2116: gme_common_pvt.count_and_get (x_count => x_message_count

2112: ,x_data => x_message_list);
2113: WHEN setup_failure THEN
2114: ROLLBACK TO SAVEPOINT complete_batch;
2115: x_batch_header_rec := NULL;
2116: gme_common_pvt.count_and_get (x_count => x_message_count
2117: ,p_encoded => fnd_api.g_false
2118: ,x_data => x_message_list);
2119: x_return_status := fnd_api.g_ret_sts_error;
2120: WHEN OTHERS THEN

Line 2132: gme_common_pvt.count_and_get (x_count => x_message_count

2128: END IF;
2129:
2130: ROLLBACK TO SAVEPOINT complete_batch;
2131: x_batch_header_rec := NULL;
2132: gme_common_pvt.count_and_get (x_count => x_message_count
2133: ,p_encoded => fnd_api.g_false
2134: ,x_data => x_message_list);
2135: x_return_status := fnd_api.g_ret_sts_unexp_error;
2136: END complete_batch;

Line 2141: := gme_common_pvt.g_max_errors

2137:
2138: /*************************************************************************/
2139: PROCEDURE complete_step (
2140: p_validation_level IN NUMBER
2141: := gme_common_pvt.g_max_errors
2142: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2143: ,x_message_count OUT NOCOPY NUMBER
2144: ,x_message_list OUT NOCOPY VARCHAR2
2145: ,x_return_status OUT NOCOPY VARCHAR2

Line 2149: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab

2145: ,x_return_status OUT NOCOPY VARCHAR2
2146: ,p_batch_step_rec IN gme_batch_steps%ROWTYPE
2147: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
2148: ,x_batch_step_rec OUT NOCOPY gme_batch_steps%ROWTYPE
2149: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab
2150: ,p_ignore_exception IN VARCHAR2 := NULL) --Bug#5186328
2151: IS
2152: l_api_name CONSTANT VARCHAR2 (30) := 'COMPLETE_STEP';
2153: setup_failure EXCEPTION;

Line 2168: IF NOT gme_common_pvt.g_setup_done THEN

2164: IF (g_debug IS NOT NULL) THEN
2165: gme_debug.log_initialize ('CompleteStep');
2166: END IF;
2167:
2168: IF NOT gme_common_pvt.g_setup_done THEN
2169: gme_common_pvt.g_setup_done :=
2170: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2171:
2172: IF NOT gme_common_pvt.g_setup_done THEN

Line 2169: gme_common_pvt.g_setup_done :=

2165: gme_debug.log_initialize ('CompleteStep');
2166: END IF;
2167:
2168: IF NOT gme_common_pvt.g_setup_done THEN
2169: gme_common_pvt.g_setup_done :=
2170: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2171:
2172: IF NOT gme_common_pvt.g_setup_done THEN
2173: x_return_status := fnd_api.g_ret_sts_error;

Line 2170: gme_common_pvt.setup (p_batch_header_rec.organization_id);

2166: END IF;
2167:
2168: IF NOT gme_common_pvt.g_setup_done THEN
2169: gme_common_pvt.g_setup_done :=
2170: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2171:
2172: IF NOT gme_common_pvt.g_setup_done THEN
2173: x_return_status := fnd_api.g_ret_sts_error;
2174: RAISE setup_failure;

Line 2172: IF NOT gme_common_pvt.g_setup_done THEN

2168: IF NOT gme_common_pvt.g_setup_done THEN
2169: gme_common_pvt.g_setup_done :=
2170: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2171:
2172: IF NOT gme_common_pvt.g_setup_done THEN
2173: x_return_status := fnd_api.g_ret_sts_error;
2174: RAISE setup_failure;
2175: END IF;
2176: END IF;

Line 2184: gme_common_pvt.g_error_count := 0;

2180:
2181: -- Initialize message list and count if needed
2182: IF p_init_msg_list = fnd_api.g_true THEN
2183: fnd_msg_pub.initialize;
2184: gme_common_pvt.g_error_count := 0;
2185: END IF;
2186:
2187: gme_common_pvt.set_timestamp;
2188: gme_complete_batch_step_pvt.complete_step

Line 2187: gme_common_pvt.set_timestamp;

2183: fnd_msg_pub.initialize;
2184: gme_common_pvt.g_error_count := 0;
2185: END IF;
2186:
2187: gme_common_pvt.set_timestamp;
2188: gme_complete_batch_step_pvt.complete_step
2189: (p_batch_step_rec => p_batch_step_rec
2190: ,p_batch_header_rec => p_batch_header_rec
2191: ,x_batch_step_rec => x_batch_step_rec

Line 2195: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN

2191: ,x_batch_step_rec => x_batch_step_rec
2192: ,x_exception_material_tbl => x_exception_material_tbl
2193: ,x_return_status => x_return_status);
2194:
2195: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
2196: RAISE step_complete_failure;
2197: END IF; /* IF x_return_status NOT IN */
2198:
2199:

Line 2202: x_return_status = gme_common_pvt.g_exceptions_err THEN

2198:
2199:
2200: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
2201: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
2202: x_return_status = gme_common_pvt.g_exceptions_err THEN
2203: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
2204: ELSE
2205: gme_common_pvt.log_message ('GME_API_STEP_COMPLETED');
2206: END IF;

Line 2203: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');

2199:
2200: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
2201: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
2202: x_return_status = gme_common_pvt.g_exceptions_err THEN
2203: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
2204: ELSE
2205: gme_common_pvt.log_message ('GME_API_STEP_COMPLETED');
2206: END IF;
2207:

Line 2205: gme_common_pvt.log_message ('GME_API_STEP_COMPLETED');

2201: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
2202: x_return_status = gme_common_pvt.g_exceptions_err THEN
2203: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
2204: ELSE
2205: gme_common_pvt.log_message ('GME_API_STEP_COMPLETED');
2206: END IF;
2207:
2208: gme_common_pvt.count_and_get (x_count => x_message_count
2209: ,p_encoded => fnd_api.g_false

Line 2208: gme_common_pvt.count_and_get (x_count => x_message_count

2204: ELSE
2205: gme_common_pvt.log_message ('GME_API_STEP_COMPLETED');
2206: END IF;
2207:
2208: gme_common_pvt.count_and_get (x_count => x_message_count
2209: ,p_encoded => fnd_api.g_false
2210: ,x_data => x_message_list);
2211:
2212: IF (g_debug IS NOT NULL) THEN

Line 2226: gme_common_pvt.count_and_get (x_count => x_message_count

2222: EXCEPTION
2223: WHEN step_complete_failure THEN
2224: ROLLBACK TO SAVEPOINT complete_step;
2225: x_batch_step_rec := NULL;
2226: gme_common_pvt.count_and_get (x_count => x_message_count
2227: ,p_encoded => fnd_api.g_false
2228: ,x_data => x_message_list);
2229: WHEN setup_failure THEN
2230: ROLLBACK TO SAVEPOINT complete_step;

Line 2232: gme_common_pvt.count_and_get (x_count => x_message_count

2228: ,x_data => x_message_list);
2229: WHEN setup_failure THEN
2230: ROLLBACK TO SAVEPOINT complete_step;
2231: x_batch_step_rec := NULL;
2232: gme_common_pvt.count_and_get (x_count => x_message_count
2233: ,p_encoded => fnd_api.g_false
2234: ,x_data => x_message_list);
2235: x_return_status := fnd_api.g_ret_sts_error;
2236: WHEN OTHERS THEN

Line 2248: gme_common_pvt.count_and_get (x_count => x_message_count

2244: END IF;
2245:
2246: ROLLBACK TO SAVEPOINT complete_step;
2247: x_batch_step_rec := NULL;
2248: gme_common_pvt.count_and_get (x_count => x_message_count
2249: ,p_encoded => fnd_api.g_false
2250: ,x_data => x_message_list);
2251: x_return_status := fnd_api.g_ret_sts_unexp_error;
2252: END complete_step;

Line 2257: := gme_common_pvt.g_max_errors

2253:
2254: /*************************************************************************/
2255: PROCEDURE delete_step (
2256: p_validation_level IN NUMBER
2257: := gme_common_pvt.g_max_errors
2258: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2259: ,x_message_count OUT NOCOPY NUMBER
2260: ,x_message_list OUT NOCOPY VARCHAR2
2261: ,x_return_status OUT NOCOPY VARCHAR2

Line 2286: IF NOT gme_common_pvt.g_setup_done THEN

2282:
2283: /* Set the return status to success initially */
2284: x_return_status := fnd_api.g_ret_sts_success;
2285:
2286: IF NOT gme_common_pvt.g_setup_done THEN
2287: gme_common_pvt.g_setup_done :=
2288: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2289:
2290: IF NOT gme_common_pvt.g_setup_done THEN

Line 2287: gme_common_pvt.g_setup_done :=

2283: /* Set the return status to success initially */
2284: x_return_status := fnd_api.g_ret_sts_success;
2285:
2286: IF NOT gme_common_pvt.g_setup_done THEN
2287: gme_common_pvt.g_setup_done :=
2288: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2289:
2290: IF NOT gme_common_pvt.g_setup_done THEN
2291: x_return_status := fnd_api.g_ret_sts_error;

Line 2288: gme_common_pvt.setup (p_batch_header_rec.organization_id);

2284: x_return_status := fnd_api.g_ret_sts_success;
2285:
2286: IF NOT gme_common_pvt.g_setup_done THEN
2287: gme_common_pvt.g_setup_done :=
2288: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2289:
2290: IF NOT gme_common_pvt.g_setup_done THEN
2291: x_return_status := fnd_api.g_ret_sts_error;
2292: RAISE setup_failure;

Line 2290: IF NOT gme_common_pvt.g_setup_done THEN

2286: IF NOT gme_common_pvt.g_setup_done THEN
2287: gme_common_pvt.g_setup_done :=
2288: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2289:
2290: IF NOT gme_common_pvt.g_setup_done THEN
2291: x_return_status := fnd_api.g_ret_sts_error;
2292: RAISE setup_failure;
2293: END IF;
2294: END IF;

Line 2298: gme_common_pvt.g_error_count := 0;

2294: END IF;
2295: /* Initialize message list and count if needed */
2296: IF p_init_msg_list = fnd_api.g_true THEN
2297: fnd_msg_pub.initialize;
2298: gme_common_pvt.g_error_count := 0;
2299: END IF;
2300:
2301: /* Punit Kumar */
2302: gme_common_pvt.set_timestamp;

Line 2302: gme_common_pvt.set_timestamp;

2298: gme_common_pvt.g_error_count := 0;
2299: END IF;
2300:
2301: /* Punit Kumar */
2302: gme_common_pvt.set_timestamp;
2303: gme_delete_batch_step_pvt.delete_step
2304: (x_return_status => x_return_status
2305: ,p_batch_step_rec => p_batch_step_rec
2306: ,p_reroute_flag => FALSE);

Line 2314: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHSTEP_REMOVED

2310: ELSE
2311: RAISE delete_step_failed;
2312: END IF;
2313: -- NEW
2314: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHSTEP_REMOVED
2315: ,P_EVENT_KEY => p_batch_step_rec.batch_id||'-'||p_batch_step_rec.BATCHSTEP_id
2316: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_STEP_LABEL')
2317: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
2318: '-'||p_batch_header_rec.batch_no||'-'|| p_batch_step_rec.BATCHSTEP_NO

Line 2317: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||

2313: -- NEW
2314: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHSTEP_REMOVED
2315: ,P_EVENT_KEY => p_batch_step_rec.batch_id||'-'||p_batch_step_rec.BATCHSTEP_id
2316: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_STEP_LABEL')
2317: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
2318: '-'||p_batch_header_rec.batch_no||'-'|| p_batch_step_rec.BATCHSTEP_NO
2319: ||'-'||GME_ERES_PKG.GET_OPRN_NO(p_batch_step_rec.OPRN_ID)
2320: ,P_POST_OP_API => 'NONE'
2321: ,P_PARENT_EVENT => NULL

Line 2331: gme_common_pvt.log_message ('GME_API_STEP_DELETE');

2327: END IF;
2328:
2329:
2330:
2331: gme_common_pvt.log_message ('GME_API_STEP_DELETE');
2332:
2333:
2334: IF (g_debug <= gme_debug.g_log_procedure) THEN
2335: gme_debug.put_line ( 'Completed '

Line 2341: gme_common_pvt.count_and_get (x_count => x_message_count

2337: || ' at '
2338: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
2339: END IF;
2340:
2341: gme_common_pvt.count_and_get (x_count => x_message_count
2342: ,p_encoded => fnd_api.g_false
2343: ,x_data => x_message_list);
2344: EXCEPTION
2345: WHEN setup_failure THEN

Line 2348: gme_common_pvt.count_and_get (x_count => x_message_count

2344: EXCEPTION
2345: WHEN setup_failure THEN
2346: ROLLBACK TO SAVEPOINT delete_step;
2347: x_return_status := fnd_api.g_ret_sts_error;
2348: gme_common_pvt.count_and_get (x_count => x_message_count
2349: ,p_encoded => fnd_api.g_false
2350: ,x_data => x_message_list);
2351: WHEN delete_step_failed OR batch_save_failed THEN
2352: ROLLBACK TO SAVEPOINT delete_step;

Line 2353: gme_common_pvt.count_and_get (x_count => x_message_count

2349: ,p_encoded => fnd_api.g_false
2350: ,x_data => x_message_list);
2351: WHEN delete_step_failed OR batch_save_failed THEN
2352: ROLLBACK TO SAVEPOINT delete_step;
2353: gme_common_pvt.count_and_get (x_count => x_message_count
2354: ,p_encoded => fnd_api.g_false
2355: ,x_data => x_message_list);
2356: WHEN OTHERS THEN
2357: ROLLBACK TO SAVEPOINT delete_step;

Line 2359: gme_common_pvt.count_and_get (x_count => x_message_count

2355: ,x_data => x_message_list);
2356: WHEN OTHERS THEN
2357: ROLLBACK TO SAVEPOINT delete_step;
2358: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2359: gme_common_pvt.count_and_get (x_count => x_message_count
2360: ,p_encoded => fnd_api.g_false
2361: ,x_data => x_message_list);
2362: x_return_status := fnd_api.g_ret_sts_unexp_error;
2363: END delete_step;

Line 2373: := gme_common_pvt.g_max_errors

2369: Punit Kumar 07-Apr-2005 Convergence Changes
2370: /*************************************************************************/
2371: PROCEDURE insert_step (
2372: p_validation_level IN NUMBER
2373: := gme_common_pvt.g_max_errors
2374: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2375: ,x_message_count OUT NOCOPY NUMBER
2376: ,x_message_list OUT NOCOPY VARCHAR2
2377: ,x_return_status OUT NOCOPY VARCHAR2

Line 2410: IF NOT gme_common_pvt.g_setup_done THEN

2406:
2407: /* Set the return status to success initially */
2408: x_return_status := fnd_api.g_ret_sts_success;
2409:
2410: IF NOT gme_common_pvt.g_setup_done THEN
2411: gme_common_pvt.g_setup_done :=
2412: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2413:
2414: IF NOT gme_common_pvt.g_setup_done THEN

Line 2411: gme_common_pvt.g_setup_done :=

2407: /* Set the return status to success initially */
2408: x_return_status := fnd_api.g_ret_sts_success;
2409:
2410: IF NOT gme_common_pvt.g_setup_done THEN
2411: gme_common_pvt.g_setup_done :=
2412: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2413:
2414: IF NOT gme_common_pvt.g_setup_done THEN
2415: x_return_status := fnd_api.g_ret_sts_error;

Line 2412: gme_common_pvt.setup (p_batch_header_rec.organization_id);

2408: x_return_status := fnd_api.g_ret_sts_success;
2409:
2410: IF NOT gme_common_pvt.g_setup_done THEN
2411: gme_common_pvt.g_setup_done :=
2412: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2413:
2414: IF NOT gme_common_pvt.g_setup_done THEN
2415: x_return_status := fnd_api.g_ret_sts_error;
2416: RAISE setup_failure;

Line 2414: IF NOT gme_common_pvt.g_setup_done THEN

2410: IF NOT gme_common_pvt.g_setup_done THEN
2411: gme_common_pvt.g_setup_done :=
2412: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2413:
2414: IF NOT gme_common_pvt.g_setup_done THEN
2415: x_return_status := fnd_api.g_ret_sts_error;
2416: RAISE setup_failure;
2417: END IF;
2418: END IF;

Line 2421: gme_common_pvt.g_error_count := 0;

2417: END IF;
2418: END IF;
2419: IF p_init_msg_list = fnd_api.g_true THEN
2420: fnd_msg_pub.initialize;
2421: gme_common_pvt.g_error_count := 0;
2422: END IF;
2423:
2424: /* Punit Kumar */
2425: gme_common_pvt.set_timestamp;

Line 2425: gme_common_pvt.set_timestamp;

2421: gme_common_pvt.g_error_count := 0;
2422: END IF;
2423:
2424: /* Punit Kumar */
2425: gme_common_pvt.set_timestamp;
2426: gme_insert_step_pvt.insert_batch_step
2427: (p_gme_batch_header => p_batch_header_rec
2428: ,p_gme_batch_step => p_batch_step_rec
2429: ,x_gme_batch_step => x_batch_step

Line 2453: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHSTEP_ADDED

2449: END IF;
2450: -- End Bug 5903208
2451:
2452: -- NEW
2453: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHSTEP_ADDED
2454: ,P_EVENT_KEY => x_batch_step.batch_id||'-'||x_batch_step.BATCHSTEP_id
2455: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_STEP_LABEL')
2456: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
2457: '-'||p_batch_header_rec.batch_no||'-'|| x_batch_step.BATCHSTEP_NO

Line 2456: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||

2452: -- NEW
2453: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHSTEP_ADDED
2454: ,P_EVENT_KEY => x_batch_step.batch_id||'-'||x_batch_step.BATCHSTEP_id
2455: ,P_USER_KEY_LABEL => FND_MESSAGE.GET_STRING('GME','GME_PSIG_BATCH_STEP_LABEL')
2456: ,P_USER_KEY_VALUE => gme_common_pvt.g_organization_code ||
2457: '-'||p_batch_header_rec.batch_no||'-'|| x_batch_step.BATCHSTEP_NO
2458: ||'-'||GME_ERES_PKG.GET_OPRN_NO(x_batch_step.OPRN_ID)
2459: ,P_POST_OP_API => 'NONE'
2460: ,P_PARENT_EVENT => NULL

Line 2467: gme_common_pvt.log_message ('GME_INSERT_STEP');

2463: ,X_STATUS => x_return_status);
2464: IF x_return_status <> fnd_api.g_ret_sts_success THEN
2465: RAISE insert_step_failed;
2466: END IF;
2467: gme_common_pvt.log_message ('GME_INSERT_STEP');
2468: IF (g_debug <= gme_debug.g_log_procedure) THEN
2469: gme_debug.put_line ( 'Completed '
2470: || l_api_name
2471: || ' at '

Line 2483: gme_common_pvt.count_and_get (x_count => x_message_count

2479: WHEN setup_failure THEN
2480: ROLLBACK TO SAVEPOINT insert_step;
2481: x_batch_step := NULL;
2482: x_return_status := fnd_api.g_ret_sts_error;
2483: gme_common_pvt.count_and_get (x_count => x_message_count
2484: ,p_encoded => fnd_api.g_false
2485: ,x_data => x_message_list);
2486: WHEN insert_step_failed OR batch_save_failed THEN
2487: ROLLBACK TO SAVEPOINT insert_step;

Line 2489: gme_common_pvt.count_and_get (x_count => x_message_count

2485: ,x_data => x_message_list);
2486: WHEN insert_step_failed OR batch_save_failed THEN
2487: ROLLBACK TO SAVEPOINT insert_step;
2488: x_batch_step := NULL;
2489: gme_common_pvt.count_and_get (x_count => x_message_count
2490: ,p_encoded => fnd_api.g_false
2491: ,x_data => x_message_list);
2492: WHEN OTHERS THEN
2493: ROLLBACK TO SAVEPOINT insert_step;

Line 2496: gme_common_pvt.count_and_get (x_count => x_message_count

2492: WHEN OTHERS THEN
2493: ROLLBACK TO SAVEPOINT insert_step;
2494: x_batch_step := NULL;
2495: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2496: gme_common_pvt.count_and_get (x_count => x_message_count
2497: ,p_encoded => fnd_api.g_false
2498: ,x_data => x_message_list);
2499: x_return_status := fnd_api.g_ret_sts_unexp_error;
2500: END insert_step;

Line 2504: p_validation_level IN NUMBER := gme_common_pvt.g_max_errors

2500: END insert_step;
2501:
2502:
2503: PROCEDURE revert_batch (
2504: p_validation_level IN NUMBER := gme_common_pvt.g_max_errors
2505: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
2506: ,x_message_count OUT NOCOPY NUMBER
2507: ,x_message_list OUT NOCOPY VARCHAR2
2508: ,x_return_status OUT NOCOPY VARCHAR2

Line 2533: IF NOT gme_common_pvt.g_setup_done THEN

2529:
2530: /* Set the return status to success initially */
2531: x_return_status := fnd_api.g_ret_sts_success;
2532:
2533: IF NOT gme_common_pvt.g_setup_done THEN
2534: gme_common_pvt.g_setup_done :=
2535: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2536:
2537: IF NOT gme_common_pvt.g_setup_done THEN

Line 2534: gme_common_pvt.g_setup_done :=

2530: /* Set the return status to success initially */
2531: x_return_status := fnd_api.g_ret_sts_success;
2532:
2533: IF NOT gme_common_pvt.g_setup_done THEN
2534: gme_common_pvt.g_setup_done :=
2535: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2536:
2537: IF NOT gme_common_pvt.g_setup_done THEN
2538: x_return_status := fnd_api.g_ret_sts_error;

Line 2535: gme_common_pvt.setup (p_batch_header_rec.organization_id);

2531: x_return_status := fnd_api.g_ret_sts_success;
2532:
2533: IF NOT gme_common_pvt.g_setup_done THEN
2534: gme_common_pvt.g_setup_done :=
2535: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2536:
2537: IF NOT gme_common_pvt.g_setup_done THEN
2538: x_return_status := fnd_api.g_ret_sts_error;
2539: RAISE setup_failure;

Line 2537: IF NOT gme_common_pvt.g_setup_done THEN

2533: IF NOT gme_common_pvt.g_setup_done THEN
2534: gme_common_pvt.g_setup_done :=
2535: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2536:
2537: IF NOT gme_common_pvt.g_setup_done THEN
2538: x_return_status := fnd_api.g_ret_sts_error;
2539: RAISE setup_failure;
2540: END IF;
2541: END IF;

Line 2546: gme_common_pvt.g_error_count := 0;

2542:
2543: -- Initialize message list and count if needed
2544: IF p_init_msg_list = fnd_api.g_true THEN
2545: fnd_msg_pub.initialize;
2546: gme_common_pvt.g_error_count := 0;
2547: END IF;
2548:
2549: gme_common_pvt.set_timestamp;
2550:

Line 2549: gme_common_pvt.set_timestamp;

2545: fnd_msg_pub.initialize;
2546: gme_common_pvt.g_error_count := 0;
2547: END IF;
2548:
2549: gme_common_pvt.set_timestamp;
2550:
2551: IF g_debug <= gme_debug.g_log_statement THEN
2552: gme_debug.put_line ( g_pkg_name
2553: || '.'

Line 2578: gme_common_pvt.log_message ('GME_API_BATCH_UNCERTIFIED');

2574: RAISE batch_revert_failure;
2575: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
2576:
2577:
2578: gme_common_pvt.log_message ('GME_API_BATCH_UNCERTIFIED');
2579:
2580:
2581: gme_common_pvt.count_and_get (x_count => x_message_count,
2582: p_encoded => fnd_api.g_false,

Line 2581: gme_common_pvt.count_and_get (x_count => x_message_count,

2577:
2578: gme_common_pvt.log_message ('GME_API_BATCH_UNCERTIFIED');
2579:
2580:
2581: gme_common_pvt.count_and_get (x_count => x_message_count,
2582: p_encoded => fnd_api.g_false,
2583: x_data => x_message_list);
2584:
2585: IF (g_debug IS NOT NULL) THEN

Line 2603: gme_common_pvt.count_and_get (x_count => x_message_count,

2599: EXCEPTION
2600: WHEN batch_revert_failure THEN
2601: ROLLBACK TO SAVEPOINT revert_batch;
2602: x_batch_header_rec := NULL;
2603: gme_common_pvt.count_and_get (x_count => x_message_count,
2604: p_encoded => fnd_api.g_false,
2605: x_data => x_message_list);
2606: WHEN setup_failure THEN
2607: ROLLBACK TO SAVEPOINT revert_batch;

Line 2609: gme_common_pvt.count_and_get (x_count => x_message_count,

2605: x_data => x_message_list);
2606: WHEN setup_failure THEN
2607: ROLLBACK TO SAVEPOINT revert_batch;
2608: x_batch_header_rec := NULL;
2609: gme_common_pvt.count_and_get (x_count => x_message_count,
2610: p_encoded => fnd_api.g_false,
2611: x_data => x_message_list);
2612: x_return_status := fnd_api.g_ret_sts_error;
2613: WHEN OTHERS THEN

Line 2625: gme_common_pvt.count_and_get (x_count => x_message_count,

2621: END IF;
2622:
2623: ROLLBACK TO SAVEPOINT revert_batch;
2624: x_batch_header_rec := NULL;
2625: gme_common_pvt.count_and_get (x_count => x_message_count,
2626: p_encoded => fnd_api.g_false,
2627: x_data => x_message_list);
2628: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2629:

Line 2634: p_validation_level IN NUMBER := gme_common_pvt.g_max_errors

2630:
2631: END revert_batch;
2632:
2633: PROCEDURE revert_step (
2634: p_validation_level IN NUMBER := gme_common_pvt.g_max_errors
2635: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
2636: ,x_message_count OUT NOCOPY NUMBER
2637: ,x_message_list OUT NOCOPY VARCHAR2
2638: ,x_return_status OUT NOCOPY VARCHAR2

Line 2664: IF NOT gme_common_pvt.g_setup_done THEN

2660:
2661: /* Set the return status to success initially */
2662: x_return_status := fnd_api.g_ret_sts_success;
2663:
2664: IF NOT gme_common_pvt.g_setup_done THEN
2665: gme_common_pvt.g_setup_done :=
2666: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2667:
2668: IF NOT gme_common_pvt.g_setup_done THEN

Line 2665: gme_common_pvt.g_setup_done :=

2661: /* Set the return status to success initially */
2662: x_return_status := fnd_api.g_ret_sts_success;
2663:
2664: IF NOT gme_common_pvt.g_setup_done THEN
2665: gme_common_pvt.g_setup_done :=
2666: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2667:
2668: IF NOT gme_common_pvt.g_setup_done THEN
2669: x_return_status := fnd_api.g_ret_sts_error;

Line 2666: gme_common_pvt.setup (p_batch_header_rec.organization_id);

2662: x_return_status := fnd_api.g_ret_sts_success;
2663:
2664: IF NOT gme_common_pvt.g_setup_done THEN
2665: gme_common_pvt.g_setup_done :=
2666: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2667:
2668: IF NOT gme_common_pvt.g_setup_done THEN
2669: x_return_status := fnd_api.g_ret_sts_error;
2670: RAISE setup_failure;

Line 2668: IF NOT gme_common_pvt.g_setup_done THEN

2664: IF NOT gme_common_pvt.g_setup_done THEN
2665: gme_common_pvt.g_setup_done :=
2666: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2667:
2668: IF NOT gme_common_pvt.g_setup_done THEN
2669: x_return_status := fnd_api.g_ret_sts_error;
2670: RAISE setup_failure;
2671: END IF;
2672: END IF;

Line 2677: gme_common_pvt.g_error_count := 0;

2673:
2674: -- Initialize message list and count if needed
2675: IF p_init_msg_list = fnd_api.g_true THEN
2676: fnd_msg_pub.initialize;
2677: gme_common_pvt.g_error_count := 0;
2678: END IF;
2679:
2680: gme_common_pvt.set_timestamp;
2681:

Line 2680: gme_common_pvt.set_timestamp;

2676: fnd_msg_pub.initialize;
2677: gme_common_pvt.g_error_count := 0;
2678: END IF;
2679:
2680: gme_common_pvt.set_timestamp;
2681:
2682: IF g_debug <= gme_debug.g_log_statement THEN
2683: gme_debug.put_line ( g_pkg_name
2684: || '.'

Line 2710: gme_common_pvt.log_message ('GME_BATCH_STEP_UNCERTIFIED');

2706: RAISE step_revert_failure;
2707: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
2708:
2709:
2710: gme_common_pvt.log_message ('GME_BATCH_STEP_UNCERTIFIED');
2711:
2712:
2713: gme_common_pvt.count_and_get (x_count => x_message_count,
2714: p_encoded => fnd_api.g_false,

Line 2713: gme_common_pvt.count_and_get (x_count => x_message_count,

2709:
2710: gme_common_pvt.log_message ('GME_BATCH_STEP_UNCERTIFIED');
2711:
2712:
2713: gme_common_pvt.count_and_get (x_count => x_message_count,
2714: p_encoded => fnd_api.g_false,
2715: x_data => x_message_list);
2716:
2717: IF (g_debug IS NOT NULL) THEN

Line 2735: gme_common_pvt.count_and_get (x_count => x_message_count,

2731: EXCEPTION
2732: WHEN step_revert_failure THEN
2733: ROLLBACK TO SAVEPOINT revert_step;
2734: x_batch_step_rec := NULL;
2735: gme_common_pvt.count_and_get (x_count => x_message_count,
2736: p_encoded => fnd_api.g_false,
2737: x_data => x_message_list);
2738: WHEN setup_failure THEN
2739: ROLLBACK TO SAVEPOINT revert_step;

Line 2741: gme_common_pvt.count_and_get (x_count => x_message_count,

2737: x_data => x_message_list);
2738: WHEN setup_failure THEN
2739: ROLLBACK TO SAVEPOINT revert_step;
2740: x_batch_step_rec := NULL;
2741: gme_common_pvt.count_and_get (x_count => x_message_count,
2742: p_encoded => fnd_api.g_false,
2743: x_data => x_message_list);
2744: x_return_status := fnd_api.g_ret_sts_error;
2745: WHEN OTHERS THEN

Line 2757: gme_common_pvt.count_and_get (x_count => x_message_count,

2753: END IF;
2754:
2755: ROLLBACK TO SAVEPOINT revert_step;
2756: x_batch_step_rec := NULL;
2757: gme_common_pvt.count_and_get (x_count => x_message_count,
2758: p_encoded => fnd_api.g_false,
2759: x_data => x_message_list);
2760: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2761: END revert_step;

Line 2789: IF NOT gme_common_pvt.g_setup_done THEN

2785: IF (g_debug IS NOT NULL) THEN
2786: gme_debug.log_initialize ('CloseBatch');
2787: END IF;
2788:
2789: IF NOT gme_common_pvt.g_setup_done THEN
2790: gme_common_pvt.g_setup_done :=
2791: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2792:
2793: IF NOT gme_common_pvt.g_setup_done THEN

Line 2790: gme_common_pvt.g_setup_done :=

2786: gme_debug.log_initialize ('CloseBatch');
2787: END IF;
2788:
2789: IF NOT gme_common_pvt.g_setup_done THEN
2790: gme_common_pvt.g_setup_done :=
2791: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2792:
2793: IF NOT gme_common_pvt.g_setup_done THEN
2794: x_return_status := fnd_api.g_ret_sts_error;

Line 2791: gme_common_pvt.setup (p_batch_header_rec.organization_id);

2787: END IF;
2788:
2789: IF NOT gme_common_pvt.g_setup_done THEN
2790: gme_common_pvt.g_setup_done :=
2791: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2792:
2793: IF NOT gme_common_pvt.g_setup_done THEN
2794: x_return_status := fnd_api.g_ret_sts_error;
2795: RAISE setup_failure;

Line 2793: IF NOT gme_common_pvt.g_setup_done THEN

2789: IF NOT gme_common_pvt.g_setup_done THEN
2790: gme_common_pvt.g_setup_done :=
2791: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2792:
2793: IF NOT gme_common_pvt.g_setup_done THEN
2794: x_return_status := fnd_api.g_ret_sts_error;
2795: RAISE setup_failure;
2796: END IF;
2797: END IF;

Line 2802: gme_common_pvt.g_error_count := 0;

2798:
2799: /* Initialize message list and count if needed */
2800: IF p_init_msg_list = fnd_api.g_true THEN
2801: fnd_msg_pub.initialize;
2802: gme_common_pvt.g_error_count := 0;
2803: END IF;
2804:
2805: gme_common_pvt.set_timestamp;
2806:

Line 2805: gme_common_pvt.set_timestamp;

2801: fnd_msg_pub.initialize;
2802: gme_common_pvt.g_error_count := 0;
2803: END IF;
2804:
2805: gme_common_pvt.set_timestamp;
2806:
2807: IF g_debug <= gme_debug.g_log_procedure THEN
2808: gme_debug.put_line ('Calling gme_close_batch_pvt.close_batch.');
2809: END IF;

Line 2837: gme_common_pvt.log_message ('GME_API_BATCH_CLOSED');

2833: RAISE batch_close_failure;
2834: END IF;
2835:
2836:
2837: gme_common_pvt.log_message ('GME_API_BATCH_CLOSED');
2838:
2839:
2840: gme_common_pvt.count_and_get (x_count => x_message_count
2841: ,p_encoded => fnd_api.g_false

Line 2840: gme_common_pvt.count_and_get (x_count => x_message_count

2836:
2837: gme_common_pvt.log_message ('GME_API_BATCH_CLOSED');
2838:
2839:
2840: gme_common_pvt.count_and_get (x_count => x_message_count
2841: ,p_encoded => fnd_api.g_false
2842: ,x_data => x_message_list);
2843:
2844: IF g_debug <= gme_debug.g_log_procedure THEN

Line 2854: gme_common_pvt.count_and_get (x_count => x_message_count

2850: EXCEPTION
2851: WHEN setup_failure OR batch_close_failure OR batch_save_failed THEN
2852: ROLLBACK TO SAVEPOINT close_batch;
2853: x_batch_header_rec := NULL;
2854: gme_common_pvt.count_and_get (x_count => x_message_count
2855: ,p_encoded => fnd_api.g_false
2856: ,x_data => x_message_list);
2857: WHEN OTHERS THEN
2858: ROLLBACK TO SAVEPOINT close_batch;

Line 2861: gme_common_pvt.count_and_get (x_count => x_message_count

2857: WHEN OTHERS THEN
2858: ROLLBACK TO SAVEPOINT close_batch;
2859: x_batch_header_rec := NULL;
2860: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2861: gme_common_pvt.count_and_get (x_count => x_message_count
2862: ,p_encoded => fnd_api.g_false
2863: ,x_data => x_message_list);
2864: x_return_status := fnd_api.g_ret_sts_unexp_error;
2865: END close_batch;

Line 2870: := gme_common_pvt.g_max_errors

2866:
2867: /*************************************************************************/
2868: PROCEDURE close_step (
2869: p_validation_level IN NUMBER
2870: := gme_common_pvt.g_max_errors
2871: , /* Punit Kumar */
2872: p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2873: ,x_message_count OUT NOCOPY NUMBER
2874: ,x_message_list OUT NOCOPY VARCHAR2

Line 2902: IF NOT gme_common_pvt.g_setup_done THEN

2898:
2899: /* Set the return status to success initially */
2900: x_return_status := fnd_api.g_ret_sts_success;
2901:
2902: IF NOT gme_common_pvt.g_setup_done THEN
2903: gme_common_pvt.g_setup_done :=
2904: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2905:
2906: IF NOT gme_common_pvt.g_setup_done THEN

Line 2903: gme_common_pvt.g_setup_done :=

2899: /* Set the return status to success initially */
2900: x_return_status := fnd_api.g_ret_sts_success;
2901:
2902: IF NOT gme_common_pvt.g_setup_done THEN
2903: gme_common_pvt.g_setup_done :=
2904: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2905:
2906: IF NOT gme_common_pvt.g_setup_done THEN
2907: x_return_status := fnd_api.g_ret_sts_error;

Line 2904: gme_common_pvt.setup (p_batch_header_rec.organization_id);

2900: x_return_status := fnd_api.g_ret_sts_success;
2901:
2902: IF NOT gme_common_pvt.g_setup_done THEN
2903: gme_common_pvt.g_setup_done :=
2904: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2905:
2906: IF NOT gme_common_pvt.g_setup_done THEN
2907: x_return_status := fnd_api.g_ret_sts_error;
2908: RAISE setup_failure;

Line 2906: IF NOT gme_common_pvt.g_setup_done THEN

2902: IF NOT gme_common_pvt.g_setup_done THEN
2903: gme_common_pvt.g_setup_done :=
2904: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2905:
2906: IF NOT gme_common_pvt.g_setup_done THEN
2907: x_return_status := fnd_api.g_ret_sts_error;
2908: RAISE setup_failure;
2909: END IF;
2910: END IF;

Line 2914: gme_common_pvt.g_error_count := 0;

2910: END IF;
2911: /* Initialize message list and count if needed */
2912: IF p_init_msg_list = fnd_api.g_true THEN
2913: fnd_msg_pub.initialize;
2914: gme_common_pvt.g_error_count := 0;
2915: END IF;
2916:
2917: gme_common_pvt.set_timestamp;
2918:

Line 2917: gme_common_pvt.set_timestamp;

2913: fnd_msg_pub.initialize;
2914: gme_common_pvt.g_error_count := 0;
2915: END IF;
2916:
2917: gme_common_pvt.set_timestamp;
2918:
2919: gme_close_step_pvt.close_step (p_batch_step_rec => p_batch_step_rec
2920: ,p_delete_pending => p_delete_pending
2921: ,x_batch_step_rec => x_batch_step_rec

Line 2938: gme_common_pvt.log_message ('GME_BATCH_STEP_CLOSED');

2934: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
2935: END IF;
2936:
2937:
2938: gme_common_pvt.log_message ('GME_BATCH_STEP_CLOSED');
2939:
2940:
2941: gme_common_pvt.count_and_get (x_count => x_message_count
2942: ,p_encoded => fnd_api.g_false

Line 2941: gme_common_pvt.count_and_get (x_count => x_message_count

2937:
2938: gme_common_pvt.log_message ('GME_BATCH_STEP_CLOSED');
2939:
2940:
2941: gme_common_pvt.count_and_get (x_count => x_message_count
2942: ,p_encoded => fnd_api.g_false
2943: ,x_data => x_message_list);
2944: EXCEPTION
2945: WHEN setup_failure OR step_close_failed OR batch_save_failed THEN

Line 2949: gme_common_pvt.count_and_get (x_count => x_message_count

2945: WHEN setup_failure OR step_close_failed OR batch_save_failed THEN
2946: ROLLBACK TO SAVEPOINT close_batch_step;
2947: x_batch_step_rec := NULL;
2948: /*N Punit Kumar */
2949: gme_common_pvt.count_and_get (x_count => x_message_count
2950: ,p_encoded => fnd_api.g_false
2951: ,x_data => x_message_list);
2952: WHEN OTHERS THEN
2953: ROLLBACK TO SAVEPOINT close_batch_step;

Line 2957: gme_common_pvt.count_and_get (x_count => x_message_count

2953: ROLLBACK TO SAVEPOINT close_batch_step;
2954: x_batch_step_rec := NULL;
2955: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2956: /*N Punit Kumar */
2957: gme_common_pvt.count_and_get (x_count => x_message_count
2958: ,p_encoded => fnd_api.g_false
2959: ,x_data => x_message_list);
2960: x_return_status := fnd_api.g_ret_sts_unexp_error;
2961: END close_step;

Line 2966: := gme_common_pvt.g_max_errors

2962:
2963: /*************************************************************************/
2964: PROCEDURE reopen_batch (
2965: p_validation_level IN NUMBER
2966: := gme_common_pvt.g_max_errors
2967: ,
2968: p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2969: ,x_message_count OUT NOCOPY NUMBER
2970: ,x_message_list OUT NOCOPY VARCHAR2

Line 2996: gme_common_pvt.g_error_count := 0;

2992:
2993: /* Initialize message list and count if needed*/
2994: IF p_init_msg_list = fnd_api.g_true THEN
2995: fnd_msg_pub.initialize;
2996: gme_common_pvt.g_error_count := 0;
2997: END IF;
2998:
2999: /* Set the success staus to success inititally*/
3000: x_return_status := fnd_api.g_ret_sts_success;

Line 3003: IF NOT gme_common_pvt.g_setup_done THEN

2999: /* Set the success staus to success inititally*/
3000: x_return_status := fnd_api.g_ret_sts_success;
3001:
3002: -- Pawan kumar added for bug 4956087
3003: IF NOT gme_common_pvt.g_setup_done THEN
3004: gme_common_pvt.g_setup_done :=
3005: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3006:
3007: IF NOT gme_common_pvt.g_setup_done THEN

Line 3004: gme_common_pvt.g_setup_done :=

3000: x_return_status := fnd_api.g_ret_sts_success;
3001:
3002: -- Pawan kumar added for bug 4956087
3003: IF NOT gme_common_pvt.g_setup_done THEN
3004: gme_common_pvt.g_setup_done :=
3005: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3006:
3007: IF NOT gme_common_pvt.g_setup_done THEN
3008: x_return_status := fnd_api.g_ret_sts_error;

Line 3005: gme_common_pvt.setup (p_batch_header_rec.organization_id);

3001:
3002: -- Pawan kumar added for bug 4956087
3003: IF NOT gme_common_pvt.g_setup_done THEN
3004: gme_common_pvt.g_setup_done :=
3005: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3006:
3007: IF NOT gme_common_pvt.g_setup_done THEN
3008: x_return_status := fnd_api.g_ret_sts_error;
3009: RAISE setup_failure;

Line 3007: IF NOT gme_common_pvt.g_setup_done THEN

3003: IF NOT gme_common_pvt.g_setup_done THEN
3004: gme_common_pvt.g_setup_done :=
3005: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3006:
3007: IF NOT gme_common_pvt.g_setup_done THEN
3008: x_return_status := fnd_api.g_ret_sts_error;
3009: RAISE setup_failure;
3010: END IF;
3011: END IF;

Line 3012: gme_common_pvt.set_timestamp;

3008: x_return_status := fnd_api.g_ret_sts_error;
3009: RAISE setup_failure;
3010: END IF;
3011: END IF;
3012: gme_common_pvt.set_timestamp;
3013:
3014: IF (g_debug <= gme_debug.g_log_procedure) THEN
3015: gme_debug.put_line (g_pkg_name || '.' || l_api_name || ':'
3016: || 'calling private layer');

Line 3036: gme_common_pvt.log_message ('GME_API_BATCH_REOPENED');

3032: ELSE
3033: RAISE batch_reopen_failure;
3034: END IF;
3035:
3036: gme_common_pvt.log_message ('GME_API_BATCH_REOPENED');
3037:
3038:
3039: IF (g_debug <= gme_debug.g_log_procedure) THEN
3040: gme_debug.put_line ( 'Completed '

Line 3047: gme_common_pvt.count_and_get (x_count => x_message_count

3043: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
3044: END IF;
3045:
3046:
3047: gme_common_pvt.count_and_get (x_count => x_message_count
3048: ,p_encoded => fnd_api.g_false
3049: ,x_data => x_message_list);
3050:
3051:

Line 3065: gme_common_pvt.count_and_get (x_count => x_message_count

3061: END IF;
3062:
3063: x_return_status := fnd_api.g_ret_sts_error;
3064: /*N Punit Kumar */
3065: gme_common_pvt.count_and_get (x_count => x_message_count
3066: ,p_encoded => fnd_api.g_false
3067: ,x_data => x_message_list);
3068: WHEN batch_reopen_failure OR batch_save_failed THEN
3069: ROLLBACK TO SAVEPOINT reopen_batch;

Line 3079: gme_common_pvt.count_and_get (x_count => x_message_count

3075: );
3076: END IF;
3077:
3078: /*N Punit Kumar */
3079: gme_common_pvt.count_and_get (x_count => x_message_count
3080: ,p_encoded => fnd_api.g_false
3081: ,x_data => x_message_list);
3082: x_return_status := fnd_api.g_ret_sts_error;
3083: WHEN OTHERS THEN

Line 3095: gme_common_pvt.count_and_get (x_count => x_message_count

3091: END IF;
3092:
3093: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3094:
3095: gme_common_pvt.count_and_get (x_count => x_message_count
3096: ,p_encoded => fnd_api.g_false
3097: ,x_data => x_message_list);
3098: x_return_status := fnd_api.g_ret_sts_unexp_error;
3099: END reopen_batch;

Line 3104: := gme_common_pvt.g_max_errors

3100:
3101: /*************************************************************************/
3102: PROCEDURE reopen_step (
3103: p_validation_level IN NUMBER
3104: := gme_common_pvt.g_max_errors
3105: , /* Punit Kumar */
3106: p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3107: ,x_message_count OUT NOCOPY NUMBER
3108: ,x_message_list OUT NOCOPY VARCHAR2

Line 3126: gme_common_pvt.g_error_count := 0; /* Punit Kumar */

3122:
3123: /* Initialize message list and count if needed*/
3124: IF p_init_msg_list = fnd_api.g_true THEN
3125: fnd_msg_pub.initialize;
3126: gme_common_pvt.g_error_count := 0; /* Punit Kumar */
3127: END IF;
3128:
3129: IF (g_debug IS NOT NULL) THEN
3130: gme_debug.log_initialize ('ReopenStep');

Line 3137: IF NOT gme_common_pvt.g_setup_done THEN

3133: IF (g_debug <= gme_debug.g_log_procedure) THEN
3134: gme_debug.put_line (g_pkg_name || '.' || l_api_name || ':'
3135: || 'entering');
3136: END IF;
3137: IF NOT gme_common_pvt.g_setup_done THEN
3138: gme_common_pvt.g_setup_done :=
3139: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3140:
3141: IF NOT gme_common_pvt.g_setup_done THEN

Line 3138: gme_common_pvt.g_setup_done :=

3134: gme_debug.put_line (g_pkg_name || '.' || l_api_name || ':'
3135: || 'entering');
3136: END IF;
3137: IF NOT gme_common_pvt.g_setup_done THEN
3138: gme_common_pvt.g_setup_done :=
3139: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3140:
3141: IF NOT gme_common_pvt.g_setup_done THEN
3142: x_return_status := fnd_api.g_ret_sts_error;

Line 3139: gme_common_pvt.setup (p_batch_header_rec.organization_id);

3135: || 'entering');
3136: END IF;
3137: IF NOT gme_common_pvt.g_setup_done THEN
3138: gme_common_pvt.g_setup_done :=
3139: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3140:
3141: IF NOT gme_common_pvt.g_setup_done THEN
3142: x_return_status := fnd_api.g_ret_sts_error;
3143: RAISE setup_failure;

Line 3141: IF NOT gme_common_pvt.g_setup_done THEN

3137: IF NOT gme_common_pvt.g_setup_done THEN
3138: gme_common_pvt.g_setup_done :=
3139: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3140:
3141: IF NOT gme_common_pvt.g_setup_done THEN
3142: x_return_status := fnd_api.g_ret_sts_error;
3143: RAISE setup_failure;
3144: END IF;
3145: END IF;

Line 3149: gme_common_pvt.set_timestamp;

3145: END IF;
3146: /* Set the success staus to success inititally*/
3147: x_return_status := fnd_api.g_ret_sts_success;
3148: /* Punit Kumar */
3149: gme_common_pvt.set_timestamp;
3150:
3151: IF (g_debug <= gme_debug.g_log_procedure) THEN
3152: gme_debug.put_line (g_pkg_name || '.' || l_api_name || ':'
3153: || 'calling private layer');

Line 3172: gme_common_pvt.log_message ('GME_API_STEP_REOPENED');

3168: RAISE step_reopen_failure;
3169: END IF;
3170:
3171:
3172: gme_common_pvt.log_message ('GME_API_STEP_REOPENED');
3173:
3174:
3175: IF (g_debug <= gme_debug.g_log_procedure) THEN
3176: gme_debug.put_line ( 'Completed '

Line 3182: gme_common_pvt.count_and_get (x_count => x_message_count

3178: || ' at '
3179: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
3180: END IF;
3181:
3182: gme_common_pvt.count_and_get (x_count => x_message_count
3183: ,p_encoded => fnd_api.g_false
3184: ,x_data => x_message_list);
3185:
3186: IF (g_debug <= gme_debug.g_log_procedure) THEN

Line 3204: gme_common_pvt.count_and_get (x_count => x_message_count

3200: END IF;
3201:
3202: x_return_status := fnd_api.g_ret_sts_error;
3203: /* Punit Kumar */
3204: gme_common_pvt.count_and_get (x_count => x_message_count
3205: ,p_encoded => fnd_api.g_false
3206: ,x_data => x_message_list);
3207: WHEN step_reopen_failure OR step_save_failed THEN
3208: ROLLBACK TO SAVEPOINT reopen_batch_step;

Line 3219: gme_common_pvt.count_and_get (x_count => x_message_count

3215: );
3216: END IF;
3217:
3218: /* Punit Kumar */
3219: gme_common_pvt.count_and_get (x_count => x_message_count
3220: ,p_encoded => fnd_api.g_false
3221: ,x_data => x_message_list);
3222: x_return_status := fnd_api.g_ret_sts_error;
3223: WHEN OTHERS THEN

Line 3235: gme_common_pvt.count_and_get (x_count => x_message_count

3231: END IF;
3232:
3233: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3234: /* Punit Kumar */
3235: gme_common_pvt.count_and_get (x_count => x_message_count
3236: ,p_encoded => fnd_api.g_false
3237: ,x_data => x_message_list);
3238: x_return_status := fnd_api.g_ret_sts_unexp_error;
3239: END reopen_step;

Line 3280: := gme_common_pvt.g_max_errors

3276: Keep the user entered transaction date when exceptions appear so it can be used later on the form.
3277: ================================================================================*/
3278: PROCEDURE incremental_backflush (
3279: p_validation_level IN NUMBER
3280: := gme_common_pvt.g_max_errors
3281: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3282: ,x_message_count OUT NOCOPY NUMBER
3283: ,x_message_list OUT NOCOPY VARCHAR2
3284: ,x_return_status OUT NOCOPY VARCHAR2

Line 3290: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab )

3286: ,p_material_detail_rec IN gme_material_details%ROWTYPE
3287: ,p_qty IN NUMBER
3288: ,p_qty_type IN NUMBER
3289: ,p_trans_date IN DATE
3290: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab )
3291: IS
3292: l_api_name CONSTANT VARCHAR2 (30) := 'INCREMENTAL_BACKFLUSH';
3293: l_trans_date DATE;
3294:

Line 3310: IF NOT gme_common_pvt.g_setup_done THEN

3306: /* Set the return status to success initially */
3307: x_return_status := fnd_api.g_ret_sts_success;
3308:
3309: /* Setup the common constants used across the apis */
3310: IF NOT gme_common_pvt.g_setup_done THEN
3311: gme_common_pvt.g_setup_done :=
3312: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3313:
3314: IF NOT gme_common_pvt.g_setup_done THEN

Line 3311: gme_common_pvt.g_setup_done :=

3307: x_return_status := fnd_api.g_ret_sts_success;
3308:
3309: /* Setup the common constants used across the apis */
3310: IF NOT gme_common_pvt.g_setup_done THEN
3311: gme_common_pvt.g_setup_done :=
3312: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3313:
3314: IF NOT gme_common_pvt.g_setup_done THEN
3315: x_return_status := fnd_api.g_ret_sts_error;

Line 3312: gme_common_pvt.setup (p_batch_header_rec.organization_id);

3308:
3309: /* Setup the common constants used across the apis */
3310: IF NOT gme_common_pvt.g_setup_done THEN
3311: gme_common_pvt.g_setup_done :=
3312: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3313:
3314: IF NOT gme_common_pvt.g_setup_done THEN
3315: x_return_status := fnd_api.g_ret_sts_error;
3316: RAISE setup_failure;

Line 3314: IF NOT gme_common_pvt.g_setup_done THEN

3310: IF NOT gme_common_pvt.g_setup_done THEN
3311: gme_common_pvt.g_setup_done :=
3312: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3313:
3314: IF NOT gme_common_pvt.g_setup_done THEN
3315: x_return_status := fnd_api.g_ret_sts_error;
3316: RAISE setup_failure;
3317: END IF;
3318: END IF;

Line 3323: gme_common_pvt.g_error_count := 0;

3319:
3320: /* Initialize message list and count if needed */
3321: IF p_init_msg_list = fnd_api.g_true THEN
3322: fnd_msg_pub.initialize;
3323: gme_common_pvt.g_error_count := 0;
3324: END IF;
3325:
3326: gme_common_pvt.set_timestamp;
3327:

Line 3326: gme_common_pvt.set_timestamp;

3322: fnd_msg_pub.initialize;
3323: gme_common_pvt.g_error_count := 0;
3324: END IF;
3325:
3326: gme_common_pvt.set_timestamp;
3327:
3328: l_trans_date := p_trans_date;
3329:
3330: -- 8751983 - Set IB globals to be used later for resource trans reversals during negative IB.

Line 3332: gme_common_pvt.g_ib_timestamp_set := 1;

3328: l_trans_date := p_trans_date;
3329:
3330: -- 8751983 - Set IB globals to be used later for resource trans reversals during negative IB.
3331: IF l_trans_date IS NOT NULL THEN
3332: gme_common_pvt.g_ib_timestamp_set := 1;
3333: gme_common_pvt.g_ib_timestamp_date := l_trans_date;
3334: ELSE
3335: l_trans_date := gme_common_pvt.g_timestamp;
3336: gme_common_pvt.g_ib_timestamp_set := 0;

Line 3333: gme_common_pvt.g_ib_timestamp_date := l_trans_date;

3329:
3330: -- 8751983 - Set IB globals to be used later for resource trans reversals during negative IB.
3331: IF l_trans_date IS NOT NULL THEN
3332: gme_common_pvt.g_ib_timestamp_set := 1;
3333: gme_common_pvt.g_ib_timestamp_date := l_trans_date;
3334: ELSE
3335: l_trans_date := gme_common_pvt.g_timestamp;
3336: gme_common_pvt.g_ib_timestamp_set := 0;
3337: gme_common_pvt.g_ib_timestamp_date := NULL;

Line 3335: l_trans_date := gme_common_pvt.g_timestamp;

3331: IF l_trans_date IS NOT NULL THEN
3332: gme_common_pvt.g_ib_timestamp_set := 1;
3333: gme_common_pvt.g_ib_timestamp_date := l_trans_date;
3334: ELSE
3335: l_trans_date := gme_common_pvt.g_timestamp;
3336: gme_common_pvt.g_ib_timestamp_set := 0;
3337: gme_common_pvt.g_ib_timestamp_date := NULL;
3338: END IF;
3339:

Line 3336: gme_common_pvt.g_ib_timestamp_set := 0;

3332: gme_common_pvt.g_ib_timestamp_set := 1;
3333: gme_common_pvt.g_ib_timestamp_date := l_trans_date;
3334: ELSE
3335: l_trans_date := gme_common_pvt.g_timestamp;
3336: gme_common_pvt.g_ib_timestamp_set := 0;
3337: gme_common_pvt.g_ib_timestamp_date := NULL;
3338: END IF;
3339:
3340:

Line 3337: gme_common_pvt.g_ib_timestamp_date := NULL;

3333: gme_common_pvt.g_ib_timestamp_date := l_trans_date;
3334: ELSE
3335: l_trans_date := gme_common_pvt.g_timestamp;
3336: gme_common_pvt.g_ib_timestamp_set := 0;
3337: gme_common_pvt.g_ib_timestamp_date := NULL;
3338: END IF;
3339:
3340:
3341: IF ( NVL(G_DEBUG,-1) = GME_DEBUG.G_LOG_STATEMENT ) THEN

Line 3343: gme_debug.put_line('gme_common_pvt.g_ib_timestamp_set is '||gme_common_pvt.g_ib_timestamp_set);

3339:
3340:
3341: IF ( NVL(G_DEBUG,-1) = GME_DEBUG.G_LOG_STATEMENT ) THEN
3342: gme_debug.put_line('l_trans_date is '||to_char(l_trans_date, 'DD-MON-YYYY HH24:MI:SS'));
3343: gme_debug.put_line('gme_common_pvt.g_ib_timestamp_set is '||gme_common_pvt.g_ib_timestamp_set);
3344: END IF;
3345:
3346: -- does backflush resource usage need to be performed?
3347: IF (p_batch_header_rec.batch_status = gme_common_pvt.g_step_wip AND

Line 3347: IF (p_batch_header_rec.batch_status = gme_common_pvt.g_step_wip AND

3343: gme_debug.put_line('gme_common_pvt.g_ib_timestamp_set is '||gme_common_pvt.g_ib_timestamp_set);
3344: END IF;
3345:
3346: -- does backflush resource usage need to be performed?
3347: IF (p_batch_header_rec.batch_status = gme_common_pvt.g_step_wip AND
3348: p_material_detail_rec.line_type = gme_common_pvt.g_line_type_prod AND
3349: gme_common_pvt.g_backflush_rsrc_usg_ind = 1) THEN
3350: l_backflush_rsrc_usg_ind := 1;
3351: ELSE

Line 3348: p_material_detail_rec.line_type = gme_common_pvt.g_line_type_prod AND

3344: END IF;
3345:
3346: -- does backflush resource usage need to be performed?
3347: IF (p_batch_header_rec.batch_status = gme_common_pvt.g_step_wip AND
3348: p_material_detail_rec.line_type = gme_common_pvt.g_line_type_prod AND
3349: gme_common_pvt.g_backflush_rsrc_usg_ind = 1) THEN
3350: l_backflush_rsrc_usg_ind := 1;
3351: ELSE
3352: l_backflush_rsrc_usg_ind := 0;

Line 3349: gme_common_pvt.g_backflush_rsrc_usg_ind = 1) THEN

3345:
3346: -- does backflush resource usage need to be performed?
3347: IF (p_batch_header_rec.batch_status = gme_common_pvt.g_step_wip AND
3348: p_material_detail_rec.line_type = gme_common_pvt.g_line_type_prod AND
3349: gme_common_pvt.g_backflush_rsrc_usg_ind = 1) THEN
3350: l_backflush_rsrc_usg_ind := 1;
3351: ELSE
3352: l_backflush_rsrc_usg_ind := 0;
3353: END IF;

Line 3367: -- gme_common_pvt.g_ib_timestamp_set := 0;

3363: ,x_return_status => x_return_status);
3364:
3365: -- Bug 13881792 - Do not reset flag here. Moved below.
3366: -- Bug 13017256 - Reset flag.
3367: -- gme_common_pvt.g_ib_timestamp_set := 0;
3368:
3369: IF x_return_status NOT IN
3370: (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
3371: IF ( NVL(G_DEBUG,-1) = GME_DEBUG.G_LOG_STATEMENT ) THEN

Line 3370: (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN

3366: -- Bug 13017256 - Reset flag.
3367: -- gme_common_pvt.g_ib_timestamp_set := 0;
3368:
3369: IF x_return_status NOT IN
3370: (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
3371: IF ( NVL(G_DEBUG,-1) = GME_DEBUG.G_LOG_STATEMENT ) THEN
3372: gme_debug.put_line (g_pkg_name||'.'||l_api_name||' after gme_incremental_backflush_pvt.incremental_backflush; x_return_status= '||x_return_status);
3373: END IF;
3374:

Line 3376: gme_common_pvt.g_ib_timestamp_set := 0;

3372: gme_debug.put_line (g_pkg_name||'.'||l_api_name||' after gme_incremental_backflush_pvt.incremental_backflush; x_return_status= '||x_return_status);
3373: END IF;
3374:
3375: -- Bug 13017256 - Reset flag.
3376: gme_common_pvt.g_ib_timestamp_set := 0;
3377: RAISE incremental_backflush_failed;
3378: END IF; /* IF x_return_status NOT IN */
3379:
3380: /*Bug#5277982 if there are any exceptions then we give message saying IB done with exceptions*/

Line 3382: gme_common_pvt.log_message('GME_IB_EXCEPTIONS');

3378: END IF; /* IF x_return_status NOT IN */
3379:
3380: /*Bug#5277982 if there are any exceptions then we give message saying IB done with exceptions*/
3381: IF x_exception_material_tbl.COUNT > 0 THEN
3382: gme_common_pvt.log_message('GME_IB_EXCEPTIONS');
3383: -- Bug 13881792
3384: IF (gme_common_pvt.g_ib_timestamp_set <> 0) THEN
3385: gme_common_pvt.g_ib_timestamp_set := -1;
3386: END IF;

Line 3384: IF (gme_common_pvt.g_ib_timestamp_set <> 0) THEN

3380: /*Bug#5277982 if there are any exceptions then we give message saying IB done with exceptions*/
3381: IF x_exception_material_tbl.COUNT > 0 THEN
3382: gme_common_pvt.log_message('GME_IB_EXCEPTIONS');
3383: -- Bug 13881792
3384: IF (gme_common_pvt.g_ib_timestamp_set <> 0) THEN
3385: gme_common_pvt.g_ib_timestamp_set := -1;
3386: END IF;
3387: ELSE
3388: gme_common_pvt.log_message ('GME_API_PARTIAL_CERTIFIED');

Line 3385: gme_common_pvt.g_ib_timestamp_set := -1;

3381: IF x_exception_material_tbl.COUNT > 0 THEN
3382: gme_common_pvt.log_message('GME_IB_EXCEPTIONS');
3383: -- Bug 13881792
3384: IF (gme_common_pvt.g_ib_timestamp_set <> 0) THEN
3385: gme_common_pvt.g_ib_timestamp_set := -1;
3386: END IF;
3387: ELSE
3388: gme_common_pvt.log_message ('GME_API_PARTIAL_CERTIFIED');
3389: -- Bug 13017256 - Reset flag.

Line 3388: gme_common_pvt.log_message ('GME_API_PARTIAL_CERTIFIED');

3384: IF (gme_common_pvt.g_ib_timestamp_set <> 0) THEN
3385: gme_common_pvt.g_ib_timestamp_set := -1;
3386: END IF;
3387: ELSE
3388: gme_common_pvt.log_message ('GME_API_PARTIAL_CERTIFIED');
3389: -- Bug 13017256 - Reset flag.
3390: gme_common_pvt.g_ib_timestamp_set := 0;
3391: END IF;
3392:

Line 3390: gme_common_pvt.g_ib_timestamp_set := 0;

3386: END IF;
3387: ELSE
3388: gme_common_pvt.log_message ('GME_API_PARTIAL_CERTIFIED');
3389: -- Bug 13017256 - Reset flag.
3390: gme_common_pvt.g_ib_timestamp_set := 0;
3391: END IF;
3392:
3393: IF (g_debug <= gme_debug.g_log_procedure) THEN
3394: gme_debug.put_line ( 'gme_api_main: Completed '

Line 3400: gme_common_pvt.count_and_get (x_count => x_message_count

3396: || ' at '
3397: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
3398: END IF;
3399:
3400: gme_common_pvt.count_and_get (x_count => x_message_count
3401: ,p_encoded => fnd_api.g_false
3402: ,x_data => x_message_list);
3403: EXCEPTION
3404: WHEN setup_failure THEN

Line 3407: gme_common_pvt.count_and_get (x_count => x_message_count

3403: EXCEPTION
3404: WHEN setup_failure THEN
3405: ROLLBACK TO SAVEPOINT incremental_backflush;
3406: x_return_status := fnd_api.g_ret_sts_error;
3407: gme_common_pvt.count_and_get (x_count => x_message_count
3408: ,p_encoded => fnd_api.g_false
3409: ,x_data => x_message_list);
3410: WHEN incremental_backflush_failed THEN
3411: ROLLBACK TO SAVEPOINT incremental_backflush;

Line 3414: gme_common_pvt.count_and_get (x_count => x_message_count

3410: WHEN incremental_backflush_failed THEN
3411: ROLLBACK TO SAVEPOINT incremental_backflush;
3412: -- Bug 8639523 - Clear the cache just in case any transactions hit the tree.
3413: inv_quantity_tree_pub.clear_quantity_cache;
3414: gme_common_pvt.count_and_get (x_count => x_message_count
3415: ,p_encoded => fnd_api.g_false
3416: ,x_data => x_message_list);
3417: IF ( NVL(G_DEBUG,-1) = GME_DEBUG.G_LOG_STATEMENT ) THEN
3418: gme_debug.put_line (g_pkg_name||'.'||l_api_name||' in exception block; x_return_status= '||x_return_status);

Line 3423: gme_common_pvt.count_and_get (x_count => x_message_count

3419: END IF;
3420: WHEN OTHERS THEN
3421: ROLLBACK TO SAVEPOINT incremental_backflush;
3422: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3423: gme_common_pvt.count_and_get (x_count => x_message_count
3424: ,p_encoded => fnd_api.g_false
3425: ,x_data => x_message_list);
3426: x_return_status := fnd_api.g_ret_sts_unexp_error;
3427: END incremental_backflush;

Line 3450: := gme_common_pvt.g_max_errors

3446: C - No continous periods found
3447: ================================================================================*/
3448: PROCEDURE reroute_batch (
3449: p_validation_level IN NUMBER
3450: := gme_common_pvt.g_max_errors
3451: ,p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false
3452: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
3453: ,p_validity_rule_id IN NUMBER
3454: ,p_use_workday_cal IN VARCHAR2 DEFAULT fnd_api.g_false

Line 3480: gme_common_pvt.g_error_count := 0;

3476: END IF;
3477:
3478: IF (fnd_api.to_boolean (p_init_msg_list) ) THEN
3479: fnd_msg_pub.initialize;
3480: gme_common_pvt.g_error_count := 0;
3481: END IF;
3482:
3483: /* Set the return status to success initially */
3484: x_return_status := fnd_api.g_ret_sts_success;

Line 3486: IF NOT gme_common_pvt.g_setup_done THEN

3482:
3483: /* Set the return status to success initially */
3484: x_return_status := fnd_api.g_ret_sts_success;
3485:
3486: IF NOT gme_common_pvt.g_setup_done THEN
3487: gme_common_pvt.g_setup_done :=
3488: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3489:
3490: IF NOT gme_common_pvt.g_setup_done THEN

Line 3487: gme_common_pvt.g_setup_done :=

3483: /* Set the return status to success initially */
3484: x_return_status := fnd_api.g_ret_sts_success;
3485:
3486: IF NOT gme_common_pvt.g_setup_done THEN
3487: gme_common_pvt.g_setup_done :=
3488: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3489:
3490: IF NOT gme_common_pvt.g_setup_done THEN
3491: x_return_status := fnd_api.g_ret_sts_error;

Line 3488: gme_common_pvt.setup (p_batch_header_rec.organization_id);

3484: x_return_status := fnd_api.g_ret_sts_success;
3485:
3486: IF NOT gme_common_pvt.g_setup_done THEN
3487: gme_common_pvt.g_setup_done :=
3488: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3489:
3490: IF NOT gme_common_pvt.g_setup_done THEN
3491: x_return_status := fnd_api.g_ret_sts_error;
3492: RAISE setup_failure;

Line 3490: IF NOT gme_common_pvt.g_setup_done THEN

3486: IF NOT gme_common_pvt.g_setup_done THEN
3487: gme_common_pvt.g_setup_done :=
3488: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3489:
3490: IF NOT gme_common_pvt.g_setup_done THEN
3491: x_return_status := fnd_api.g_ret_sts_error;
3492: RAISE setup_failure;
3493: END IF;
3494: END IF;

Line 3496: gme_common_pvt.set_timestamp;

3492: RAISE setup_failure;
3493: END IF;
3494: END IF;
3495:
3496: gme_common_pvt.set_timestamp;
3497: gme_reroute_batch_pvt.reroute_batch
3498: (p_batch_header_rec => p_batch_header_rec
3499: ,p_validity_rule_id => p_validity_rule_id
3500: ,p_use_workday_cal => p_use_workday_cal

Line 3518: gme_common_pvt.log_message ('GME_API_BATCH_REROUTED','DOC',FND_MESSAGE.GET);

3514: FND_MESSAGE.SET_NAME('GME','GME_BATCH');
3515: ELSE
3516: FND_MESSAGE.SET_NAME('GME','GME_FIRM_PLAN_ORDER');
3517: END IF;
3518: gme_common_pvt.log_message ('GME_API_BATCH_REROUTED','DOC',FND_MESSAGE.GET);
3519: --FPBug#5040865 End
3520: END IF;
3521:
3522: gme_common_pvt.count_and_get (x_count => x_message_count

Line 3522: gme_common_pvt.count_and_get (x_count => x_message_count

3518: gme_common_pvt.log_message ('GME_API_BATCH_REROUTED','DOC',FND_MESSAGE.GET);
3519: --FPBug#5040865 End
3520: END IF;
3521:
3522: gme_common_pvt.count_and_get (x_count => x_message_count
3523: ,p_encoded => fnd_api.g_false
3524: ,x_data => x_message_list);
3525:
3526: IF (NVL (g_debug, 0) IN

Line 3539: gme_common_pvt.count_and_get (x_count => x_message_count

3535: EXCEPTION
3536: WHEN setup_failure THEN
3537: ROLLBACK TO SAVEPOINT reroute_batch_main;
3538: x_batch_header_rec := NULL;
3539: gme_common_pvt.count_and_get (x_count => x_message_count
3540: ,p_encoded => fnd_api.g_false
3541: ,x_data => x_message_list);
3542: x_return_status := fnd_api.g_ret_sts_error;
3543: WHEN no_continous_periods THEN

Line 3544: gme_common_pvt.count_and_get (x_count => x_message_count

3540: ,p_encoded => fnd_api.g_false
3541: ,x_data => x_message_list);
3542: x_return_status := fnd_api.g_ret_sts_error;
3543: WHEN no_continous_periods THEN
3544: gme_common_pvt.count_and_get (x_count => x_message_count
3545: ,p_encoded => fnd_api.g_false
3546: ,x_data => x_message_list);
3547: WHEN fnd_api.g_exc_error THEN
3548: ROLLBACK TO SAVEPOINT reroute_batch_main;

Line 3551: gme_common_pvt.count_and_get (x_count => x_message_count

3547: WHEN fnd_api.g_exc_error THEN
3548: ROLLBACK TO SAVEPOINT reroute_batch_main;
3549: x_batch_header_rec := NULL;
3550: x_return_status := fnd_api.g_ret_sts_error;
3551: gme_common_pvt.count_and_get (x_count => x_message_count
3552: ,p_encoded => fnd_api.g_false
3553: ,x_data => x_message_list);
3554: WHEN fnd_api.g_exc_unexpected_error THEN
3555: ROLLBACK TO SAVEPOINT reroute_batch_main;

Line 3568: gme_common_pvt.count_and_get (x_count => x_message_count

3564: || 'UNEXPECTED:'
3565: || SQLERRM);
3566: END IF;
3567:
3568: gme_common_pvt.count_and_get (x_count => x_message_count
3569: ,p_encoded => fnd_api.g_false
3570: ,x_data => x_message_list);
3571: WHEN OTHERS THEN
3572: ROLLBACK TO SAVEPOINT reroute_batch_main;

Line 3586: gme_common_pvt.count_and_get (x_count => x_message_count

3582: || 'OTHERS:'
3583: || SQLERRM);
3584: END IF;
3585:
3586: gme_common_pvt.count_and_get (x_count => x_message_count
3587: ,p_encoded => fnd_api.g_false
3588: ,x_data => x_message_list);
3589: END reroute_batch;
3590:

Line 3610: := gme_common_pvt.g_max_errors

3606: U - Unexpected Error
3607: ================================================================================*/
3608: PROCEDURE cancel_batch (
3609: p_validation_level IN NUMBER
3610: := gme_common_pvt.g_max_errors
3611: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3612: ,x_message_count OUT NOCOPY NUMBER
3613: ,x_message_list OUT NOCOPY VARCHAR2
3614: ,x_return_status OUT NOCOPY VARCHAR2

Line 3636: IF NOT gme_common_pvt.g_setup_done THEN

3632:
3633: /* Set the return status to success initially */
3634: x_return_status := fnd_api.g_ret_sts_success;
3635:
3636: IF NOT gme_common_pvt.g_setup_done THEN
3637: gme_common_pvt.g_setup_done :=
3638: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3639:
3640: IF NOT gme_common_pvt.g_setup_done THEN

Line 3637: gme_common_pvt.g_setup_done :=

3633: /* Set the return status to success initially */
3634: x_return_status := fnd_api.g_ret_sts_success;
3635:
3636: IF NOT gme_common_pvt.g_setup_done THEN
3637: gme_common_pvt.g_setup_done :=
3638: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3639:
3640: IF NOT gme_common_pvt.g_setup_done THEN
3641: x_return_status := fnd_api.g_ret_sts_error;

Line 3638: gme_common_pvt.setup (p_batch_header_rec.organization_id);

3634: x_return_status := fnd_api.g_ret_sts_success;
3635:
3636: IF NOT gme_common_pvt.g_setup_done THEN
3637: gme_common_pvt.g_setup_done :=
3638: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3639:
3640: IF NOT gme_common_pvt.g_setup_done THEN
3641: x_return_status := fnd_api.g_ret_sts_error;
3642: RAISE setup_failure;

Line 3640: IF NOT gme_common_pvt.g_setup_done THEN

3636: IF NOT gme_common_pvt.g_setup_done THEN
3637: gme_common_pvt.g_setup_done :=
3638: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3639:
3640: IF NOT gme_common_pvt.g_setup_done THEN
3641: x_return_status := fnd_api.g_ret_sts_error;
3642: RAISE setup_failure;
3643: END IF;
3644: END IF;

Line 3649: gme_common_pvt.g_error_count := 0;

3645:
3646: -- Initialize message list and count if needed
3647: IF p_init_msg_list = fnd_api.g_true THEN
3648: fnd_msg_pub.initialize;
3649: gme_common_pvt.g_error_count := 0;
3650: END IF;
3651:
3652: gme_common_pvt.set_timestamp;
3653:

Line 3652: gme_common_pvt.set_timestamp;

3648: fnd_msg_pub.initialize;
3649: gme_common_pvt.g_error_count := 0;
3650: END IF;
3651:
3652: gme_common_pvt.set_timestamp;
3653:
3654: IF g_debug <= gme_debug.g_log_statement THEN
3655: gme_debug.put_line ( g_pkg_name
3656: || '.'

Line 3686: gme_common_pvt.log_message ('GME_API_BATCH_CANCELLED','DOC',FND_MESSAGE.GET);

3682: FND_MESSAGE.SET_NAME('GME','GME_BATCH');
3683: ELSE
3684: FND_MESSAGE.SET_NAME('GME','GME_FIRM_PLAN_ORDER');
3685: END IF;
3686: gme_common_pvt.log_message ('GME_API_BATCH_CANCELLED','DOC',FND_MESSAGE.GET);
3687: --FPBug#5040865 End
3688:
3689: gme_common_pvt.count_and_get (x_count => x_message_count
3690: ,p_encoded => fnd_api.g_false

Line 3689: gme_common_pvt.count_and_get (x_count => x_message_count

3685: END IF;
3686: gme_common_pvt.log_message ('GME_API_BATCH_CANCELLED','DOC',FND_MESSAGE.GET);
3687: --FPBug#5040865 End
3688:
3689: gme_common_pvt.count_and_get (x_count => x_message_count
3690: ,p_encoded => fnd_api.g_false
3691: ,x_data => x_message_list);
3692:
3693: IF (g_debug IS NOT NULL) THEN

Line 3711: gme_common_pvt.count_and_get (x_count => x_message_count

3707: EXCEPTION
3708: WHEN batch_cancel_failure THEN
3709: ROLLBACK TO SAVEPOINT cancel_batch;
3710: x_batch_header_rec := NULL;
3711: gme_common_pvt.count_and_get (x_count => x_message_count
3712: ,p_encoded => fnd_api.g_false
3713: ,x_data => x_message_list);
3714: WHEN setup_failure THEN
3715: ROLLBACK TO SAVEPOINT cancel_batch;

Line 3717: gme_common_pvt.count_and_get (x_count => x_message_count

3713: ,x_data => x_message_list);
3714: WHEN setup_failure THEN
3715: ROLLBACK TO SAVEPOINT cancel_batch;
3716: x_batch_header_rec := NULL;
3717: gme_common_pvt.count_and_get (x_count => x_message_count
3718: ,p_encoded => fnd_api.g_false
3719: ,x_data => x_message_list);
3720: x_return_status := fnd_api.g_ret_sts_error;
3721: WHEN OTHERS THEN

Line 3733: gme_common_pvt.count_and_get (x_count => x_message_count

3729: END IF;
3730:
3731: ROLLBACK TO SAVEPOINT cancel_batch;
3732: x_batch_header_rec := NULL;
3733: gme_common_pvt.count_and_get (x_count => x_message_count
3734: ,p_encoded => fnd_api.g_false
3735: ,x_data => x_message_list);
3736: x_return_status := fnd_api.g_ret_sts_unexp_error;
3737: END cancel_batch;

Line 3760: := gme_common_pvt.g_max_errors

3756: U - Unexpected Error
3757: ================================================================================*/
3758: PROCEDURE terminate_batch (
3759: p_validation_level IN NUMBER
3760: := gme_common_pvt.g_max_errors
3761: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3762: ,x_message_count OUT NOCOPY NUMBER
3763: ,x_message_list OUT NOCOPY VARCHAR2
3764: ,x_return_status OUT NOCOPY VARCHAR2

Line 3787: IF NOT gme_common_pvt.g_setup_done THEN

3783:
3784: /* Set the return status to success initially */
3785: x_return_status := fnd_api.g_ret_sts_success;
3786:
3787: IF NOT gme_common_pvt.g_setup_done THEN
3788: gme_common_pvt.g_setup_done :=
3789: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3790:
3791: IF NOT gme_common_pvt.g_setup_done THEN

Line 3788: gme_common_pvt.g_setup_done :=

3784: /* Set the return status to success initially */
3785: x_return_status := fnd_api.g_ret_sts_success;
3786:
3787: IF NOT gme_common_pvt.g_setup_done THEN
3788: gme_common_pvt.g_setup_done :=
3789: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3790:
3791: IF NOT gme_common_pvt.g_setup_done THEN
3792: x_return_status := fnd_api.g_ret_sts_error;

Line 3789: gme_common_pvt.setup (p_batch_header_rec.organization_id);

3785: x_return_status := fnd_api.g_ret_sts_success;
3786:
3787: IF NOT gme_common_pvt.g_setup_done THEN
3788: gme_common_pvt.g_setup_done :=
3789: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3790:
3791: IF NOT gme_common_pvt.g_setup_done THEN
3792: x_return_status := fnd_api.g_ret_sts_error;
3793: RAISE setup_failure;

Line 3791: IF NOT gme_common_pvt.g_setup_done THEN

3787: IF NOT gme_common_pvt.g_setup_done THEN
3788: gme_common_pvt.g_setup_done :=
3789: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3790:
3791: IF NOT gme_common_pvt.g_setup_done THEN
3792: x_return_status := fnd_api.g_ret_sts_error;
3793: RAISE setup_failure;
3794: END IF;
3795: END IF;

Line 3800: gme_common_pvt.g_error_count := 0;

3796:
3797: -- Initialize message list and count if needed
3798: IF p_init_msg_list = fnd_api.g_true THEN
3799: fnd_msg_pub.initialize;
3800: gme_common_pvt.g_error_count := 0;
3801: END IF;
3802:
3803: gme_common_pvt.set_timestamp;
3804:

Line 3803: gme_common_pvt.set_timestamp;

3799: fnd_msg_pub.initialize;
3800: gme_common_pvt.g_error_count := 0;
3801: END IF;
3802:
3803: gme_common_pvt.set_timestamp;
3804:
3805: IF g_debug <= gme_debug.g_log_statement THEN
3806: gme_debug.put_line ( g_pkg_name
3807: || '.'

Line 3831: gme_common_pvt.log_message ('GME_API_BATCH_TERMINATED');

3827: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3828: RAISE batch_terminate_failure;
3829: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3830:
3831: gme_common_pvt.log_message ('GME_API_BATCH_TERMINATED');
3832:
3833:
3834: gme_common_pvt.count_and_get (x_count => x_message_count
3835: ,p_encoded => fnd_api.g_false

Line 3834: gme_common_pvt.count_and_get (x_count => x_message_count

3830:
3831: gme_common_pvt.log_message ('GME_API_BATCH_TERMINATED');
3832:
3833:
3834: gme_common_pvt.count_and_get (x_count => x_message_count
3835: ,p_encoded => fnd_api.g_false
3836: ,x_data => x_message_list);
3837:
3838: IF (g_debug IS NOT NULL) THEN

Line 3867: gme_common_pvt.count_and_get (x_count => x_message_count

3863: || 'SETUP_FAILURE.');
3864: END IF;
3865:
3866: x_return_status := fnd_api.g_ret_sts_error;
3867: gme_common_pvt.count_and_get (x_count => x_message_count
3868: ,p_encoded => fnd_api.g_false
3869: ,x_data => x_message_list);
3870: WHEN batch_terminate_failure THEN
3871: ROLLBACK TO SAVEPOINT terminate_batch;

Line 3883: gme_common_pvt.count_and_get (x_count => x_message_count

3879: || ':'
3880: || 'BATCH_TERMINATE_FAILURE OR BATCH_SAVE_FAILED.');
3881: END IF;
3882:
3883: gme_common_pvt.count_and_get (x_count => x_message_count
3884: ,p_encoded => fnd_api.g_false
3885: ,x_data => x_message_list);
3886: WHEN OTHERS THEN
3887: ROLLBACK TO SAVEPOINT terminate_batch;

Line 3900: gme_common_pvt.count_and_get (x_count => x_message_count

3896: || SQLERRM);
3897: END IF;
3898:
3899: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3900: gme_common_pvt.count_and_get (x_count => x_message_count
3901: ,p_encoded => fnd_api.g_false
3902: ,x_data => x_message_list);
3903: x_return_status := fnd_api.g_ret_sts_unexp_error;
3904: END terminate_batch;

Line 3909: := gme_common_pvt.g_max_errors

3905:
3906: /*************************************************************************/
3907: PROCEDURE unrelease_batch (
3908: p_validation_level IN NUMBER
3909: := gme_common_pvt.g_max_errors
3910: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3911: ,x_message_count OUT NOCOPY NUMBER
3912: ,x_message_list OUT NOCOPY VARCHAR2
3913: ,x_return_status OUT NOCOPY VARCHAR2

Line 3933: IF NOT gme_common_pvt.g_setup_done THEN

3929: IF (g_debug IS NOT NULL) THEN
3930: gme_debug.log_initialize ('UnreleaseBatch');
3931: END IF;
3932:
3933: IF NOT gme_common_pvt.g_setup_done THEN
3934: gme_common_pvt.g_setup_done :=
3935: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3936:
3937: IF NOT gme_common_pvt.g_setup_done THEN

Line 3934: gme_common_pvt.g_setup_done :=

3930: gme_debug.log_initialize ('UnreleaseBatch');
3931: END IF;
3932:
3933: IF NOT gme_common_pvt.g_setup_done THEN
3934: gme_common_pvt.g_setup_done :=
3935: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3936:
3937: IF NOT gme_common_pvt.g_setup_done THEN
3938: x_return_status := fnd_api.g_ret_sts_error;

Line 3935: gme_common_pvt.setup (p_batch_header_rec.organization_id);

3931: END IF;
3932:
3933: IF NOT gme_common_pvt.g_setup_done THEN
3934: gme_common_pvt.g_setup_done :=
3935: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3936:
3937: IF NOT gme_common_pvt.g_setup_done THEN
3938: x_return_status := fnd_api.g_ret_sts_error;
3939: RAISE setup_failure;

Line 3937: IF NOT gme_common_pvt.g_setup_done THEN

3933: IF NOT gme_common_pvt.g_setup_done THEN
3934: gme_common_pvt.g_setup_done :=
3935: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3936:
3937: IF NOT gme_common_pvt.g_setup_done THEN
3938: x_return_status := fnd_api.g_ret_sts_error;
3939: RAISE setup_failure;
3940: END IF;
3941: END IF;

Line 3949: gme_common_pvt.g_error_count := 0;

3945:
3946: -- Initialize message list and count if needed
3947: IF p_init_msg_list = fnd_api.g_true THEN
3948: fnd_msg_pub.initialize;
3949: gme_common_pvt.g_error_count := 0;
3950: END IF;
3951:
3952: gme_common_pvt.set_timestamp;
3953: gme_common_pvt.reset_txn_hdr_tbl; -- nsinghi bug#5176319

Line 3952: gme_common_pvt.set_timestamp;

3948: fnd_msg_pub.initialize;
3949: gme_common_pvt.g_error_count := 0;
3950: END IF;
3951:
3952: gme_common_pvt.set_timestamp;
3953: gme_common_pvt.reset_txn_hdr_tbl; -- nsinghi bug#5176319
3954: gme_unrelease_batch_pvt.unrelease_batch
3955: (p_batch_header_rec => p_batch_header_rec
3956: ,p_create_resv_pend_lots => p_create_resv_pend_lots

Line 3953: gme_common_pvt.reset_txn_hdr_tbl; -- nsinghi bug#5176319

3949: gme_common_pvt.g_error_count := 0;
3950: END IF;
3951:
3952: gme_common_pvt.set_timestamp;
3953: gme_common_pvt.reset_txn_hdr_tbl; -- nsinghi bug#5176319
3954: gme_unrelease_batch_pvt.unrelease_batch
3955: (p_batch_header_rec => p_batch_header_rec
3956: ,p_create_resv_pend_lots => p_create_resv_pend_lots
3957: ,x_batch_header_rec => x_batch_header_rec

Line 3964: gme_common_pvt.log_message ('GME_API_BATCH_UNRELEASED');

3960: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3961: RAISE batch_unrelease_failure;
3962: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3963:
3964: gme_common_pvt.log_message ('GME_API_BATCH_UNRELEASED');
3965:
3966: gme_common_pvt.count_and_get (x_count => x_message_count
3967: ,p_encoded => fnd_api.g_false
3968: ,x_data => x_message_list);

Line 3966: gme_common_pvt.count_and_get (x_count => x_message_count

3962: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3963:
3964: gme_common_pvt.log_message ('GME_API_BATCH_UNRELEASED');
3965:
3966: gme_common_pvt.count_and_get (x_count => x_message_count
3967: ,p_encoded => fnd_api.g_false
3968: ,x_data => x_message_list);
3969:
3970: IF (g_debug IS NOT NULL) THEN

Line 3984: gme_common_pvt.count_and_get (x_count => x_message_count

3980: EXCEPTION
3981: WHEN batch_unrelease_failure THEN
3982: ROLLBACK TO SAVEPOINT unrelease_batch;
3983: x_batch_header_rec := NULL;
3984: gme_common_pvt.count_and_get (x_count => x_message_count
3985: ,p_encoded => fnd_api.g_false
3986: ,x_data => x_message_list);
3987: WHEN setup_failure THEN
3988: ROLLBACK TO SAVEPOINT unrelease_batch;

Line 3990: gme_common_pvt.count_and_get (x_count => x_message_count

3986: ,x_data => x_message_list);
3987: WHEN setup_failure THEN
3988: ROLLBACK TO SAVEPOINT unrelease_batch;
3989: x_batch_header_rec := NULL;
3990: gme_common_pvt.count_and_get (x_count => x_message_count
3991: ,p_encoded => fnd_api.g_false
3992: ,x_data => x_message_list);
3993: x_return_status := fnd_api.g_ret_sts_error;
3994: WHEN OTHERS THEN

Line 4006: gme_common_pvt.count_and_get (x_count => x_message_count

4002: END IF;
4003:
4004: ROLLBACK TO SAVEPOINT unrelease_batch;
4005: x_batch_header_rec := NULL;
4006: gme_common_pvt.count_and_get (x_count => x_message_count
4007: ,p_encoded => fnd_api.g_false
4008: ,x_data => x_message_list);
4009: x_return_status := fnd_api.g_ret_sts_unexp_error;
4010: END unrelease_batch;

Line 4015: := gme_common_pvt.g_max_errors

4011:
4012: /*************************************************************************/
4013: PROCEDURE unrelease_step (
4014: p_validation_level IN NUMBER
4015: := gme_common_pvt.g_max_errors
4016: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
4017: ,x_message_count OUT NOCOPY NUMBER
4018: ,x_message_list OUT NOCOPY VARCHAR2
4019: ,x_return_status OUT NOCOPY VARCHAR2

Line 4040: IF NOT gme_common_pvt.g_setup_done THEN

4036: IF (g_debug IS NOT NULL) THEN
4037: gme_debug.log_initialize ('UnreleaseStep');
4038: END IF;
4039:
4040: IF NOT gme_common_pvt.g_setup_done THEN
4041: gme_common_pvt.g_setup_done :=
4042: gme_common_pvt.setup (p_batch_header_rec.organization_id);
4043:
4044: IF NOT gme_common_pvt.g_setup_done THEN

Line 4041: gme_common_pvt.g_setup_done :=

4037: gme_debug.log_initialize ('UnreleaseStep');
4038: END IF;
4039:
4040: IF NOT gme_common_pvt.g_setup_done THEN
4041: gme_common_pvt.g_setup_done :=
4042: gme_common_pvt.setup (p_batch_header_rec.organization_id);
4043:
4044: IF NOT gme_common_pvt.g_setup_done THEN
4045: x_return_status := fnd_api.g_ret_sts_error;

Line 4042: gme_common_pvt.setup (p_batch_header_rec.organization_id);

4038: END IF;
4039:
4040: IF NOT gme_common_pvt.g_setup_done THEN
4041: gme_common_pvt.g_setup_done :=
4042: gme_common_pvt.setup (p_batch_header_rec.organization_id);
4043:
4044: IF NOT gme_common_pvt.g_setup_done THEN
4045: x_return_status := fnd_api.g_ret_sts_error;
4046: RAISE setup_failure;

Line 4044: IF NOT gme_common_pvt.g_setup_done THEN

4040: IF NOT gme_common_pvt.g_setup_done THEN
4041: gme_common_pvt.g_setup_done :=
4042: gme_common_pvt.setup (p_batch_header_rec.organization_id);
4043:
4044: IF NOT gme_common_pvt.g_setup_done THEN
4045: x_return_status := fnd_api.g_ret_sts_error;
4046: RAISE setup_failure;
4047: END IF;
4048: END IF;

Line 4056: gme_common_pvt.g_error_count := 0;

4052:
4053: -- Initialize message list and count if needed
4054: IF p_init_msg_list = fnd_api.g_true THEN
4055: fnd_msg_pub.initialize;
4056: gme_common_pvt.g_error_count := 0;
4057: END IF;
4058:
4059: gme_common_pvt.set_timestamp;
4060: gme_common_pvt.reset_txn_hdr_tbl; -- nsinghi bug#5176319

Line 4059: gme_common_pvt.set_timestamp;

4055: fnd_msg_pub.initialize;
4056: gme_common_pvt.g_error_count := 0;
4057: END IF;
4058:
4059: gme_common_pvt.set_timestamp;
4060: gme_common_pvt.reset_txn_hdr_tbl; -- nsinghi bug#5176319
4061: gme_unrelease_step_pvt.unrelease_step
4062: (p_batch_step_rec => p_batch_step_rec
4063: ,p_update_inventory_ind => p_batch_header_rec.update_inventory_ind

Line 4060: gme_common_pvt.reset_txn_hdr_tbl; -- nsinghi bug#5176319

4056: gme_common_pvt.g_error_count := 0;
4057: END IF;
4058:
4059: gme_common_pvt.set_timestamp;
4060: gme_common_pvt.reset_txn_hdr_tbl; -- nsinghi bug#5176319
4061: gme_unrelease_step_pvt.unrelease_step
4062: (p_batch_step_rec => p_batch_step_rec
4063: ,p_update_inventory_ind => p_batch_header_rec.update_inventory_ind
4064: ,p_create_resv_pend_lots => p_create_resv_pend_lots

Line 4074: gme_common_pvt.log_message ('GME_BATCH_STEP_UNRELEASED');

4070: RAISE step_unrelease_failure;
4071: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4072:
4073:
4074: gme_common_pvt.log_message ('GME_BATCH_STEP_UNRELEASED');
4075:
4076: gme_common_pvt.count_and_get (x_count => x_message_count
4077: ,p_encoded => fnd_api.g_false
4078: ,x_data => x_message_list);

Line 4076: gme_common_pvt.count_and_get (x_count => x_message_count

4072:
4073:
4074: gme_common_pvt.log_message ('GME_BATCH_STEP_UNRELEASED');
4075:
4076: gme_common_pvt.count_and_get (x_count => x_message_count
4077: ,p_encoded => fnd_api.g_false
4078: ,x_data => x_message_list);
4079:
4080: IF (g_debug IS NOT NULL) THEN

Line 4094: gme_common_pvt.count_and_get (x_count => x_message_count

4090: EXCEPTION
4091: WHEN step_unrelease_failure THEN
4092: ROLLBACK TO SAVEPOINT unrelease_step;
4093: x_batch_step_rec := NULL;
4094: gme_common_pvt.count_and_get (x_count => x_message_count
4095: ,p_encoded => fnd_api.g_false
4096: ,x_data => x_message_list);
4097: WHEN setup_failure THEN
4098: ROLLBACK TO SAVEPOINT unrelease_step;

Line 4100: gme_common_pvt.count_and_get (x_count => x_message_count

4096: ,x_data => x_message_list);
4097: WHEN setup_failure THEN
4098: ROLLBACK TO SAVEPOINT unrelease_step;
4099: x_batch_step_rec := NULL;
4100: gme_common_pvt.count_and_get (x_count => x_message_count
4101: ,p_encoded => fnd_api.g_false
4102: ,x_data => x_message_list);
4103: x_return_status := fnd_api.g_ret_sts_error;
4104: WHEN OTHERS THEN

Line 4116: gme_common_pvt.count_and_get (x_count => x_message_count

4112: END IF;
4113:
4114: ROLLBACK TO SAVEPOINT unrelease_step;
4115: x_batch_step_rec := NULL;
4116: gme_common_pvt.count_and_get (x_count => x_message_count
4117: ,p_encoded => fnd_api.g_false
4118: ,x_data => x_message_list);
4119: x_return_status := fnd_api.g_ret_sts_unexp_error;
4120: END unrelease_step;

Line 4146: IF NOT gme_common_pvt.g_setup_done THEN

4142: gme_debug.put_line ('Entering api ' || g_pkg_name || '.'
4143: || l_api_name);
4144: END IF;
4145:
4146: IF NOT gme_common_pvt.g_setup_done THEN
4147: gme_common_pvt.g_setup_done :=
4148: gme_common_pvt.setup (p_material_detail_rec.organization_id);
4149:
4150: IF NOT gme_common_pvt.g_setup_done THEN

Line 4147: gme_common_pvt.g_setup_done :=

4143: || l_api_name);
4144: END IF;
4145:
4146: IF NOT gme_common_pvt.g_setup_done THEN
4147: gme_common_pvt.g_setup_done :=
4148: gme_common_pvt.setup (p_material_detail_rec.organization_id);
4149:
4150: IF NOT gme_common_pvt.g_setup_done THEN
4151: x_return_status := fnd_api.g_ret_sts_error;

Line 4148: gme_common_pvt.setup (p_material_detail_rec.organization_id);

4144: END IF;
4145:
4146: IF NOT gme_common_pvt.g_setup_done THEN
4147: gme_common_pvt.g_setup_done :=
4148: gme_common_pvt.setup (p_material_detail_rec.organization_id);
4149:
4150: IF NOT gme_common_pvt.g_setup_done THEN
4151: x_return_status := fnd_api.g_ret_sts_error;
4152: RAISE setup_failure;

Line 4150: IF NOT gme_common_pvt.g_setup_done THEN

4146: IF NOT gme_common_pvt.g_setup_done THEN
4147: gme_common_pvt.g_setup_done :=
4148: gme_common_pvt.setup (p_material_detail_rec.organization_id);
4149:
4150: IF NOT gme_common_pvt.g_setup_done THEN
4151: x_return_status := fnd_api.g_ret_sts_error;
4152: RAISE setup_failure;
4153: END IF;
4154: END IF;

Line 4159: gme_common_pvt.g_error_count := 0;

4155:
4156: -- Initialize message list and count if needed
4157: IF p_init_msg_list = fnd_api.g_true THEN
4158: fnd_msg_pub.initialize;
4159: gme_common_pvt.g_error_count := 0;
4160: END IF;
4161:
4162: /* Set the return status to success initially */
4163: x_return_status := fnd_api.g_ret_sts_success;

Line 4165: gme_common_pvt.set_timestamp;

4161:
4162: /* Set the return status to success initially */
4163: x_return_status := fnd_api.g_ret_sts_success;
4164: /* Set the timestamp */
4165: gme_common_pvt.set_timestamp;
4166: gme_reservations_pvt.auto_detail_line
4167: (p_material_details_rec => p_material_detail_rec
4168: ,x_return_status => x_return_status);
4169:

Line 4174: gme_common_pvt.log_message ('GME_BATCH_AUTO_DETAIL_LINE');

4170: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4171: RAISE auto_detail_failure;
4172: END IF;
4173:
4174: gme_common_pvt.log_message ('GME_BATCH_AUTO_DETAIL_LINE');
4175:
4176: IF (g_debug <= gme_debug.g_log_procedure) THEN
4177: gme_debug.put_line ( 'Completed '
4178: || l_api_name

Line 4185: gme_common_pvt.count_and_get (x_count => x_message_count

4181: END IF;
4182: EXCEPTION
4183: WHEN auto_detail_failure OR setup_failure THEN
4184: ROLLBACK TO SAVEPOINT auto_detail_line;
4185: gme_common_pvt.count_and_get (x_count => x_message_count
4186: ,p_encoded => fnd_api.g_false
4187: ,x_data => x_message_list);
4188: WHEN OTHERS THEN
4189: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 4200: gme_common_pvt.count_and_get (x_count => x_message_count

4196: END IF;
4197:
4198: ROLLBACK TO SAVEPOINT auto_detail_line;
4199: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
4200: gme_common_pvt.count_and_get (x_count => x_message_count
4201: ,p_encoded => fnd_api.g_false
4202: ,x_data => x_message_list);
4203: x_return_status := fnd_api.g_ret_sts_unexp_error;
4204: END auto_detail_line;

Line 4230: IF NOT gme_common_pvt.g_setup_done THEN

4226: IF g_debug <= gme_debug.g_log_procedure THEN
4227: gme_debug.put_line ('Entering api ' || g_pkg_name || '.' || l_api_name);
4228: END IF;
4229:
4230: IF NOT gme_common_pvt.g_setup_done THEN
4231: gme_common_pvt.g_setup_done :=
4232: gme_common_pvt.setup (p_batch_rec.organization_id);
4233:
4234: IF NOT gme_common_pvt.g_setup_done THEN

Line 4231: gme_common_pvt.g_setup_done :=

4227: gme_debug.put_line ('Entering api ' || g_pkg_name || '.' || l_api_name);
4228: END IF;
4229:
4230: IF NOT gme_common_pvt.g_setup_done THEN
4231: gme_common_pvt.g_setup_done :=
4232: gme_common_pvt.setup (p_batch_rec.organization_id);
4233:
4234: IF NOT gme_common_pvt.g_setup_done THEN
4235: x_return_status := fnd_api.g_ret_sts_error;

Line 4232: gme_common_pvt.setup (p_batch_rec.organization_id);

4228: END IF;
4229:
4230: IF NOT gme_common_pvt.g_setup_done THEN
4231: gme_common_pvt.g_setup_done :=
4232: gme_common_pvt.setup (p_batch_rec.organization_id);
4233:
4234: IF NOT gme_common_pvt.g_setup_done THEN
4235: x_return_status := fnd_api.g_ret_sts_error;
4236: RAISE setup_failure;

Line 4234: IF NOT gme_common_pvt.g_setup_done THEN

4230: IF NOT gme_common_pvt.g_setup_done THEN
4231: gme_common_pvt.g_setup_done :=
4232: gme_common_pvt.setup (p_batch_rec.organization_id);
4233:
4234: IF NOT gme_common_pvt.g_setup_done THEN
4235: x_return_status := fnd_api.g_ret_sts_error;
4236: RAISE setup_failure;
4237: END IF;
4238: END IF;

Line 4243: gme_common_pvt.g_error_count := 0;

4239:
4240: -- Initialize message list and count if needed
4241: IF p_init_msg_list = fnd_api.g_true THEN
4242: fnd_msg_pub.initialize;
4243: gme_common_pvt.g_error_count := 0;
4244: END IF;
4245:
4246: /* Set the return status to success initially */
4247: x_return_status := fnd_api.g_ret_sts_success;

Line 4250: gme_common_pvt.set_timestamp;

4246: /* Set the return status to success initially */
4247: x_return_status := fnd_api.g_ret_sts_success;
4248:
4249: /* Set the timestamp */
4250: gme_common_pvt.set_timestamp;
4251:
4252: gme_reservations_pvt.auto_detail_batch(p_batch_rec => p_batch_rec
4253: ,x_return_status => x_return_status);
4254:

Line 4258: gme_common_pvt.log_message ('GME_BATCH_AUTO_DETAIL_BATCH');

4254:
4255: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4256: RAISE auto_detail_failure;
4257: END IF;
4258: gme_common_pvt.log_message ('GME_BATCH_AUTO_DETAIL_BATCH');
4259: IF (g_debug <= gme_debug.g_log_procedure) THEN
4260: gme_debug.put_line ( 'Completed '
4261: || l_api_name
4262: || ' at '

Line 4268: gme_common_pvt.count_and_get (x_count => x_message_count,

4264: END IF;
4265: EXCEPTION
4266: WHEN auto_detail_failure OR setup_failure THEN
4267: ROLLBACK TO SAVEPOINT auto_detail_batch;
4268: gme_common_pvt.count_and_get (x_count => x_message_count,
4269: p_encoded => fnd_api.g_false,
4270: x_data => x_message_list);
4271: WHEN OTHERS THEN
4272: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 4283: gme_common_pvt.count_and_get (x_count => x_message_count,

4279: END IF;
4280:
4281: ROLLBACK TO SAVEPOINT auto_detail_batch;
4282: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
4283: gme_common_pvt.count_and_get (x_count => x_message_count,
4284: p_encoded => fnd_api.g_false,
4285: x_data => x_message_list);
4286: x_return_status := fnd_api.g_ret_sts_unexp_error;
4287: END auto_detail_batch;

Line 4292: := gme_common_pvt.g_max_errors

4288:
4289: /*************************************************************************/
4290: PROCEDURE create_pending_product_lot (
4291: p_validation_level IN NUMBER
4292: := gme_common_pvt.g_max_errors
4293: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
4294: ,x_message_count OUT NOCOPY NUMBER
4295: ,x_message_list OUT NOCOPY VARCHAR2
4296: ,x_return_status OUT NOCOPY VARCHAR2

Line 4316: IF NOT gme_common_pvt.g_setup_done THEN

4312: IF (g_debug IS NOT NULL) THEN
4313: gme_debug.log_initialize ('CreatePendingProdLot');
4314: END IF;
4315:
4316: IF NOT gme_common_pvt.g_setup_done THEN
4317: gme_common_pvt.g_setup_done :=
4318: gme_common_pvt.setup (p_org_id);
4319:
4320: IF NOT gme_common_pvt.g_setup_done THEN

Line 4317: gme_common_pvt.g_setup_done :=

4313: gme_debug.log_initialize ('CreatePendingProdLot');
4314: END IF;
4315:
4316: IF NOT gme_common_pvt.g_setup_done THEN
4317: gme_common_pvt.g_setup_done :=
4318: gme_common_pvt.setup (p_org_id);
4319:
4320: IF NOT gme_common_pvt.g_setup_done THEN
4321: x_return_status := fnd_api.g_ret_sts_error;

Line 4318: gme_common_pvt.setup (p_org_id);

4314: END IF;
4315:
4316: IF NOT gme_common_pvt.g_setup_done THEN
4317: gme_common_pvt.g_setup_done :=
4318: gme_common_pvt.setup (p_org_id);
4319:
4320: IF NOT gme_common_pvt.g_setup_done THEN
4321: x_return_status := fnd_api.g_ret_sts_error;
4322: RAISE setup_failure;

Line 4320: IF NOT gme_common_pvt.g_setup_done THEN

4316: IF NOT gme_common_pvt.g_setup_done THEN
4317: gme_common_pvt.g_setup_done :=
4318: gme_common_pvt.setup (p_org_id);
4319:
4320: IF NOT gme_common_pvt.g_setup_done THEN
4321: x_return_status := fnd_api.g_ret_sts_error;
4322: RAISE setup_failure;
4323: END IF;
4324: END IF;

Line 4332: gme_common_pvt.g_error_count := 0;

4328:
4329: -- Initialize message list and count if needed
4330: IF p_init_msg_list = fnd_api.g_true THEN
4331: fnd_msg_pub.initialize;
4332: gme_common_pvt.g_error_count := 0;
4333: END IF;
4334:
4335: gme_common_pvt.set_timestamp;
4336: gme_pending_product_lots_pvt.create_pending_product_lot

Line 4335: gme_common_pvt.set_timestamp;

4331: fnd_msg_pub.initialize;
4332: gme_common_pvt.g_error_count := 0;
4333: END IF;
4334:
4335: gme_common_pvt.set_timestamp;
4336: gme_pending_product_lots_pvt.create_pending_product_lot
4337: (p_pending_product_lots_rec => p_pending_product_lots_rec
4338: ,x_pending_product_lots_rec => x_pending_product_lots_rec
4339: ,x_return_status => x_return_status);

Line 4346: gme_common_pvt.log_message ('GME_API_PP_LOT_CREATED');

4342: RAISE create_pp_lot_failure;
4343: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4344:
4345:
4346: gme_common_pvt.log_message ('GME_API_PP_LOT_CREATED');
4347:
4348: gme_common_pvt.count_and_get (x_count => x_message_count
4349: ,p_encoded => fnd_api.g_false
4350: ,x_data => x_message_list);

Line 4348: gme_common_pvt.count_and_get (x_count => x_message_count

4344:
4345:
4346: gme_common_pvt.log_message ('GME_API_PP_LOT_CREATED');
4347:
4348: gme_common_pvt.count_and_get (x_count => x_message_count
4349: ,p_encoded => fnd_api.g_false
4350: ,x_data => x_message_list);
4351:
4352: IF (g_debug IS NOT NULL) THEN

Line 4366: gme_common_pvt.count_and_get (x_count => x_message_count

4362: EXCEPTION
4363: WHEN create_pp_lot_failure THEN
4364: ROLLBACK TO SAVEPOINT create_pp_lot;
4365: x_pending_product_lots_rec := NULL;
4366: gme_common_pvt.count_and_get (x_count => x_message_count
4367: ,p_encoded => fnd_api.g_false
4368: ,x_data => x_message_list);
4369: WHEN setup_failure THEN
4370: ROLLBACK TO SAVEPOINT create_pp_lot;

Line 4372: gme_common_pvt.count_and_get (x_count => x_message_count

4368: ,x_data => x_message_list);
4369: WHEN setup_failure THEN
4370: ROLLBACK TO SAVEPOINT create_pp_lot;
4371: x_pending_product_lots_rec := NULL;
4372: gme_common_pvt.count_and_get (x_count => x_message_count
4373: ,p_encoded => fnd_api.g_false
4374: ,x_data => x_message_list);
4375: x_return_status := fnd_api.g_ret_sts_error;
4376: WHEN OTHERS THEN

Line 4388: gme_common_pvt.count_and_get (x_count => x_message_count

4384: END IF;
4385:
4386: ROLLBACK TO SAVEPOINT create_pp_lot;
4387: x_pending_product_lots_rec := NULL;
4388: gme_common_pvt.count_and_get (x_count => x_message_count
4389: ,p_encoded => fnd_api.g_false
4390: ,x_data => x_message_list);
4391: x_return_status := fnd_api.g_ret_sts_unexp_error;
4392: END create_pending_product_lot;

Line 4396: := gme_common_pvt.g_max_errors

4392: END create_pending_product_lot;
4393:
4394: PROCEDURE update_pending_product_lot (
4395: p_validation_level IN NUMBER
4396: := gme_common_pvt.g_max_errors
4397: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
4398: ,x_message_count OUT NOCOPY NUMBER
4399: ,x_message_list OUT NOCOPY VARCHAR2
4400: ,x_return_status OUT NOCOPY VARCHAR2

Line 4420: IF NOT gme_common_pvt.g_setup_done THEN

4416: IF (g_debug IS NOT NULL) THEN
4417: gme_debug.log_initialize ('UpdatePendingProdLot');
4418: END IF;
4419:
4420: IF NOT gme_common_pvt.g_setup_done THEN
4421: gme_common_pvt.g_setup_done :=
4422: gme_common_pvt.setup (p_org_id);
4423:
4424: IF NOT gme_common_pvt.g_setup_done THEN

Line 4421: gme_common_pvt.g_setup_done :=

4417: gme_debug.log_initialize ('UpdatePendingProdLot');
4418: END IF;
4419:
4420: IF NOT gme_common_pvt.g_setup_done THEN
4421: gme_common_pvt.g_setup_done :=
4422: gme_common_pvt.setup (p_org_id);
4423:
4424: IF NOT gme_common_pvt.g_setup_done THEN
4425: x_return_status := fnd_api.g_ret_sts_error;

Line 4422: gme_common_pvt.setup (p_org_id);

4418: END IF;
4419:
4420: IF NOT gme_common_pvt.g_setup_done THEN
4421: gme_common_pvt.g_setup_done :=
4422: gme_common_pvt.setup (p_org_id);
4423:
4424: IF NOT gme_common_pvt.g_setup_done THEN
4425: x_return_status := fnd_api.g_ret_sts_error;
4426: RAISE setup_failure;

Line 4424: IF NOT gme_common_pvt.g_setup_done THEN

4420: IF NOT gme_common_pvt.g_setup_done THEN
4421: gme_common_pvt.g_setup_done :=
4422: gme_common_pvt.setup (p_org_id);
4423:
4424: IF NOT gme_common_pvt.g_setup_done THEN
4425: x_return_status := fnd_api.g_ret_sts_error;
4426: RAISE setup_failure;
4427: END IF;
4428: END IF;

Line 4436: gme_common_pvt.g_error_count := 0;

4432:
4433: -- Initialize message list and count if needed
4434: IF p_init_msg_list = fnd_api.g_true THEN
4435: fnd_msg_pub.initialize;
4436: gme_common_pvt.g_error_count := 0;
4437: END IF;
4438:
4439: gme_common_pvt.set_timestamp;
4440: gme_pending_product_lots_pvt.update_pending_product_lot

Line 4439: gme_common_pvt.set_timestamp;

4435: fnd_msg_pub.initialize;
4436: gme_common_pvt.g_error_count := 0;
4437: END IF;
4438:
4439: gme_common_pvt.set_timestamp;
4440: gme_pending_product_lots_pvt.update_pending_product_lot
4441: (p_pending_product_lots_rec => p_pending_product_lots_rec
4442: ,x_pending_product_lots_rec => x_pending_product_lots_rec
4443: ,x_return_status => x_return_status);

Line 4450: gme_common_pvt.log_message ('GME_API_PP_LOT_UPDATED');

4446: RAISE update_pp_lot_failure;
4447: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4448:
4449:
4450: gme_common_pvt.log_message ('GME_API_PP_LOT_UPDATED');
4451:
4452:
4453: gme_common_pvt.count_and_get (x_count => x_message_count
4454: ,p_encoded => fnd_api.g_false

Line 4453: gme_common_pvt.count_and_get (x_count => x_message_count

4449:
4450: gme_common_pvt.log_message ('GME_API_PP_LOT_UPDATED');
4451:
4452:
4453: gme_common_pvt.count_and_get (x_count => x_message_count
4454: ,p_encoded => fnd_api.g_false
4455: ,x_data => x_message_list);
4456:
4457: IF (g_debug IS NOT NULL) THEN

Line 4471: gme_common_pvt.count_and_get (x_count => x_message_count

4467: EXCEPTION
4468: WHEN update_pp_lot_failure THEN
4469: ROLLBACK TO SAVEPOINT update_pp_lot;
4470: x_pending_product_lots_rec := NULL;
4471: gme_common_pvt.count_and_get (x_count => x_message_count
4472: ,p_encoded => fnd_api.g_false
4473: ,x_data => x_message_list);
4474: WHEN setup_failure THEN
4475: ROLLBACK TO SAVEPOINT update_pp_lot;

Line 4477: gme_common_pvt.count_and_get (x_count => x_message_count

4473: ,x_data => x_message_list);
4474: WHEN setup_failure THEN
4475: ROLLBACK TO SAVEPOINT update_pp_lot;
4476: x_pending_product_lots_rec := NULL;
4477: gme_common_pvt.count_and_get (x_count => x_message_count
4478: ,p_encoded => fnd_api.g_false
4479: ,x_data => x_message_list);
4480: x_return_status := fnd_api.g_ret_sts_error;
4481: WHEN OTHERS THEN

Line 4493: gme_common_pvt.count_and_get (x_count => x_message_count

4489: END IF;
4490:
4491: ROLLBACK TO SAVEPOINT update_pp_lot;
4492: x_pending_product_lots_rec := NULL;
4493: gme_common_pvt.count_and_get (x_count => x_message_count
4494: ,p_encoded => fnd_api.g_false
4495: ,x_data => x_message_list);
4496: x_return_status := fnd_api.g_ret_sts_unexp_error;
4497: END update_pending_product_lot;

Line 4501: := gme_common_pvt.g_max_errors

4497: END update_pending_product_lot;
4498:
4499: PROCEDURE delete_pending_product_lot (
4500: p_validation_level IN NUMBER
4501: := gme_common_pvt.g_max_errors
4502: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
4503: ,x_message_count OUT NOCOPY NUMBER
4504: ,x_message_list OUT NOCOPY VARCHAR2
4505: ,x_return_status OUT NOCOPY VARCHAR2

Line 4524: IF NOT gme_common_pvt.g_setup_done THEN

4520: IF (g_debug IS NOT NULL) THEN
4521: gme_debug.log_initialize ('DeletePendingProdLot');
4522: END IF;
4523:
4524: IF NOT gme_common_pvt.g_setup_done THEN
4525: gme_common_pvt.g_setup_done :=
4526: gme_common_pvt.setup (p_org_id);
4527:
4528: IF NOT gme_common_pvt.g_setup_done THEN

Line 4525: gme_common_pvt.g_setup_done :=

4521: gme_debug.log_initialize ('DeletePendingProdLot');
4522: END IF;
4523:
4524: IF NOT gme_common_pvt.g_setup_done THEN
4525: gme_common_pvt.g_setup_done :=
4526: gme_common_pvt.setup (p_org_id);
4527:
4528: IF NOT gme_common_pvt.g_setup_done THEN
4529: x_return_status := fnd_api.g_ret_sts_error;

Line 4526: gme_common_pvt.setup (p_org_id);

4522: END IF;
4523:
4524: IF NOT gme_common_pvt.g_setup_done THEN
4525: gme_common_pvt.g_setup_done :=
4526: gme_common_pvt.setup (p_org_id);
4527:
4528: IF NOT gme_common_pvt.g_setup_done THEN
4529: x_return_status := fnd_api.g_ret_sts_error;
4530: RAISE setup_failure;

Line 4528: IF NOT gme_common_pvt.g_setup_done THEN

4524: IF NOT gme_common_pvt.g_setup_done THEN
4525: gme_common_pvt.g_setup_done :=
4526: gme_common_pvt.setup (p_org_id);
4527:
4528: IF NOT gme_common_pvt.g_setup_done THEN
4529: x_return_status := fnd_api.g_ret_sts_error;
4530: RAISE setup_failure;
4531: END IF;
4532: END IF;

Line 4540: gme_common_pvt.g_error_count := 0;

4536:
4537: -- Initialize message list and count if needed
4538: IF p_init_msg_list = fnd_api.g_true THEN
4539: fnd_msg_pub.initialize;
4540: gme_common_pvt.g_error_count := 0;
4541: END IF;
4542:
4543: gme_common_pvt.set_timestamp;
4544: gme_pending_product_lots_pvt.delete_pending_product_lot

Line 4543: gme_common_pvt.set_timestamp;

4539: fnd_msg_pub.initialize;
4540: gme_common_pvt.g_error_count := 0;
4541: END IF;
4542:
4543: gme_common_pvt.set_timestamp;
4544: gme_pending_product_lots_pvt.delete_pending_product_lot
4545: (p_pending_product_lots_rec => p_pending_product_lots_rec
4546: ,x_return_status => x_return_status);
4547:

Line 4552: gme_common_pvt.log_message ('GME_API_PP_LOT_DELETED');

4548: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4549: RAISE delete_pp_lot_failure;
4550: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4551:
4552: gme_common_pvt.log_message ('GME_API_PP_LOT_DELETED');
4553:
4554:
4555: gme_common_pvt.count_and_get (x_count => x_message_count
4556: ,p_encoded => fnd_api.g_false

Line 4555: gme_common_pvt.count_and_get (x_count => x_message_count

4551:
4552: gme_common_pvt.log_message ('GME_API_PP_LOT_DELETED');
4553:
4554:
4555: gme_common_pvt.count_and_get (x_count => x_message_count
4556: ,p_encoded => fnd_api.g_false
4557: ,x_data => x_message_list);
4558:
4559: IF (g_debug IS NOT NULL) THEN

Line 4572: gme_common_pvt.count_and_get (x_count => x_message_count

4568: END IF;
4569: EXCEPTION
4570: WHEN delete_pp_lot_failure THEN
4571: ROLLBACK TO SAVEPOINT delete_pp_lot;
4572: gme_common_pvt.count_and_get (x_count => x_message_count
4573: ,p_encoded => fnd_api.g_false
4574: ,x_data => x_message_list);
4575: WHEN setup_failure THEN
4576: ROLLBACK TO SAVEPOINT delete_pp_lot;

Line 4577: gme_common_pvt.count_and_get (x_count => x_message_count

4573: ,p_encoded => fnd_api.g_false
4574: ,x_data => x_message_list);
4575: WHEN setup_failure THEN
4576: ROLLBACK TO SAVEPOINT delete_pp_lot;
4577: gme_common_pvt.count_and_get (x_count => x_message_count
4578: ,p_encoded => fnd_api.g_false
4579: ,x_data => x_message_list);
4580: x_return_status := fnd_api.g_ret_sts_error;
4581: WHEN OTHERS THEN

Line 4592: gme_common_pvt.count_and_get (x_count => x_message_count

4588: || SQLERRM);
4589: END IF;
4590:
4591: ROLLBACK TO SAVEPOINT delete_pp_lot;
4592: gme_common_pvt.count_and_get (x_count => x_message_count
4593: ,p_encoded => fnd_api.g_false
4594: ,x_data => x_message_list);
4595: x_return_status := fnd_api.g_ret_sts_unexp_error;
4596: END delete_pending_product_lot;