DBA Data[Home] [Help]

APPS.GME_API_MAIN dependencies on FND_API

Line 10: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

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
14: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 24: ,p_ignore_qty_below_cap IN VARCHAR2 := fnd_api.g_true

20: ,p_recipe_no IN VARCHAR2 := NULL
21: ,p_recipe_version IN NUMBER := NULL
22: ,p_product_no IN VARCHAR2 := NULL
23: ,p_product_id IN NUMBER := NULL
24: ,p_ignore_qty_below_cap IN VARCHAR2 := fnd_api.g_true
25: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true
26: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_false
27: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false
28: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)

Line 25: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true

21: ,p_recipe_version IN NUMBER := NULL
22: ,p_product_no IN VARCHAR2 := NULL
23: ,p_product_id IN NUMBER := NULL
24: ,p_ignore_qty_below_cap IN VARCHAR2 := fnd_api.g_true
25: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true
26: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_false
27: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false
28: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)
29: IS

Line 26: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_false

22: ,p_product_no IN VARCHAR2 := NULL
23: ,p_product_id IN NUMBER := NULL
24: ,p_ignore_qty_below_cap IN VARCHAR2 := fnd_api.g_true
25: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true
26: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_false
27: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false
28: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)
29: IS
30: l_api_name CONSTANT VARCHAR2 (30) := 'CREATE_BATCH';

Line 27: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false

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

Line 51: x_return_status := fnd_api.g_ret_sts_error;

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

Line 57: x_return_status := fnd_api.g_ret_sts_success;

53: END IF;
54: END IF;
55:
56: /* Set the return status to success initially */
57: x_return_status := fnd_api.g_ret_sts_success;
58:
59: -- Initialize message list and count if needed
60: IF p_init_msg_list = fnd_api.g_true THEN
61: fnd_msg_pub.initialize;

Line 60: IF p_init_msg_list = fnd_api.g_true THEN

56: /* Set the return status to success initially */
57: x_return_status := fnd_api.g_ret_sts_success;
58:
59: -- Initialize message list and count if needed
60: IF p_init_msg_list = fnd_api.g_true THEN
61: fnd_msg_pub.initialize;
62: gme_common_pvt.g_error_count := 0;
63: END IF;
64:

Line 80: IF x_return_status <> fnd_api.g_ret_sts_success THEN

76: ,x_batch_header_rec => x_batch_header_rec
77: ,x_exception_material_tbl => x_exception_material_tbl
78: ,x_return_status => x_return_status);
79:
80: IF x_return_status <> fnd_api.g_ret_sts_success THEN
81: RAISE batch_creation_failure;
82: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
83:
84: IF x_message_count = 0 THEN

Line 82: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

78: ,x_return_status => x_return_status);
79:
80: IF x_return_status <> fnd_api.g_ret_sts_success THEN
81: RAISE batch_creation_failure;
82: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
83:
84: IF x_message_count = 0 THEN
85: gme_common_pvt.log_message ('GME_API_BATCH_CREATED');
86: END IF;

Line 89: ,p_encoded => fnd_api.g_false

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

Line 110: ,p_encoded => fnd_api.g_false

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

Line 116: ,p_encoded => fnd_api.g_false

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

Line 118: x_return_status := fnd_api.g_ret_sts_error;

114: x_batch_header_rec := NULL;
115: gme_common_pvt.count_and_get (x_count => x_message_count
116: ,p_encoded => fnd_api.g_false
117: ,x_data => x_message_list);
118: x_return_status := fnd_api.g_ret_sts_error;
119: WHEN OTHERS THEN
120: IF g_debug <= gme_debug.g_log_unexpected THEN
121: gme_debug.put_line ( 'When others exception in '
122: || g_pkg_name

Line 132: ,p_encoded => fnd_api.g_false

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

Line 134: x_return_status := fnd_api.g_ret_sts_unexp_error;

130: x_batch_header_rec := NULL;
131: gme_common_pvt.count_and_get (x_count => x_message_count
132: ,p_encoded => fnd_api.g_false
133: ,x_data => x_message_list);
134: x_return_status := fnd_api.g_ret_sts_unexp_error;
135: END create_batch;
136:
137: /*************************************************************************/
138: PROCEDURE create_phantom (

Line 141: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

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

Line 150: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true

146: ,p_batch_header_rec IN gme_batch_header%ROWTYPE --Bug#6738476
147: ,p_batch_no IN VARCHAR2 DEFAULT NULL
148: ,x_material_detail_rec OUT NOCOPY gme_material_details%ROWTYPE
149: ,p_validity_rule_id IN NUMBER
150: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true
151: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_true
152: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false
153: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)
154: IS

Line 151: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_true

147: ,p_batch_no IN VARCHAR2 DEFAULT NULL
148: ,x_material_detail_rec OUT NOCOPY gme_material_details%ROWTYPE
149: ,p_validity_rule_id IN NUMBER
150: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true
151: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_true
152: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false
153: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)
154: IS
155: l_api_name CONSTANT VARCHAR2 (30) := 'CREATE_PHANTOM';

Line 152: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false

148: ,x_material_detail_rec OUT NOCOPY gme_material_details%ROWTYPE
149: ,p_validity_rule_id IN NUMBER
150: ,p_use_workday_cal IN VARCHAR2 := fnd_api.g_true
151: ,p_contiguity_override IN VARCHAR2 := fnd_api.g_true
152: ,p_use_least_cost_validity_rule IN VARCHAR2 := fnd_api.g_false
153: ,x_exception_material_tbl OUT NOCOPY gme_common_pvt.exceptions_tab)
154: IS
155: l_api_name CONSTANT VARCHAR2 (30) := 'CREATE_PHANTOM';
156: setup_failure EXCEPTION;

Line 177: x_return_status := fnd_api.g_ret_sts_error;

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

Line 183: IF p_init_msg_list = fnd_api.g_true THEN

179: END IF;
180: END IF;
181:
182: -- Initialize message list and count if needed
183: IF p_init_msg_list = fnd_api.g_true THEN
184: fnd_msg_pub.initialize;
185: gme_common_pvt.g_error_count := 0;
186: END IF;
187:

Line 189: x_return_status := fnd_api.g_ret_sts_success;

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

Line 203: IF x_return_status <> fnd_api.g_ret_sts_success THEN

199: ,p_use_least_cost_validity_rule => p_use_least_cost_validity_rule
200: ,x_exception_material_tbl => x_exception_material_tbl
201: ,x_return_status => x_return_status);
202:
203: IF x_return_status <> fnd_api.g_ret_sts_success THEN
204: RAISE phantom_creation_failure;
205: END IF;
206:
207: IF (g_debug <= gme_debug.g_log_procedure) THEN

Line 218: ,p_encoded => fnd_api.g_false

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

Line 234: ,p_encoded => fnd_api.g_false

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

Line 236: x_return_status := fnd_api.g_ret_sts_unexp_error;

232: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
233: gme_common_pvt.count_and_get (x_count => x_message_count
234: ,p_encoded => fnd_api.g_false
235: ,x_data => x_message_list);
236: x_return_status := fnd_api.g_ret_sts_unexp_error;
237: END create_phantom;
238:
239: PROCEDURE scale_batch (
240: p_validation_level IN NUMBER

Line 279: x_return_status := fnd_api.g_ret_sts_error;

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

Line 286: IF p_init_msg_list = fnd_api.g_true THEN

282: END IF;
283:
284:
285: /* Initialize message list and count if needed */
286: IF p_init_msg_list = fnd_api.g_true THEN
287: fnd_msg_pub.initialize;
288: gme_common_pvt.g_error_count := 0;
289: END IF;
290:

Line 307: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, 'C', 'W') THEN

303: ,x_batch_header_rec => x_batch_header_rec
304: ,x_return_status => x_return_status);
305: x_message_count := 0;
306: -- pawan kumar bug 5358705 add condition for different return status 'c' and 'w'
307: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, 'C', 'W') THEN
308: RAISE scale_batch_failed;
309: END IF;
310: gme_common_pvt.log_message ('GME_SCALE_SUCCESS');
311: IF (g_debug <= gme_debug.g_log_procedure) THEN

Line 321: x_return_status := fnd_api.g_ret_sts_error;

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

Line 323: ,p_encoded => fnd_api.g_false

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

Line 329: ,p_encoded => fnd_api.g_false

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

Line 335: ,p_encoded => fnd_api.g_false

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

Line 342: ,p_encoded => fnd_api.g_false

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

Line 344: x_return_status := fnd_api.g_ret_sts_unexp_error;

340: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
341: gme_common_pvt.count_and_get (x_count => x_message_count
342: ,p_encoded => fnd_api.g_false
343: ,x_data => x_message_list);
344: x_return_status := fnd_api.g_ret_sts_unexp_error;
345: END scale_batch;
346:
347: /*************************************************************************/
348: PROCEDURE theoretical_yield_batch (

Line 387: IF p_init_msg_list = fnd_api.g_true THEN

383: END IF;
384: END IF;
385:
386: /* Initialize message list and count if needed */
387: IF p_init_msg_list = fnd_api.g_true THEN
388: fnd_msg_pub.initialize;
389: gme_common_pvt.g_error_count := 0;
390: END IF;
391:

Line 398: IF x_return_status <> fnd_api.g_ret_sts_success THEN

394: (p_batch_header_rec => p_batch_header_rec
395: ,p_scale_factor => p_scale_factor
396: ,x_return_status => x_return_status);
397:
398: IF x_return_status <> fnd_api.g_ret_sts_success THEN
399: RAISE theoretical_yield_failed;
400: END IF;
401:
402: gme_common_pvt.count_and_get (x_count => x_message_count

Line 403: ,p_encoded => fnd_api.g_false

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

Line 415: x_return_status := fnd_api.g_ret_sts_error;

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

Line 417: ,p_encoded => fnd_api.g_false

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

Line 422: ,p_encoded => fnd_api.g_false

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

Line 428: ,p_encoded => fnd_api.g_false

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

Line 430: x_return_status := fnd_api.g_ret_sts_unexp_error;

426: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
427: gme_common_pvt.count_and_get (x_count => x_message_count
428: ,p_encoded => fnd_api.g_false
429: ,x_data => x_message_list);
430: x_return_status := fnd_api.g_ret_sts_unexp_error;
431: END theoretical_yield_batch;
432:
433: /*************************************************************************/
434: PROCEDURE insert_material_line (

Line 437: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

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

Line 461: x_return_status := fnd_api.g_ret_sts_success;

457: l_message_list VARCHAR2(2000);
458: BEGIN
459:
460: /* Set the return status to success initially */
461: x_return_status := fnd_api.g_ret_sts_success;
462:
463: SAVEPOINT insert_material_line1;
464:
465: IF (g_debug IS NOT NULL) THEN

Line 479: x_return_status := fnd_api.g_ret_sts_error;

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

Line 485: IF p_init_msg_list = fnd_api.g_true THEN

481: END IF;
482: END IF;
483:
484: -- Initialize message list and count if needed
485: IF p_init_msg_list = fnd_api.g_true THEN
486: fnd_msg_pub.initialize;
487: gme_common_pvt.g_error_count := 0;
488: END IF;
489:

Line 496: RAISE fnd_api.g_exc_error;

492: IF p_batch_step_id IS NOT NULL THEN
493: l_batch_step_rec.batchstep_id := p_batch_step_id;
494:
495: IF NOT gme_batch_steps_dbl.fetch_row(l_batch_step_rec, l_batch_step_rec) THEN
496: RAISE fnd_api.g_exc_error;
497: END IF;
498: END IF;
499:
500: insert_material_line (p_validation_level => p_validation_level

Line 512: IF x_return_status <> fnd_api.g_ret_sts_success THEN

508: ,p_trans_id => p_trans_id
509: ,x_transacted => x_transacted
510: ,x_material_detail_rec => x_material_detail_rec);
511:
512: IF x_return_status <> fnd_api.g_ret_sts_success THEN
513: RAISE ins_mtl_line_failure;
514: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
515:
516: --

Line 514: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

510: ,x_material_detail_rec => x_material_detail_rec);
511:
512: IF x_return_status <> fnd_api.g_ret_sts_success THEN
513: RAISE ins_mtl_line_failure;
514: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
515:
516: --
517: -- Bug 5903208 -- call to GMF
518: GMF_VIB.Update_Batch_Requirements

Line 520: p_init_msg_list => FND_API.G_FALSE,

516: --
517: -- Bug 5903208 -- call to GMF
518: GMF_VIB.Update_Batch_Requirements
519: ( p_api_version => 1.0,
520: p_init_msg_list => FND_API.G_FALSE,
521: p_batch_id => p_batch_header_rec.batch_id,
522: x_return_status => x_return_status,
523: x_msg_count => l_message_count,
524: x_msg_data => l_message_list);

Line 526: IF x_return_status <> FND_API.G_RET_STS_SUCCESS

522: x_return_status => x_return_status,
523: x_msg_count => l_message_count,
524: x_msg_data => l_message_list);
525:
526: IF x_return_status <> FND_API.G_RET_STS_SUCCESS
527: THEN
528: RAISE gmf_cost_failure;
529: END IF;
530: -- NEW

Line 542: IF x_return_status <> fnd_api.g_ret_sts_success THEN

538: ,P_PARENT_EVENT => NULL
539: ,P_PARENT_EVENT_KEY => NULL
540: ,P_PARENT_ERECORD_ID => NULL
541: ,X_STATUS => x_return_status);
542: IF x_return_status <> fnd_api.g_ret_sts_success THEN
543: RAISE ins_mtl_line_failure;
544: END IF;
545:
546: gme_common_pvt.count_and_get (x_count => x_message_count

Line 547: ,p_encoded => fnd_api.g_false

543: RAISE ins_mtl_line_failure;
544: END IF;
545:
546: gme_common_pvt.count_and_get (x_count => x_message_count
547: ,p_encoded => fnd_api.g_false
548: ,x_data => x_message_list);
549:
550: IF (g_debug IS NOT NULL) THEN
551: gme_debug.put_line ( 'Completed '

Line 557: x_return_status := fnd_api.g_ret_sts_success;

553: || ' at '
554: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
555: END IF;
556: IF (x_return_status IS NULL) THEN
557: x_return_status := fnd_api.g_ret_sts_success;
558: END IF;
559: EXCEPTION
560: WHEN gmf_cost_failure THEN
561: -- Bug 5903208

Line 562: x_return_status := FND_API.G_RET_STS_ERROR;

558: END IF;
559: EXCEPTION
560: WHEN gmf_cost_failure THEN
561: -- Bug 5903208
562: x_return_status := FND_API.G_RET_STS_ERROR;
563:
564: WHEN ins_mtl_line_failure THEN
565: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
566: ROLLBACK TO SAVEPOINT insert_material_line1;

Line 571: ,p_encoded => fnd_api.g_false

567: x_material_detail_rec := NULL;
568: END IF;
569:
570: gme_common_pvt.count_and_get (x_count => x_message_count
571: ,p_encoded => fnd_api.g_false
572: ,x_data => x_message_list);
573: WHEN setup_failure THEN
574: ROLLBACK TO SAVEPOINT insert_material_line1;
575: x_material_detail_rec := NULL;

Line 577: ,p_encoded => fnd_api.g_false

573: WHEN setup_failure THEN
574: ROLLBACK TO SAVEPOINT insert_material_line1;
575: x_material_detail_rec := NULL;
576: gme_common_pvt.count_and_get (x_count => x_message_count
577: ,p_encoded => fnd_api.g_false
578: ,x_data => x_message_list);
579: x_return_status := fnd_api.g_ret_sts_error;
580: WHEN OTHERS THEN
581: ROLLBACK TO SAVEPOINT insert_material_line1;

Line 579: x_return_status := fnd_api.g_ret_sts_error;

575: x_material_detail_rec := NULL;
576: gme_common_pvt.count_and_get (x_count => x_message_count
577: ,p_encoded => fnd_api.g_false
578: ,x_data => x_message_list);
579: x_return_status := fnd_api.g_ret_sts_error;
580: WHEN OTHERS THEN
581: ROLLBACK TO SAVEPOINT insert_material_line1;
582: x_material_detail_rec := NULL;
583:

Line 594: ,p_encoded => fnd_api.g_false

590: || SQLERRM);
591: END IF;
592:
593: gme_common_pvt.count_and_get (x_count => x_message_count
594: ,p_encoded => fnd_api.g_false
595: ,x_data => x_message_list);
596: x_return_status := fnd_api.g_ret_sts_unexp_error;
597: END insert_material_line;
598:

Line 596: x_return_status := fnd_api.g_ret_sts_unexp_error;

592:
593: gme_common_pvt.count_and_get (x_count => x_message_count
594: ,p_encoded => fnd_api.g_false
595: ,x_data => x_message_list);
596: x_return_status := fnd_api.g_ret_sts_unexp_error;
597: END insert_material_line;
598:
599: /*************************************************************************/
600: PROCEDURE insert_material_line (

Line 603: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

599: /*************************************************************************/
600: PROCEDURE insert_material_line (
601: p_validation_level IN NUMBER
602: := gme_common_pvt.g_max_errors
603: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
604: ,x_message_count OUT NOCOPY NUMBER
605: ,x_message_list OUT NOCOPY VARCHAR2
606: ,x_return_status OUT NOCOPY VARCHAR2
607: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 620: x_return_status := fnd_api.g_ret_sts_success;

616: ins_mtl_line_failure EXCEPTION;
617: BEGIN
618:
619: /* Set the return status to success initially */
620: x_return_status := fnd_api.g_ret_sts_success;
621:
622: SAVEPOINT insert_material_line;
623:
624: IF (g_debug IS NOT NULL) THEN

Line 638: x_return_status := fnd_api.g_ret_sts_error;

634: gme_common_pvt.g_setup_done :=
635: gme_common_pvt.setup (p_batch_header_rec.organization_id);
636:
637: IF NOT gme_common_pvt.g_setup_done THEN
638: x_return_status := fnd_api.g_ret_sts_error;
639: RAISE setup_failure;
640: END IF;
641: END IF;
642:

Line 644: IF p_init_msg_list = fnd_api.g_true THEN

640: END IF;
641: END IF;
642:
643: -- Initialize message list and count if needed
644: IF p_init_msg_list = fnd_api.g_true THEN
645: fnd_msg_pub.initialize;
646: gme_common_pvt.g_error_count := 0;
647: END IF;
648:

Line 660: IF x_return_status <> fnd_api.g_ret_sts_success THEN

656: ,x_transacted => x_transacted
657: ,x_material_detail_rec => x_material_detail_rec
658: ,x_return_status => x_return_status);
659:
660: IF x_return_status <> fnd_api.g_ret_sts_success THEN
661: RAISE ins_mtl_line_failure;
662: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
663:
664: gme_common_pvt.log_message ('GME_MTL_LINE_INSERTED');

Line 662: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

658: ,x_return_status => x_return_status);
659:
660: IF x_return_status <> fnd_api.g_ret_sts_success THEN
661: RAISE ins_mtl_line_failure;
662: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
663:
664: gme_common_pvt.log_message ('GME_MTL_LINE_INSERTED');
665:
666:

Line 668: ,p_encoded => fnd_api.g_false

664: gme_common_pvt.log_message ('GME_MTL_LINE_INSERTED');
665:
666:
667: gme_common_pvt.count_and_get (x_count => x_message_count
668: ,p_encoded => fnd_api.g_false
669: ,x_data => x_message_list);
670:
671: IF (g_debug IS NOT NULL) THEN
672: gme_debug.put_line ( 'Completed '

Line 678: x_return_status := fnd_api.g_ret_sts_success;

674: || ' at '
675: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
676: END IF;
677: IF (x_return_status IS NULL) THEN
678: x_return_status := fnd_api.g_ret_sts_success;
679: END IF;
680: EXCEPTION
681: WHEN ins_mtl_line_failure THEN
682: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

Line 688: ,p_encoded => fnd_api.g_false

684: x_material_detail_rec := NULL;
685: END IF;
686:
687: gme_common_pvt.count_and_get (x_count => x_message_count
688: ,p_encoded => fnd_api.g_false
689: ,x_data => x_message_list);
690: WHEN setup_failure THEN
691: ROLLBACK TO SAVEPOINT insert_material_line;
692: x_material_detail_rec := NULL;

Line 694: ,p_encoded => fnd_api.g_false

690: WHEN setup_failure THEN
691: ROLLBACK TO SAVEPOINT insert_material_line;
692: x_material_detail_rec := NULL;
693: gme_common_pvt.count_and_get (x_count => x_message_count
694: ,p_encoded => fnd_api.g_false
695: ,x_data => x_message_list);
696: x_return_status := fnd_api.g_ret_sts_error;
697: WHEN OTHERS THEN
698: ROLLBACK TO SAVEPOINT insert_material_line;

Line 696: x_return_status := fnd_api.g_ret_sts_error;

692: x_material_detail_rec := NULL;
693: gme_common_pvt.count_and_get (x_count => x_message_count
694: ,p_encoded => fnd_api.g_false
695: ,x_data => x_message_list);
696: x_return_status := fnd_api.g_ret_sts_error;
697: WHEN OTHERS THEN
698: ROLLBACK TO SAVEPOINT insert_material_line;
699: x_material_detail_rec := NULL;
700:

Line 711: ,p_encoded => fnd_api.g_false

707: || SQLERRM);
708: END IF;
709:
710: gme_common_pvt.count_and_get (x_count => x_message_count
711: ,p_encoded => fnd_api.g_false
712: ,x_data => x_message_list);
713: x_return_status := fnd_api.g_ret_sts_unexp_error;
714: END insert_material_line;
715:

Line 713: x_return_status := fnd_api.g_ret_sts_unexp_error;

709:
710: gme_common_pvt.count_and_get (x_count => x_message_count
711: ,p_encoded => fnd_api.g_false
712: ,x_data => x_message_list);
713: x_return_status := fnd_api.g_ret_sts_unexp_error;
714: END insert_material_line;
715:
716: /*************************************************************************/
717: PROCEDURE update_material_line (

Line 721: := fnd_api.g_false

717: PROCEDURE update_material_line (
718: p_validation_level IN NUMBER
719: := gme_common_pvt.g_max_errors
720: ,p_init_msg_list IN VARCHAR2
721: := fnd_api.g_false
722: ,x_message_count OUT NOCOPY NUMBER
723: ,x_message_list OUT NOCOPY VARCHAR2
724: ,x_return_status OUT NOCOPY VARCHAR2
725: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 728: ,p_scale_phantom IN VARCHAR2 := fnd_api.g_false

724: ,x_return_status OUT NOCOPY VARCHAR2
725: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
726: ,p_material_detail_rec IN gme_material_details%ROWTYPE
727: ,p_batch_step_id IN NUMBER := NULL
728: ,p_scale_phantom IN VARCHAR2 := fnd_api.g_false
729: ,p_trans_id IN NUMBER
730: ,x_transacted OUT NOCOPY VARCHAR2
731: ,x_material_detail_rec OUT NOCOPY gme_material_details%ROWTYPE)
732: IS

Line 743: x_return_status := fnd_api.g_ret_sts_success;

739: setup_failure EXCEPTION;
740: BEGIN
741:
742: /* Set the return status to success initially */
743: x_return_status := fnd_api.g_ret_sts_success;
744:
745: SAVEPOINT update_material_line1;
746:
747: IF (g_debug IS NOT NULL) THEN

Line 761: x_return_status := fnd_api.g_ret_sts_error;

757: gme_common_pvt.g_setup_done :=
758: gme_common_pvt.setup (p_batch_header_rec.organization_id);
759:
760: IF NOT gme_common_pvt.g_setup_done THEN
761: x_return_status := fnd_api.g_ret_sts_error;
762: RAISE setup_failure;
763: END IF;
764: END IF;
765:

Line 767: IF p_init_msg_list = fnd_api.g_true THEN

763: END IF;
764: END IF;
765:
766: -- Initialize message list and count if needed
767: IF p_init_msg_list = fnd_api.g_true THEN
768: fnd_msg_pub.initialize;
769: gme_common_pvt.g_error_count := 0;
770: END IF;
771:

Line 778: RAISE fnd_api.g_exc_error;

774: IF p_batch_step_id IS NOT NULL THEN
775: l_batch_step_rec.batchstep_id := p_batch_step_id;
776:
777: IF NOT gme_batch_steps_dbl.fetch_row(l_batch_step_rec, l_batch_step_rec) THEN
778: RAISE fnd_api.g_exc_error;
779: END IF;
780: END IF;
781:
782: l_stored_material_detail_rec.material_detail_id := p_material_detail_rec.material_detail_id;

Line 786: RAISE fnd_api.g_exc_error;

782: l_stored_material_detail_rec.material_detail_id := p_material_detail_rec.material_detail_id;
783:
784: IF NOT gme_material_details_dbl.fetch_row
785: (l_stored_material_detail_rec,l_stored_material_detail_rec) THEN
786: RAISE fnd_api.g_exc_error;
787: END IF;
788:
789: update_material_line
790: (p_validation_level => p_validation_level

Line 804: IF x_return_status <> fnd_api.g_ret_sts_success THEN

800: ,p_trans_id => p_trans_id
801: ,x_transacted => x_transacted
802: ,x_material_detail_rec => x_material_detail_rec);
803:
804: IF x_return_status <> fnd_api.g_ret_sts_success THEN
805: RAISE upd_mtl_line_failure;
806: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
807:
808: -- NEW

Line 806: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

802: ,x_material_detail_rec => x_material_detail_rec);
803:
804: IF x_return_status <> fnd_api.g_ret_sts_success THEN
805: RAISE upd_mtl_line_failure;
806: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
807:
808: -- NEW
809: GME_ERES_PKG.INSERT_EVENT(P_EVENT_NAME => gme_common_pvt.G_BATCHMTL_UPDATED
810: ,P_EVENT_KEY => p_material_detail_rec.batch_id||'-'||p_material_detail_rec.material_detail_id

Line 821: IF x_return_status <> fnd_api.g_ret_sts_success THEN

817: ,P_PARENT_EVENT_KEY => NULL
818: ,P_PARENT_ERECORD_ID => NULL
819: ,X_STATUS => x_return_status);
820:
821: IF x_return_status <> fnd_api.g_ret_sts_success THEN
822: RAISE upd_mtl_line_failure;
823: END IF;
824:
825: gme_common_pvt.count_and_get (x_count => x_message_count

Line 826: ,p_encoded => fnd_api.g_false

822: RAISE upd_mtl_line_failure;
823: END IF;
824:
825: gme_common_pvt.count_and_get (x_count => x_message_count
826: ,p_encoded => fnd_api.g_false
827: ,x_data => x_message_list);
828:
829: IF (g_debug IS NOT NULL) THEN
830: gme_debug.put_line ( 'Completed '

Line 836: x_return_status := fnd_api.g_ret_sts_success;

832: || ' at '
833: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
834: END IF;
835: IF (x_return_status IS NULL) THEN
836: x_return_status := fnd_api.g_ret_sts_success;
837: END IF;
838: EXCEPTION
839: WHEN upd_mtl_line_failure THEN
840: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

Line 846: ,p_encoded => fnd_api.g_false

842: x_material_detail_rec := NULL;
843: END IF;
844:
845: gme_common_pvt.count_and_get (x_count => x_message_count
846: ,p_encoded => fnd_api.g_false
847: ,x_data => x_message_list);
848: WHEN setup_failure THEN
849: ROLLBACK TO SAVEPOINT update_material_line1;
850: x_material_detail_rec := NULL;

Line 852: ,p_encoded => fnd_api.g_false

848: WHEN setup_failure THEN
849: ROLLBACK TO SAVEPOINT update_material_line1;
850: x_material_detail_rec := NULL;
851: gme_common_pvt.count_and_get (x_count => x_message_count
852: ,p_encoded => fnd_api.g_false
853: ,x_data => x_message_list);
854: x_return_status := fnd_api.g_ret_sts_error;
855: WHEN OTHERS THEN
856: ROLLBACK TO SAVEPOINT update_material_line1;

Line 854: x_return_status := fnd_api.g_ret_sts_error;

850: x_material_detail_rec := NULL;
851: gme_common_pvt.count_and_get (x_count => x_message_count
852: ,p_encoded => fnd_api.g_false
853: ,x_data => x_message_list);
854: x_return_status := fnd_api.g_ret_sts_error;
855: WHEN OTHERS THEN
856: ROLLBACK TO SAVEPOINT update_material_line1;
857: x_material_detail_rec := NULL;
858:

Line 869: ,p_encoded => fnd_api.g_false

865: || SQLERRM);
866: END IF;
867:
868: gme_common_pvt.count_and_get (x_count => x_message_count
869: ,p_encoded => fnd_api.g_false
870: ,x_data => x_message_list);
871: x_return_status := fnd_api.g_ret_sts_unexp_error;
872: END update_material_line;
873:

Line 871: x_return_status := fnd_api.g_ret_sts_unexp_error;

867:
868: gme_common_pvt.count_and_get (x_count => x_message_count
869: ,p_encoded => fnd_api.g_false
870: ,x_data => x_message_list);
871: x_return_status := fnd_api.g_ret_sts_unexp_error;
872: END update_material_line;
873:
874: /*************************************************************************/
875: PROCEDURE update_material_line (

Line 879: := fnd_api.g_false

875: PROCEDURE update_material_line (
876: p_validation_level IN NUMBER
877: := gme_common_pvt.g_max_errors
878: ,p_init_msg_list IN VARCHAR2
879: := fnd_api.g_false
880: ,x_message_count OUT NOCOPY NUMBER
881: ,x_message_list OUT NOCOPY VARCHAR2
882: ,x_return_status OUT NOCOPY VARCHAR2
883: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 888: := fnd_api.g_false

884: ,p_material_detail_rec IN gme_material_details%ROWTYPE
885: ,p_stored_material_detail_rec IN gme_material_details%ROWTYPE
886: ,p_batch_step_rec IN gme_batch_steps%ROWTYPE
887: ,p_scale_phantom IN VARCHAR2
888: := fnd_api.g_false
889: ,p_trans_id IN NUMBER
890: ,x_transacted OUT NOCOPY VARCHAR2
891: ,x_material_detail_rec OUT NOCOPY gme_material_details%ROWTYPE)
892: IS

Line 913: x_return_status := fnd_api.g_ret_sts_error;

909: gme_common_pvt.g_setup_done :=
910: gme_common_pvt.setup (p_batch_header_rec.organization_id);
911:
912: IF NOT gme_common_pvt.g_setup_done THEN
913: x_return_status := fnd_api.g_ret_sts_error;
914: RAISE setup_failure;
915: END IF;
916: END IF;
917:

Line 919: x_return_status := fnd_api.g_ret_sts_success;

915: END IF;
916: END IF;
917:
918: /* Set the return status to success initially */
919: x_return_status := fnd_api.g_ret_sts_success;
920:
921: -- Initialize message list and count if needed
922: IF p_init_msg_list = fnd_api.g_true THEN
923: fnd_msg_pub.initialize;

Line 922: IF p_init_msg_list = fnd_api.g_true THEN

918: /* Set the return status to success initially */
919: x_return_status := fnd_api.g_ret_sts_success;
920:
921: -- Initialize message list and count if needed
922: IF p_init_msg_list = fnd_api.g_true THEN
923: fnd_msg_pub.initialize;
924: gme_common_pvt.g_error_count := 0;
925: END IF;
926:

Line 939: IF x_return_status <> fnd_api.g_ret_sts_success THEN

935: ,x_transacted => x_transacted
936: ,x_return_status => x_return_status
937: ,x_material_detail_rec => x_material_detail_rec);
938:
939: IF x_return_status <> fnd_api.g_ret_sts_success THEN
940: RAISE upd_mtl_line_failure;
941: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
942:
943: gme_common_pvt.log_message ('GME_MTL_LINE_UPDATED');

Line 941: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

937: ,x_material_detail_rec => x_material_detail_rec);
938:
939: IF x_return_status <> fnd_api.g_ret_sts_success THEN
940: RAISE upd_mtl_line_failure;
941: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
942:
943: gme_common_pvt.log_message ('GME_MTL_LINE_UPDATED');
944:
945:

Line 947: ,p_encoded => fnd_api.g_false

943: gme_common_pvt.log_message ('GME_MTL_LINE_UPDATED');
944:
945:
946: gme_common_pvt.count_and_get (x_count => x_message_count
947: ,p_encoded => fnd_api.g_false
948: ,x_data => x_message_list);
949:
950: IF (g_debug IS NOT NULL) THEN
951: gme_debug.put_line ( 'Completed '

Line 957: x_return_status := fnd_api.g_ret_sts_success;

953: || ' at '
954: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
955: END IF;
956: IF (x_return_status IS NULL) THEN
957: x_return_status := fnd_api.g_ret_sts_success;
958: END IF;
959: EXCEPTION
960: WHEN upd_mtl_line_failure THEN
961: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

Line 967: ,p_encoded => fnd_api.g_false

963: x_material_detail_rec := NULL;
964: END IF;
965:
966: gme_common_pvt.count_and_get (x_count => x_message_count
967: ,p_encoded => fnd_api.g_false
968: ,x_data => x_message_list);
969: WHEN setup_failure THEN
970: ROLLBACK TO SAVEPOINT update_material_line;
971: x_material_detail_rec := NULL;

Line 973: ,p_encoded => fnd_api.g_false

969: WHEN setup_failure THEN
970: ROLLBACK TO SAVEPOINT update_material_line;
971: x_material_detail_rec := NULL;
972: gme_common_pvt.count_and_get (x_count => x_message_count
973: ,p_encoded => fnd_api.g_false
974: ,x_data => x_message_list);
975: x_return_status := fnd_api.g_ret_sts_error;
976: WHEN OTHERS THEN
977: ROLLBACK TO SAVEPOINT update_material_line;

Line 975: x_return_status := fnd_api.g_ret_sts_error;

971: x_material_detail_rec := NULL;
972: gme_common_pvt.count_and_get (x_count => x_message_count
973: ,p_encoded => fnd_api.g_false
974: ,x_data => x_message_list);
975: x_return_status := fnd_api.g_ret_sts_error;
976: WHEN OTHERS THEN
977: ROLLBACK TO SAVEPOINT update_material_line;
978: x_material_detail_rec := NULL;
979:

Line 990: ,p_encoded => fnd_api.g_false

986: || SQLERRM);
987: END IF;
988:
989: gme_common_pvt.count_and_get (x_count => x_message_count
990: ,p_encoded => fnd_api.g_false
991: ,x_data => x_message_list);
992: x_return_status := fnd_api.g_ret_sts_unexp_error;
993: END update_material_line;
994:

Line 992: x_return_status := fnd_api.g_ret_sts_unexp_error;

988:
989: gme_common_pvt.count_and_get (x_count => x_message_count
990: ,p_encoded => fnd_api.g_false
991: ,x_data => x_message_list);
992: x_return_status := fnd_api.g_ret_sts_unexp_error;
993: END update_material_line;
994:
995: /*************************************************************************/
996: PROCEDURE delete_material_line (

Line 999: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

995: /*************************************************************************/
996: PROCEDURE delete_material_line (
997: p_validation_level IN NUMBER
998: := gme_common_pvt.g_max_errors
999: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1000: ,x_message_count OUT NOCOPY NUMBER
1001: ,x_message_list OUT NOCOPY VARCHAR2
1002: ,x_return_status OUT NOCOPY VARCHAR2
1003: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 1023: x_return_status := fnd_api.g_ret_sts_success;

1019:
1020: BEGIN
1021:
1022: /* Set the return status to success initially */
1023: x_return_status := fnd_api.g_ret_sts_success;
1024:
1025: SAVEPOINT delete_material_line1;
1026:
1027: IF (g_debug IS NOT NULL) THEN

Line 1041: x_return_status := fnd_api.g_ret_sts_error;

1037: gme_common_pvt.g_setup_done :=
1038: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1039:
1040: IF NOT gme_common_pvt.g_setup_done THEN
1041: x_return_status := fnd_api.g_ret_sts_error;
1042: RAISE setup_failure;
1043: END IF;
1044: END IF;
1045:

Line 1047: IF p_init_msg_list = fnd_api.g_true THEN

1043: END IF;
1044: END IF;
1045:
1046: -- Initialize message list and count if needed
1047: IF p_init_msg_list = fnd_api.g_true THEN
1048: fnd_msg_pub.initialize;
1049: gme_common_pvt.g_error_count := 0;
1050: END IF;
1051:

Line 1058: RAISE fnd_api.g_exc_error;

1054: IF p_batch_step_id IS NOT NULL THEN
1055: l_batch_step_rec.batchstep_id := p_batch_step_id;
1056:
1057: IF NOT gme_batch_steps_dbl.fetch_row(l_batch_step_rec, l_batch_step_rec) THEN
1058: RAISE fnd_api.g_exc_error;
1059: END IF;
1060: END IF;
1061:
1062: delete_material_line (

Line 1073: IF x_return_status <> fnd_api.g_ret_sts_success THEN

1069: ,p_material_detail_rec => p_material_detail_rec
1070: ,p_batch_step_rec => l_batch_step_rec
1071: ,x_transacted => x_transacted);
1072:
1073: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1074: RAISE del_mtl_line_failure;
1075: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
1076:
1077: --

Line 1075: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

1071: ,x_transacted => x_transacted);
1072:
1073: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1074: RAISE del_mtl_line_failure;
1075: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
1076:
1077: --
1078: -- Bug 5903208 -- call to GMF
1079: --

Line 1082: p_init_msg_list => FND_API.G_FALSE,

1078: -- Bug 5903208 -- call to GMF
1079: --
1080: GMF_VIB.Update_Batch_Requirements
1081: ( p_api_version => 1.0,
1082: p_init_msg_list => FND_API.G_FALSE,
1083: p_batch_id => p_batch_header_rec.batch_id,
1084: x_return_status => x_return_status,
1085: x_msg_count => l_message_count,
1086: x_msg_data => l_message_list);

Line 1087: IF x_return_status <> FND_API.G_RET_STS_SUCCESS

1083: p_batch_id => p_batch_header_rec.batch_id,
1084: x_return_status => x_return_status,
1085: x_msg_count => l_message_count,
1086: x_msg_data => l_message_list);
1087: IF x_return_status <> FND_API.G_RET_STS_SUCCESS
1088: THEN
1089: RAISE gmf_cost_failure;
1090: END IF;
1091: -- End Bug 5903208

Line 1106: IF x_return_status <> fnd_api.g_ret_sts_success THEN

1102: ,P_PARENT_EVENT_KEY => NULL
1103: ,P_PARENT_ERECORD_ID => NULL
1104: ,X_STATUS => x_return_status);
1105:
1106: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1107: RAISE del_mtl_line_failure;
1108: END IF;
1109:
1110: gme_common_pvt.count_and_get (x_count => x_message_count

Line 1111: ,p_encoded => fnd_api.g_false

1107: RAISE del_mtl_line_failure;
1108: END IF;
1109:
1110: gme_common_pvt.count_and_get (x_count => x_message_count
1111: ,p_encoded => fnd_api.g_false
1112: ,x_data => x_message_list);
1113:
1114: IF (g_debug IS NOT NULL) THEN
1115: gme_debug.put_line ( 'Completed '

Line 1121: x_return_status := fnd_api.g_ret_sts_success;

1117: || ' at '
1118: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
1119: END IF;
1120: IF (x_return_status IS NULL) THEN
1121: x_return_status := fnd_api.g_ret_sts_success;
1122: END IF;
1123: EXCEPTION
1124: WHEN gmf_cost_failure THEN
1125: -- Bug 5903208

Line 1126: x_return_status := FND_API.G_RET_STS_ERROR;

1122: END IF;
1123: EXCEPTION
1124: WHEN gmf_cost_failure THEN
1125: -- Bug 5903208
1126: x_return_status := FND_API.G_RET_STS_ERROR;
1127:
1128: WHEN del_mtl_line_failure THEN
1129: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN
1130: ROLLBACK TO SAVEPOINT delete_material_line1;

Line 1134: ,p_encoded => fnd_api.g_false

1130: ROLLBACK TO SAVEPOINT delete_material_line1;
1131: END IF;
1132:
1133: gme_common_pvt.count_and_get (x_count => x_message_count
1134: ,p_encoded => fnd_api.g_false
1135: ,x_data => x_message_list);
1136: WHEN setup_failure THEN
1137: ROLLBACK TO SAVEPOINT delete_material_line1;
1138: gme_common_pvt.count_and_get (x_count => x_message_count

Line 1139: ,p_encoded => fnd_api.g_false

1135: ,x_data => x_message_list);
1136: WHEN setup_failure THEN
1137: ROLLBACK TO SAVEPOINT delete_material_line1;
1138: gme_common_pvt.count_and_get (x_count => x_message_count
1139: ,p_encoded => fnd_api.g_false
1140: ,x_data => x_message_list);
1141: x_return_status := fnd_api.g_ret_sts_error;
1142: WHEN OTHERS THEN
1143: ROLLBACK TO SAVEPOINT delete_material_line1;

Line 1141: x_return_status := fnd_api.g_ret_sts_error;

1137: ROLLBACK TO SAVEPOINT delete_material_line1;
1138: gme_common_pvt.count_and_get (x_count => x_message_count
1139: ,p_encoded => fnd_api.g_false
1140: ,x_data => x_message_list);
1141: x_return_status := fnd_api.g_ret_sts_error;
1142: WHEN OTHERS THEN
1143: ROLLBACK TO SAVEPOINT delete_material_line1;
1144:
1145: IF (g_debug <= gme_debug.g_log_unexpected) THEN

Line 1155: ,p_encoded => fnd_api.g_false

1151: || SQLERRM);
1152: END IF;
1153:
1154: gme_common_pvt.count_and_get (x_count => x_message_count
1155: ,p_encoded => fnd_api.g_false
1156: ,x_data => x_message_list);
1157: x_return_status := fnd_api.g_ret_sts_unexp_error;
1158: END delete_material_line;
1159:

Line 1157: x_return_status := fnd_api.g_ret_sts_unexp_error;

1153:
1154: gme_common_pvt.count_and_get (x_count => x_message_count
1155: ,p_encoded => fnd_api.g_false
1156: ,x_data => x_message_list);
1157: x_return_status := fnd_api.g_ret_sts_unexp_error;
1158: END delete_material_line;
1159:
1160: /*************************************************************************/
1161: PROCEDURE delete_material_line (

Line 1164: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1160: /*************************************************************************/
1161: PROCEDURE delete_material_line (
1162: p_validation_level IN NUMBER
1163: := gme_common_pvt.g_max_errors
1164: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1165: ,x_message_count OUT NOCOPY NUMBER
1166: ,x_message_list OUT NOCOPY VARCHAR2
1167: ,x_return_status OUT NOCOPY VARCHAR2
1168: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 1179: x_return_status := fnd_api.g_ret_sts_success;

1175: setup_failure EXCEPTION;
1176: BEGIN
1177:
1178: /* Set the return status to success initially */
1179: x_return_status := fnd_api.g_ret_sts_success;
1180:
1181: SAVEPOINT delete_material_line;
1182:
1183: IF (g_debug IS NOT NULL) THEN

Line 1197: x_return_status := fnd_api.g_ret_sts_error;

1193: gme_common_pvt.g_setup_done :=
1194: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1195:
1196: IF NOT gme_common_pvt.g_setup_done THEN
1197: x_return_status := fnd_api.g_ret_sts_error;
1198: RAISE setup_failure;
1199: END IF;
1200: END IF;
1201:

Line 1203: IF p_init_msg_list = fnd_api.g_true THEN

1199: END IF;
1200: END IF;
1201:
1202: -- Initialize message list and count if needed
1203: IF p_init_msg_list = fnd_api.g_true THEN
1204: fnd_msg_pub.initialize;
1205: gme_common_pvt.g_error_count := 0;
1206: END IF;
1207:

Line 1216: IF x_return_status <> fnd_api.g_ret_sts_success THEN

1212: ,p_batch_step_rec => p_batch_step_rec
1213: ,x_transacted => x_transacted
1214: ,x_return_status => x_return_status);
1215:
1216: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1217: RAISE del_mtl_line_failure;
1218: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
1219:
1220: gme_common_pvt.log_message ('GME_MTL_LINE_DELETED');

Line 1218: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

1214: ,x_return_status => x_return_status);
1215:
1216: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1217: RAISE del_mtl_line_failure;
1218: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
1219:
1220: gme_common_pvt.log_message ('GME_MTL_LINE_DELETED');
1221:
1222: gme_common_pvt.count_and_get (x_count => x_message_count

Line 1223: ,p_encoded => fnd_api.g_false

1219:
1220: gme_common_pvt.log_message ('GME_MTL_LINE_DELETED');
1221:
1222: gme_common_pvt.count_and_get (x_count => x_message_count
1223: ,p_encoded => fnd_api.g_false
1224: ,x_data => x_message_list);
1225:
1226: IF (g_debug IS NOT NULL) THEN
1227: gme_debug.put_line ( 'Completed '

Line 1233: x_return_status := fnd_api.g_ret_sts_success;

1229: || ' at '
1230: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
1231: END IF;
1232: IF (x_return_status IS NULL) THEN
1233: x_return_status := fnd_api.g_ret_sts_success;
1234: END IF;
1235: EXCEPTION
1236: WHEN del_mtl_line_failure THEN
1237: IF x_return_status NOT IN (gme_common_pvt.g_inv_short_err) THEN

Line 1242: ,p_encoded => fnd_api.g_false

1238: ROLLBACK TO SAVEPOINT delete_material_line;
1239: END IF;
1240:
1241: gme_common_pvt.count_and_get (x_count => x_message_count
1242: ,p_encoded => fnd_api.g_false
1243: ,x_data => x_message_list);
1244: WHEN setup_failure THEN
1245: ROLLBACK TO SAVEPOINT delete_material_line;
1246: gme_common_pvt.count_and_get (x_count => x_message_count

Line 1247: ,p_encoded => fnd_api.g_false

1243: ,x_data => x_message_list);
1244: WHEN setup_failure THEN
1245: ROLLBACK TO SAVEPOINT delete_material_line;
1246: gme_common_pvt.count_and_get (x_count => x_message_count
1247: ,p_encoded => fnd_api.g_false
1248: ,x_data => x_message_list);
1249: x_return_status := fnd_api.g_ret_sts_error;
1250: WHEN OTHERS THEN
1251: ROLLBACK TO SAVEPOINT delete_material_line;

Line 1249: x_return_status := fnd_api.g_ret_sts_error;

1245: ROLLBACK TO SAVEPOINT delete_material_line;
1246: gme_common_pvt.count_and_get (x_count => x_message_count
1247: ,p_encoded => fnd_api.g_false
1248: ,x_data => x_message_list);
1249: x_return_status := fnd_api.g_ret_sts_error;
1250: WHEN OTHERS THEN
1251: ROLLBACK TO SAVEPOINT delete_material_line;
1252:
1253: IF (g_debug <= gme_debug.g_log_unexpected) THEN

Line 1263: ,p_encoded => fnd_api.g_false

1259: || SQLERRM);
1260: END IF;
1261:
1262: gme_common_pvt.count_and_get (x_count => x_message_count
1263: ,p_encoded => fnd_api.g_false
1264: ,x_data => x_message_list);
1265: x_return_status := fnd_api.g_ret_sts_unexp_error;
1266: END delete_material_line;
1267:

Line 1265: x_return_status := fnd_api.g_ret_sts_unexp_error;

1261:
1262: gme_common_pvt.count_and_get (x_count => x_message_count
1263: ,p_encoded => fnd_api.g_false
1264: ,x_data => x_message_list);
1265: x_return_status := fnd_api.g_ret_sts_unexp_error;
1266: END delete_material_line;
1267:
1268: /*************************************************************************/
1269: PROCEDURE reschedule_batch (

Line 1302: x_return_status := fnd_api.g_ret_sts_error;

1298: gme_common_pvt.g_setup_done :=
1299: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1300:
1301: IF NOT gme_common_pvt.g_setup_done THEN
1302: x_return_status := fnd_api.g_ret_sts_error;
1303: RAISE setup_failure;
1304: END IF;
1305: END IF;
1306:

Line 1308: IF p_init_msg_list = fnd_api.g_true THEN

1304: END IF;
1305: END IF;
1306:
1307: /* Initialize message list and count if needed */
1308: IF p_init_msg_list = fnd_api.g_true THEN
1309: fnd_msg_pub.initialize;
1310: gme_common_pvt.g_error_count := 0;
1311: END IF;
1312:

Line 1335: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, 'C') THEN

1331: gme_debug.put_line
1332: ( 'Came back from Pvt Reschedule Batch with status '
1333: || x_return_status);
1334: END IF;
1335: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, 'C') THEN
1336: RAISE reschedule_batch_failed;
1337: END IF;
1338:
1339: gme_common_pvt.count_and_get (x_count => x_message_count

Line 1340: ,p_encoded => fnd_api.g_false

1336: RAISE reschedule_batch_failed;
1337: END IF;
1338:
1339: gme_common_pvt.count_and_get (x_count => x_message_count
1340: ,p_encoded => fnd_api.g_false
1341: ,x_data => x_message_list);
1342:
1343: IF g_debug <= gme_debug.g_log_procedure THEN
1344: gme_debug.put_line ( g_pkg_name

Line 1357: x_return_status := fnd_api.g_ret_sts_error;

1353: EXCEPTION
1354: WHEN setup_failure THEN
1355: ROLLBACK TO SAVEPOINT reschedule_batch;
1356: x_batch_header_rec := NULL;
1357: x_return_status := fnd_api.g_ret_sts_error;
1358: gme_common_pvt.count_and_get (x_count => x_message_count
1359: ,p_encoded => fnd_api.g_false
1360: ,x_data => x_message_list);
1361: WHEN reschedule_batch_failed THEN

Line 1359: ,p_encoded => fnd_api.g_false

1355: ROLLBACK TO SAVEPOINT reschedule_batch;
1356: x_batch_header_rec := NULL;
1357: x_return_status := fnd_api.g_ret_sts_error;
1358: gme_common_pvt.count_and_get (x_count => x_message_count
1359: ,p_encoded => fnd_api.g_false
1360: ,x_data => x_message_list);
1361: WHEN reschedule_batch_failed THEN
1362: ROLLBACK TO SAVEPOINT reschedule_batch;
1363: x_batch_header_rec := NULL;

Line 1365: ,p_encoded => fnd_api.g_false

1361: WHEN reschedule_batch_failed THEN
1362: ROLLBACK TO SAVEPOINT reschedule_batch;
1363: x_batch_header_rec := NULL;
1364: gme_common_pvt.count_and_get (x_count => x_message_count
1365: ,p_encoded => fnd_api.g_false
1366: ,x_data => x_message_list);
1367: WHEN OTHERS THEN
1368: ROLLBACK TO SAVEPOINT reschedule_batch;
1369: x_batch_header_rec := NULL;

Line 1372: ,p_encoded => fnd_api.g_false

1368: ROLLBACK TO SAVEPOINT reschedule_batch;
1369: x_batch_header_rec := NULL;
1370: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
1371: gme_common_pvt.count_and_get (x_count => x_message_count
1372: ,p_encoded => fnd_api.g_false
1373: ,x_data => x_message_list);
1374: x_return_status := fnd_api.g_ret_sts_unexp_error;
1375: END reschedule_batch;
1376:

Line 1374: x_return_status := fnd_api.g_ret_sts_unexp_error;

1370: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
1371: gme_common_pvt.count_and_get (x_count => x_message_count
1372: ,p_encoded => fnd_api.g_false
1373: ,x_data => x_message_list);
1374: x_return_status := fnd_api.g_ret_sts_unexp_error;
1375: END reschedule_batch;
1376:
1377: /*************************************************************************/
1378: PROCEDURE reschedule_step (

Line 1419: x_return_status := fnd_api.g_ret_sts_error;

1415: gme_common_pvt.g_setup_done :=
1416: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1417:
1418: IF NOT gme_common_pvt.g_setup_done THEN
1419: x_return_status := fnd_api.g_ret_sts_error;
1420: RAISE setup_failure;
1421: END IF;
1422: END IF;
1423:

Line 1425: IF p_init_msg_list = fnd_api.g_true THEN

1421: END IF;
1422: END IF;
1423:
1424: /* Initialize message list and count if needed */
1425: IF p_init_msg_list = fnd_api.g_true THEN
1426: fnd_msg_pub.initialize;
1427: gme_common_pvt.g_error_count := 0;
1428: END IF;
1429:

Line 1456: IF x_return_status = fnd_api.g_ret_sts_success THEN

1452: ( 'Came back from Pvt Reschedule Step with status '
1453: || x_return_status);
1454: END IF;
1455:
1456: IF x_return_status = fnd_api.g_ret_sts_success THEN
1457: -- OM-GME integration - call in private layer at the end
1458: -- need to retrieve batch header record here... it's already retrieved in pvt.
1459: NULL;
1460: ELSE

Line 1468: ,p_encoded => fnd_api.g_false

1464: gme_common_pvt.log_message ('GME_API_STEP_RESCH');
1465:
1466:
1467: gme_common_pvt.count_and_get (x_count => x_message_count
1468: ,p_encoded => fnd_api.g_false
1469: ,x_data => x_message_list);
1470:
1471: IF g_debug <= gme_debug.g_log_procedure THEN
1472: gme_debug.put_line ( g_pkg_name

Line 1486: ,p_encoded => fnd_api.g_false

1482: WHEN reschedule_step_failed OR setup_failure THEN
1483: ROLLBACK TO SAVEPOINT reschedule_batch_step;
1484: x_batch_step_rec := NULL;
1485: gme_common_pvt.count_and_get (x_count => x_message_count
1486: ,p_encoded => fnd_api.g_false
1487: ,x_data => x_message_list);
1488: WHEN expected_error THEN
1489: ROLLBACK TO SAVEPOINT reschedule_batch_step;
1490: x_batch_step_rec := NULL;

Line 1491: x_return_status := fnd_api.g_ret_sts_error;

1487: ,x_data => x_message_list);
1488: WHEN expected_error THEN
1489: ROLLBACK TO SAVEPOINT reschedule_batch_step;
1490: x_batch_step_rec := NULL;
1491: x_return_status := fnd_api.g_ret_sts_error;
1492: WHEN OTHERS THEN
1493: ROLLBACK TO SAVEPOINT reschedule_batch_step;
1494: x_batch_step_rec := NULL;
1495: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);

Line 1497: ,p_encoded => fnd_api.g_false

1493: ROLLBACK TO SAVEPOINT reschedule_batch_step;
1494: x_batch_step_rec := NULL;
1495: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
1496: gme_common_pvt.count_and_get (x_count => x_message_count
1497: ,p_encoded => fnd_api.g_false
1498: ,x_data => x_message_list);
1499: x_return_status := fnd_api.g_ret_sts_unexp_error;
1500: END reschedule_step;
1501:

Line 1499: x_return_status := fnd_api.g_ret_sts_unexp_error;

1495: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
1496: gme_common_pvt.count_and_get (x_count => x_message_count
1497: ,p_encoded => fnd_api.g_false
1498: ,x_data => x_message_list);
1499: x_return_status := fnd_api.g_ret_sts_unexp_error;
1500: END reschedule_step;
1501:
1502: /*************************************************************************/
1503: PROCEDURE create_batch_reservations (

Line 1504: p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1500: END reschedule_step;
1501:
1502: /*************************************************************************/
1503: PROCEDURE create_batch_reservations (
1504: p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1505: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
1506: ,x_message_count OUT NOCOPY NUMBER
1507: ,x_message_list OUT NOCOPY VARCHAR2
1508: ,x_return_status OUT NOCOPY VARCHAR2)

Line 1536: x_return_status := fnd_api.g_ret_sts_success;

1532: END IF;
1533: END IF;
1534:
1535: /* Set the return status to success initially */
1536: x_return_status := fnd_api.g_ret_sts_success;
1537:
1538: -- Initialize message list and count if needed
1539: IF p_init_msg_list = fnd_api.g_true THEN
1540: fnd_msg_pub.initialize;

Line 1539: IF p_init_msg_list = fnd_api.g_true THEN

1535: /* Set the return status to success initially */
1536: x_return_status := fnd_api.g_ret_sts_success;
1537:
1538: -- Initialize message list and count if needed
1539: IF p_init_msg_list = fnd_api.g_true THEN
1540: fnd_msg_pub.initialize;
1541: gme_common_pvt.g_error_count := 0;
1542: END IF;
1543:

Line 1550: IF x_return_status <> fnd_api.g_ret_sts_success THEN

1546: (p_batch_id => p_batch_header_rec.batch_id
1547: ,p_timefence => 1000000
1548: ,x_return_status => x_return_status);
1549:
1550: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1551: gme_common_pvt.log_message ('GME_BATCH_HL_RESERVATION_FAIL');
1552: RAISE batch_reservations_failure;
1553: END IF;
1554:

Line 1571: ,p_encoded => fnd_api.g_false

1567: EXCEPTION
1568: WHEN batch_reservations_failure THEN
1569: ROLLBACK TO SAVEPOINT create_batch_reservations;
1570: gme_common_pvt.count_and_get (x_count => x_message_count
1571: ,p_encoded => fnd_api.g_false
1572: ,x_data => x_message_list);
1573: WHEN OTHERS THEN
1574: IF g_debug <= gme_debug.g_log_unexpected THEN
1575: gme_debug.put_line ( 'When others exception in '

Line 1585: ,p_encoded => fnd_api.g_false

1581: END IF;
1582:
1583: ROLLBACK TO SAVEPOINT create_batch_reservations;
1584: gme_common_pvt.count_and_get (x_count => x_message_count
1585: ,p_encoded => fnd_api.g_false
1586: ,x_data => x_message_list);
1587: x_return_status := fnd_api.g_ret_sts_unexp_error;
1588: END create_batch_reservations;
1589:

Line 1587: x_return_status := fnd_api.g_ret_sts_unexp_error;

1583: ROLLBACK TO SAVEPOINT create_batch_reservations;
1584: gme_common_pvt.count_and_get (x_count => x_message_count
1585: ,p_encoded => fnd_api.g_false
1586: ,x_data => x_message_list);
1587: x_return_status := fnd_api.g_ret_sts_unexp_error;
1588: END create_batch_reservations;
1589:
1590: PROCEDURE create_line_reservations (
1591: p_init_msg_list IN VARCHAR2 := fnd_api.g_false

Line 1591: p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1587: x_return_status := fnd_api.g_ret_sts_unexp_error;
1588: END create_batch_reservations;
1589:
1590: PROCEDURE create_line_reservations (
1591: p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1592: ,p_matl_dtl_rec IN gme_material_details%ROWTYPE
1593: ,x_message_count OUT NOCOPY NUMBER
1594: ,x_message_list OUT NOCOPY VARCHAR2
1595: ,x_return_status OUT NOCOPY VARCHAR2)

Line 1634: x_return_status := fnd_api.g_ret_sts_success;

1630: END IF;
1631: END IF;
1632:
1633: /* Set the return status to success initially */
1634: x_return_status := fnd_api.g_ret_sts_success;
1635:
1636: -- Initialize message list and count if needed
1637: IF p_init_msg_list = fnd_api.g_true THEN
1638: fnd_msg_pub.initialize;

Line 1637: IF p_init_msg_list = fnd_api.g_true THEN

1633: /* Set the return status to success initially */
1634: x_return_status := fnd_api.g_ret_sts_success;
1635:
1636: -- Initialize message list and count if needed
1637: IF p_init_msg_list = fnd_api.g_true THEN
1638: fnd_msg_pub.initialize;
1639: gme_common_pvt.g_error_count := 0;
1640: END IF;
1641:

Line 1674: IF x_return_status <> fnd_api.g_ret_sts_success THEN

1670: || 'get_open_qty returns open_qty: '
1671: || l_open_qty);
1672: END IF;
1673:
1674: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1675: RAISE get_open_qty_failure;
1676: END IF;
1677:
1678: /* Create a high level reservation (at organization level) for the outstanding qty */

Line 1693: IF x_return_status <> fnd_api.g_ret_sts_success THEN

1689: || 'create_material_reservations returns status: '
1690: || x_return_status);
1691: END IF;
1692:
1693: IF x_return_status <> fnd_api.g_ret_sts_success THEN
1694: gme_common_pvt.log_message ('GME_LINE_HL_RESERVATION_FAIL');
1695: RAISE line_reservation_failure;
1696: END IF;
1697:

Line 1713: ,p_encoded => fnd_api.g_false

1709: EXCEPTION
1710: WHEN setup_failure OR get_open_qty_failure OR line_reservation_failure THEN
1711: ROLLBACK TO SAVEPOINT create_line_reservations;
1712: gme_common_pvt.count_and_get (x_count => x_message_count
1713: ,p_encoded => fnd_api.g_false
1714: ,x_data => x_message_list);
1715: x_return_status := fnd_api.g_ret_sts_error;
1716: WHEN OTHERS THEN
1717: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 1715: x_return_status := fnd_api.g_ret_sts_error;

1711: ROLLBACK TO SAVEPOINT create_line_reservations;
1712: gme_common_pvt.count_and_get (x_count => x_message_count
1713: ,p_encoded => fnd_api.g_false
1714: ,x_data => x_message_list);
1715: x_return_status := fnd_api.g_ret_sts_error;
1716: WHEN OTHERS THEN
1717: IF g_debug <= gme_debug.g_log_unexpected THEN
1718: gme_debug.put_line ( 'When others exception in '
1719: || g_pkg_name

Line 1728: ,p_encoded => fnd_api.g_false

1724: END IF;
1725:
1726: ROLLBACK TO SAVEPOINT create_line_reservations;
1727: gme_common_pvt.count_and_get (x_count => x_message_count
1728: ,p_encoded => fnd_api.g_false
1729: ,x_data => x_message_list);
1730: x_return_status := fnd_api.g_ret_sts_unexp_error;
1731: END create_line_reservations;
1732:

Line 1730: x_return_status := fnd_api.g_ret_sts_unexp_error;

1726: ROLLBACK TO SAVEPOINT create_line_reservations;
1727: gme_common_pvt.count_and_get (x_count => x_message_count
1728: ,p_encoded => fnd_api.g_false
1729: ,x_data => x_message_list);
1730: x_return_status := fnd_api.g_ret_sts_unexp_error;
1731: END create_line_reservations;
1732:
1733: /*************************************************************************/
1734: PROCEDURE release_batch (

Line 1737: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1733: /*************************************************************************/
1734: PROCEDURE release_batch (
1735: p_validation_level IN NUMBER
1736: := gme_common_pvt.g_max_errors
1737: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1738: ,x_message_count OUT NOCOPY NUMBER
1739: ,x_message_list OUT NOCOPY VARCHAR2
1740: ,x_return_status OUT NOCOPY VARCHAR2
1741: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 1767: x_return_status := fnd_api.g_ret_sts_error;

1763: gme_common_pvt.g_setup_done :=
1764: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1765:
1766: IF NOT gme_common_pvt.g_setup_done THEN
1767: x_return_status := fnd_api.g_ret_sts_error;
1768: RAISE setup_failure;
1769: END IF;
1770: END IF;
1771:

Line 1773: x_return_status := fnd_api.g_ret_sts_success;

1769: END IF;
1770: END IF;
1771:
1772: /* Set the return status to success initially */
1773: x_return_status := fnd_api.g_ret_sts_success;
1774:
1775: -- Initialize message list and count if needed
1776: IF p_init_msg_list = fnd_api.g_true THEN
1777: fnd_msg_pub.initialize;

Line 1776: IF p_init_msg_list = fnd_api.g_true THEN

1772: /* Set the return status to success initially */
1773: x_return_status := fnd_api.g_ret_sts_success;
1774:
1775: -- Initialize message list and count if needed
1776: IF p_init_msg_list = fnd_api.g_true THEN
1777: fnd_msg_pub.initialize;
1778: gme_common_pvt.g_error_count := 0;
1779: END IF;
1780:

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

1785: ,x_batch_header_rec => x_batch_header_rec
1786: ,x_return_status => x_return_status
1787: ,x_exception_material_tbl => x_exception_material_tbl);
1788:
1789: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
1790: RAISE batch_release_failure;
1791: END IF; /* IF x_return_status NOT IN */
1792:
1793: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/

Line 1794: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND

1790: RAISE batch_release_failure;
1791: END IF; /* IF x_return_status NOT IN */
1792:
1793: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
1794: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
1795: x_return_status = gme_common_pvt.g_exceptions_err THEN
1796: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
1797: ELSE
1798: gme_common_pvt.log_message ('GME_API_BATCH_RELEASED');

Line 1803: ,p_encoded => fnd_api.g_false

1799: END IF;
1800:
1801:
1802: gme_common_pvt.count_and_get (x_count => x_message_count
1803: ,p_encoded => fnd_api.g_false
1804: ,x_data => x_message_list);
1805:
1806: IF (g_debug IS NOT NULL) THEN
1807: gme_debug.put_line ( 'Completed '

Line 1821: ,p_encoded => fnd_api.g_false

1817: WHEN batch_release_failure THEN
1818: ROLLBACK TO SAVEPOINT release_batch;
1819: x_batch_header_rec := NULL;
1820: gme_common_pvt.count_and_get (x_count => x_message_count
1821: ,p_encoded => fnd_api.g_false
1822: ,x_data => x_message_list);
1823: WHEN setup_failure THEN
1824: ROLLBACK TO SAVEPOINT release_batch;
1825: x_batch_header_rec := NULL;

Line 1827: ,p_encoded => fnd_api.g_false

1823: WHEN setup_failure THEN
1824: ROLLBACK TO SAVEPOINT release_batch;
1825: x_batch_header_rec := NULL;
1826: gme_common_pvt.count_and_get (x_count => x_message_count
1827: ,p_encoded => fnd_api.g_false
1828: ,x_data => x_message_list);
1829: x_return_status := fnd_api.g_ret_sts_error;
1830: WHEN OTHERS THEN
1831: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 1829: x_return_status := fnd_api.g_ret_sts_error;

1825: x_batch_header_rec := NULL;
1826: gme_common_pvt.count_and_get (x_count => x_message_count
1827: ,p_encoded => fnd_api.g_false
1828: ,x_data => x_message_list);
1829: x_return_status := fnd_api.g_ret_sts_error;
1830: WHEN OTHERS THEN
1831: IF g_debug <= gme_debug.g_log_unexpected THEN
1832: gme_debug.put_line ( 'When others exception in '
1833: || g_pkg_name

Line 1843: ,p_encoded => fnd_api.g_false

1839:
1840: ROLLBACK TO SAVEPOINT release_batch;
1841: x_batch_header_rec := NULL;
1842: gme_common_pvt.count_and_get (x_count => x_message_count
1843: ,p_encoded => fnd_api.g_false
1844: ,x_data => x_message_list);
1845: x_return_status := fnd_api.g_ret_sts_unexp_error;
1846: END release_batch;
1847:

Line 1845: x_return_status := fnd_api.g_ret_sts_unexp_error;

1841: x_batch_header_rec := NULL;
1842: gme_common_pvt.count_and_get (x_count => x_message_count
1843: ,p_encoded => fnd_api.g_false
1844: ,x_data => x_message_list);
1845: x_return_status := fnd_api.g_ret_sts_unexp_error;
1846: END release_batch;
1847:
1848: /*************************************************************************/
1849: PROCEDURE release_step (

Line 1852: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1848: /*************************************************************************/
1849: PROCEDURE release_step (
1850: p_validation_level IN NUMBER
1851: := gme_common_pvt.g_max_errors
1852: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1853: ,x_message_count OUT NOCOPY NUMBER
1854: ,x_message_list OUT NOCOPY VARCHAR2
1855: ,x_return_status OUT NOCOPY VARCHAR2
1856: ,p_batch_step_rec IN gme_batch_steps%ROWTYPE

Line 1883: x_return_status := fnd_api.g_ret_sts_error;

1879: gme_common_pvt.g_setup_done :=
1880: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1881:
1882: IF NOT gme_common_pvt.g_setup_done THEN
1883: x_return_status := fnd_api.g_ret_sts_error;
1884: RAISE setup_failure;
1885: END IF;
1886: END IF;
1887:

Line 1889: x_return_status := fnd_api.g_ret_sts_success;

1885: END IF;
1886: END IF;
1887:
1888: /* Set the return status to success initially */
1889: x_return_status := fnd_api.g_ret_sts_success;
1890:
1891: -- Initialize message list and count if needed
1892: IF p_init_msg_list = fnd_api.g_true THEN
1893: fnd_msg_pub.initialize;

Line 1892: IF p_init_msg_list = fnd_api.g_true THEN

1888: /* Set the return status to success initially */
1889: x_return_status := fnd_api.g_ret_sts_success;
1890:
1891: -- Initialize message list and count if needed
1892: IF p_init_msg_list = fnd_api.g_true THEN
1893: fnd_msg_pub.initialize;
1894: gme_common_pvt.g_error_count := 0;
1895: END IF;
1896:

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

1901: ,x_batch_step_rec => x_batch_step_rec
1902: ,x_exception_material_tbl => x_exception_material_tbl
1903: ,x_return_status => x_return_status);
1904:
1905: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
1906: RAISE step_release_failure;
1907: END IF; /* IF x_return_status NOT IN */
1908:
1909: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/

Line 1910: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND

1906: RAISE step_release_failure;
1907: END IF; /* IF x_return_status NOT IN */
1908:
1909: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
1910: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
1911: x_return_status = gme_common_pvt.g_exceptions_err THEN
1912: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
1913: ELSE
1914: gme_common_pvt.log_message ('GME_API_STEP_RELEASED');

Line 1919: ,p_encoded => fnd_api.g_false

1915: END IF;
1916:
1917:
1918: gme_common_pvt.count_and_get (x_count => x_message_count
1919: ,p_encoded => fnd_api.g_false
1920: ,x_data => x_message_list);
1921:
1922: IF (g_debug IS NOT NULL) THEN
1923: gme_debug.put_line ( 'Completed '

Line 1937: ,p_encoded => fnd_api.g_false

1933: WHEN step_release_failure THEN
1934: ROLLBACK TO SAVEPOINT release_step;
1935: x_batch_step_rec := NULL;
1936: gme_common_pvt.count_and_get (x_count => x_message_count
1937: ,p_encoded => fnd_api.g_false
1938: ,x_data => x_message_list);
1939: WHEN setup_failure THEN
1940: ROLLBACK TO SAVEPOINT release_step;
1941: x_batch_step_rec := NULL;

Line 1943: ,p_encoded => fnd_api.g_false

1939: WHEN setup_failure THEN
1940: ROLLBACK TO SAVEPOINT release_step;
1941: x_batch_step_rec := NULL;
1942: gme_common_pvt.count_and_get (x_count => x_message_count
1943: ,p_encoded => fnd_api.g_false
1944: ,x_data => x_message_list);
1945: x_return_status := fnd_api.g_ret_sts_error;
1946: WHEN OTHERS THEN
1947: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 1945: x_return_status := fnd_api.g_ret_sts_error;

1941: x_batch_step_rec := NULL;
1942: gme_common_pvt.count_and_get (x_count => x_message_count
1943: ,p_encoded => fnd_api.g_false
1944: ,x_data => x_message_list);
1945: x_return_status := fnd_api.g_ret_sts_error;
1946: WHEN OTHERS THEN
1947: IF g_debug <= gme_debug.g_log_unexpected THEN
1948: gme_debug.put_line ( 'When others exception in '
1949: || g_pkg_name

Line 1959: ,p_encoded => fnd_api.g_false

1955:
1956: ROLLBACK TO SAVEPOINT release_step;
1957: x_batch_step_rec := NULL;
1958: gme_common_pvt.count_and_get (x_count => x_message_count
1959: ,p_encoded => fnd_api.g_false
1960: ,x_data => x_message_list);
1961: x_return_status := fnd_api.g_ret_sts_unexp_error;
1962: END release_step;
1963:

Line 1961: x_return_status := fnd_api.g_ret_sts_unexp_error;

1957: x_batch_step_rec := NULL;
1958: gme_common_pvt.count_and_get (x_count => x_message_count
1959: ,p_encoded => fnd_api.g_false
1960: ,x_data => x_message_list);
1961: x_return_status := fnd_api.g_ret_sts_unexp_error;
1962: END release_step;
1963:
1964: /*************************************************************************/
1965: PROCEDURE complete_batch (

Line 1968: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

1964: /*************************************************************************/
1965: PROCEDURE complete_batch (
1966: p_validation_level IN NUMBER
1967: := gme_common_pvt.g_max_errors
1968: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
1969: ,x_message_count OUT NOCOPY NUMBER
1970: ,x_message_list OUT NOCOPY VARCHAR2
1971: ,x_return_status OUT NOCOPY VARCHAR2
1972: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 1998: x_return_status := fnd_api.g_ret_sts_error;

1994: gme_common_pvt.g_setup_done :=
1995: gme_common_pvt.setup (p_batch_header_rec.organization_id);
1996:
1997: IF NOT gme_common_pvt.g_setup_done THEN
1998: x_return_status := fnd_api.g_ret_sts_error;
1999: RAISE setup_failure;
2000: END IF;
2001: END IF;
2002:

Line 2004: x_return_status := fnd_api.g_ret_sts_success;

2000: END IF;
2001: END IF;
2002:
2003: /* Set the return status to success initially */
2004: x_return_status := fnd_api.g_ret_sts_success;
2005:
2006: -- Initialize message list and count if needed
2007: IF p_init_msg_list = fnd_api.g_true THEN
2008: fnd_msg_pub.initialize;

Line 2007: IF p_init_msg_list = fnd_api.g_true THEN

2003: /* Set the return status to success initially */
2004: x_return_status := fnd_api.g_ret_sts_success;
2005:
2006: -- Initialize message list and count if needed
2007: IF p_init_msg_list = fnd_api.g_true THEN
2008: fnd_msg_pub.initialize;
2009: gme_common_pvt.g_error_count := 0;
2010: END IF;
2011:

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

2015: ,x_exception_material_tbl => x_exception_material_tbl
2016: ,x_batch_header_rec => x_batch_header_rec
2017: ,x_return_status => x_return_status);
2018:
2019: IF x_return_status NOT IN(fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
2020: RAISE batch_complete_failure;
2021: END IF; /* IF x_return_status NOT IN */
2022:
2023: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/

Line 2024: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND

2020: RAISE batch_complete_failure;
2021: END IF; /* IF x_return_status NOT IN */
2022:
2023: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
2024: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
2025: x_return_status = gme_common_pvt.g_exceptions_err THEN
2026: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
2027: ELSE
2028: gme_common_pvt.log_message ('GME_API_BATCH_COMPLETED');

Line 2032: ,p_encoded => fnd_api.g_false

2028: gme_common_pvt.log_message ('GME_API_BATCH_COMPLETED');
2029: END IF;
2030:
2031: gme_common_pvt.count_and_get (x_count => x_message_count
2032: ,p_encoded => fnd_api.g_false
2033: ,x_data => x_message_list);
2034:
2035: IF (g_debug IS NOT NULL) THEN
2036: gme_debug.put_line ( 'Completed '

Line 2050: ,p_encoded => fnd_api.g_false

2046: WHEN batch_complete_failure THEN
2047: ROLLBACK TO SAVEPOINT complete_batch;
2048: x_batch_header_rec := NULL;
2049: gme_common_pvt.count_and_get (x_count => x_message_count
2050: ,p_encoded => fnd_api.g_false
2051: ,x_data => x_message_list);
2052: WHEN setup_failure THEN
2053: ROLLBACK TO SAVEPOINT complete_batch;
2054: x_batch_header_rec := NULL;

Line 2056: ,p_encoded => fnd_api.g_false

2052: WHEN setup_failure THEN
2053: ROLLBACK TO SAVEPOINT complete_batch;
2054: x_batch_header_rec := NULL;
2055: gme_common_pvt.count_and_get (x_count => x_message_count
2056: ,p_encoded => fnd_api.g_false
2057: ,x_data => x_message_list);
2058: x_return_status := fnd_api.g_ret_sts_error;
2059: WHEN OTHERS THEN
2060: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 2058: x_return_status := fnd_api.g_ret_sts_error;

2054: x_batch_header_rec := NULL;
2055: gme_common_pvt.count_and_get (x_count => x_message_count
2056: ,p_encoded => fnd_api.g_false
2057: ,x_data => x_message_list);
2058: x_return_status := fnd_api.g_ret_sts_error;
2059: WHEN OTHERS THEN
2060: IF g_debug <= gme_debug.g_log_unexpected THEN
2061: gme_debug.put_line ( 'When others exception in '
2062: || g_pkg_name

Line 2072: ,p_encoded => fnd_api.g_false

2068:
2069: ROLLBACK TO SAVEPOINT complete_batch;
2070: x_batch_header_rec := NULL;
2071: gme_common_pvt.count_and_get (x_count => x_message_count
2072: ,p_encoded => fnd_api.g_false
2073: ,x_data => x_message_list);
2074: x_return_status := fnd_api.g_ret_sts_unexp_error;
2075: END complete_batch;
2076:

Line 2074: x_return_status := fnd_api.g_ret_sts_unexp_error;

2070: x_batch_header_rec := NULL;
2071: gme_common_pvt.count_and_get (x_count => x_message_count
2072: ,p_encoded => fnd_api.g_false
2073: ,x_data => x_message_list);
2074: x_return_status := fnd_api.g_ret_sts_unexp_error;
2075: END complete_batch;
2076:
2077: /*************************************************************************/
2078: PROCEDURE complete_step (

Line 2081: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

2077: /*************************************************************************/
2078: PROCEDURE complete_step (
2079: p_validation_level IN NUMBER
2080: := gme_common_pvt.g_max_errors
2081: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2082: ,x_message_count OUT NOCOPY NUMBER
2083: ,x_message_list OUT NOCOPY VARCHAR2
2084: ,x_return_status OUT NOCOPY VARCHAR2
2085: ,p_batch_step_rec IN gme_batch_steps%ROWTYPE

Line 2112: x_return_status := fnd_api.g_ret_sts_error;

2108: gme_common_pvt.g_setup_done :=
2109: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2110:
2111: IF NOT gme_common_pvt.g_setup_done THEN
2112: x_return_status := fnd_api.g_ret_sts_error;
2113: RAISE setup_failure;
2114: END IF;
2115: END IF;
2116:

Line 2118: x_return_status := fnd_api.g_ret_sts_success;

2114: END IF;
2115: END IF;
2116:
2117: /* Set the return status to success initially */
2118: x_return_status := fnd_api.g_ret_sts_success;
2119:
2120: -- Initialize message list and count if needed
2121: IF p_init_msg_list = fnd_api.g_true THEN
2122: fnd_msg_pub.initialize;

Line 2121: IF p_init_msg_list = fnd_api.g_true THEN

2117: /* Set the return status to success initially */
2118: x_return_status := fnd_api.g_ret_sts_success;
2119:
2120: -- Initialize message list and count if needed
2121: IF p_init_msg_list = fnd_api.g_true THEN
2122: fnd_msg_pub.initialize;
2123: gme_common_pvt.g_error_count := 0;
2124: END IF;
2125:

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

2130: ,x_batch_step_rec => x_batch_step_rec
2131: ,x_exception_material_tbl => x_exception_material_tbl
2132: ,x_return_status => x_return_status);
2133:
2134: IF x_return_status NOT IN (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
2135: RAISE step_complete_failure;
2136: END IF; /* IF x_return_status NOT IN */
2137:
2138:

Line 2140: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND

2136: END IF; /* IF x_return_status NOT IN */
2137:
2138:
2139: /*Bug#5186328 rework if return status is X then log message saying batch has exceptions*/
2140: IF NVL(p_ignore_exception,fnd_api.g_false) = fnd_api.g_false AND
2141: x_return_status = gme_common_pvt.g_exceptions_err THEN
2142: gme_common_pvt.log_message('GME_MATERIAL_EXCEPTIONS');
2143: ELSE
2144: gme_common_pvt.log_message ('GME_API_STEP_COMPLETED');

Line 2148: ,p_encoded => fnd_api.g_false

2144: gme_common_pvt.log_message ('GME_API_STEP_COMPLETED');
2145: END IF;
2146:
2147: gme_common_pvt.count_and_get (x_count => x_message_count
2148: ,p_encoded => fnd_api.g_false
2149: ,x_data => x_message_list);
2150:
2151: IF (g_debug IS NOT NULL) THEN
2152: gme_debug.put_line ( 'Completed '

Line 2166: ,p_encoded => fnd_api.g_false

2162: WHEN step_complete_failure THEN
2163: ROLLBACK TO SAVEPOINT complete_step;
2164: x_batch_step_rec := NULL;
2165: gme_common_pvt.count_and_get (x_count => x_message_count
2166: ,p_encoded => fnd_api.g_false
2167: ,x_data => x_message_list);
2168: WHEN setup_failure THEN
2169: ROLLBACK TO SAVEPOINT complete_step;
2170: x_batch_step_rec := NULL;

Line 2172: ,p_encoded => fnd_api.g_false

2168: WHEN setup_failure THEN
2169: ROLLBACK TO SAVEPOINT complete_step;
2170: x_batch_step_rec := NULL;
2171: gme_common_pvt.count_and_get (x_count => x_message_count
2172: ,p_encoded => fnd_api.g_false
2173: ,x_data => x_message_list);
2174: x_return_status := fnd_api.g_ret_sts_error;
2175: WHEN OTHERS THEN
2176: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 2174: x_return_status := fnd_api.g_ret_sts_error;

2170: x_batch_step_rec := NULL;
2171: gme_common_pvt.count_and_get (x_count => x_message_count
2172: ,p_encoded => fnd_api.g_false
2173: ,x_data => x_message_list);
2174: x_return_status := fnd_api.g_ret_sts_error;
2175: WHEN OTHERS THEN
2176: IF g_debug <= gme_debug.g_log_unexpected THEN
2177: gme_debug.put_line ( 'When others exception in '
2178: || g_pkg_name

Line 2188: ,p_encoded => fnd_api.g_false

2184:
2185: ROLLBACK TO SAVEPOINT complete_step;
2186: x_batch_step_rec := NULL;
2187: gme_common_pvt.count_and_get (x_count => x_message_count
2188: ,p_encoded => fnd_api.g_false
2189: ,x_data => x_message_list);
2190: x_return_status := fnd_api.g_ret_sts_unexp_error;
2191: END complete_step;
2192:

Line 2190: x_return_status := fnd_api.g_ret_sts_unexp_error;

2186: x_batch_step_rec := NULL;
2187: gme_common_pvt.count_and_get (x_count => x_message_count
2188: ,p_encoded => fnd_api.g_false
2189: ,x_data => x_message_list);
2190: x_return_status := fnd_api.g_ret_sts_unexp_error;
2191: END complete_step;
2192:
2193: /*************************************************************************/
2194: PROCEDURE delete_step (

Line 2197: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

2193: /*************************************************************************/
2194: PROCEDURE delete_step (
2195: p_validation_level IN NUMBER
2196: := gme_common_pvt.g_max_errors
2197: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2198: ,x_message_count OUT NOCOPY NUMBER
2199: ,x_message_list OUT NOCOPY VARCHAR2
2200: ,x_return_status OUT NOCOPY VARCHAR2
2201: ,p_batch_step_rec IN gme_batch_steps%ROWTYPE

Line 2223: x_return_status := fnd_api.g_ret_sts_success;

2219: || 'Entering');
2220: END IF;
2221:
2222: /* Set the return status to success initially */
2223: x_return_status := fnd_api.g_ret_sts_success;
2224:
2225: IF NOT gme_common_pvt.g_setup_done THEN
2226: gme_common_pvt.g_setup_done :=
2227: gme_common_pvt.setup (p_batch_header_rec.organization_id);

Line 2230: x_return_status := fnd_api.g_ret_sts_error;

2226: gme_common_pvt.g_setup_done :=
2227: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2228:
2229: IF NOT gme_common_pvt.g_setup_done THEN
2230: x_return_status := fnd_api.g_ret_sts_error;
2231: RAISE setup_failure;
2232: END IF;
2233: END IF;
2234: /* Initialize message list and count if needed */

Line 2235: IF p_init_msg_list = fnd_api.g_true THEN

2231: RAISE setup_failure;
2232: END IF;
2233: END IF;
2234: /* Initialize message list and count if needed */
2235: IF p_init_msg_list = fnd_api.g_true THEN
2236: fnd_msg_pub.initialize;
2237: gme_common_pvt.g_error_count := 0;
2238: END IF;
2239:

Line 2247: IF x_return_status = fnd_api.g_ret_sts_success THEN

2243: (x_return_status => x_return_status
2244: ,p_batch_step_rec => p_batch_step_rec
2245: ,p_reroute_flag => FALSE);
2246:
2247: IF x_return_status = fnd_api.g_ret_sts_success THEN
2248: NULL;
2249: ELSE
2250: RAISE delete_step_failed;
2251: END IF;

Line 2264: IF x_return_status <> fnd_api.g_ret_sts_success THEN

2260: ,P_PARENT_EVENT => NULL
2261: ,P_PARENT_EVENT_KEY => NULL
2262: ,P_PARENT_ERECORD_ID => NULL
2263: ,X_STATUS => x_return_status);
2264: IF x_return_status <> fnd_api.g_ret_sts_success THEN
2265: RAISE delete_step_failed;
2266: END IF;
2267:
2268:

Line 2281: ,p_encoded => fnd_api.g_false

2277: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
2278: END IF;
2279:
2280: gme_common_pvt.count_and_get (x_count => x_message_count
2281: ,p_encoded => fnd_api.g_false
2282: ,x_data => x_message_list);
2283: EXCEPTION
2284: WHEN setup_failure THEN
2285: ROLLBACK TO SAVEPOINT delete_step;

Line 2286: x_return_status := fnd_api.g_ret_sts_error;

2282: ,x_data => x_message_list);
2283: EXCEPTION
2284: WHEN setup_failure THEN
2285: ROLLBACK TO SAVEPOINT delete_step;
2286: x_return_status := fnd_api.g_ret_sts_error;
2287: gme_common_pvt.count_and_get (x_count => x_message_count
2288: ,p_encoded => fnd_api.g_false
2289: ,x_data => x_message_list);
2290: WHEN delete_step_failed OR batch_save_failed THEN

Line 2288: ,p_encoded => fnd_api.g_false

2284: WHEN setup_failure THEN
2285: ROLLBACK TO SAVEPOINT delete_step;
2286: x_return_status := fnd_api.g_ret_sts_error;
2287: gme_common_pvt.count_and_get (x_count => x_message_count
2288: ,p_encoded => fnd_api.g_false
2289: ,x_data => x_message_list);
2290: WHEN delete_step_failed OR batch_save_failed THEN
2291: ROLLBACK TO SAVEPOINT delete_step;
2292: gme_common_pvt.count_and_get (x_count => x_message_count

Line 2293: ,p_encoded => fnd_api.g_false

2289: ,x_data => x_message_list);
2290: WHEN delete_step_failed OR batch_save_failed THEN
2291: ROLLBACK TO SAVEPOINT delete_step;
2292: gme_common_pvt.count_and_get (x_count => x_message_count
2293: ,p_encoded => fnd_api.g_false
2294: ,x_data => x_message_list);
2295: WHEN OTHERS THEN
2296: ROLLBACK TO SAVEPOINT delete_step;
2297: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);

Line 2299: ,p_encoded => fnd_api.g_false

2295: WHEN OTHERS THEN
2296: ROLLBACK TO SAVEPOINT delete_step;
2297: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2298: gme_common_pvt.count_and_get (x_count => x_message_count
2299: ,p_encoded => fnd_api.g_false
2300: ,x_data => x_message_list);
2301: x_return_status := fnd_api.g_ret_sts_unexp_error;
2302: END delete_step;
2303:

Line 2301: x_return_status := fnd_api.g_ret_sts_unexp_error;

2297: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2298: gme_common_pvt.count_and_get (x_count => x_message_count
2299: ,p_encoded => fnd_api.g_false
2300: ,x_data => x_message_list);
2301: x_return_status := fnd_api.g_ret_sts_unexp_error;
2302: END delete_step;
2303:
2304: /*************************************************************************
2305: Procedure: insert_step

Line 2313: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

2309: /*************************************************************************/
2310: PROCEDURE insert_step (
2311: p_validation_level IN NUMBER
2312: := gme_common_pvt.g_max_errors
2313: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2314: ,x_message_count OUT NOCOPY NUMBER
2315: ,x_message_list OUT NOCOPY VARCHAR2
2316: ,x_return_status OUT NOCOPY VARCHAR2
2317: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 2347: x_return_status := fnd_api.g_ret_sts_success;

2343: || 'Entering');
2344: END IF;
2345:
2346: /* Set the return status to success initially */
2347: x_return_status := fnd_api.g_ret_sts_success;
2348:
2349: IF NOT gme_common_pvt.g_setup_done THEN
2350: gme_common_pvt.g_setup_done :=
2351: gme_common_pvt.setup (p_batch_header_rec.organization_id);

Line 2354: x_return_status := fnd_api.g_ret_sts_error;

2350: gme_common_pvt.g_setup_done :=
2351: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2352:
2353: IF NOT gme_common_pvt.g_setup_done THEN
2354: x_return_status := fnd_api.g_ret_sts_error;
2355: RAISE setup_failure;
2356: END IF;
2357: END IF;
2358: IF p_init_msg_list = fnd_api.g_true THEN

Line 2358: IF p_init_msg_list = fnd_api.g_true THEN

2354: x_return_status := fnd_api.g_ret_sts_error;
2355: RAISE setup_failure;
2356: END IF;
2357: END IF;
2358: IF p_init_msg_list = fnd_api.g_true THEN
2359: fnd_msg_pub.initialize;
2360: gme_common_pvt.g_error_count := 0;
2361: END IF;
2362:

Line 2371: IF x_return_status <> fnd_api.g_ret_sts_success THEN

2367: ,p_gme_batch_step => p_batch_step_rec
2368: ,x_gme_batch_step => x_batch_step
2369: ,x_return_status => x_return_status);
2370:
2371: IF x_return_status <> fnd_api.g_ret_sts_success THEN
2372: RAISE insert_step_failed;
2373: END IF;
2374:
2375: --

Line 2380: p_init_msg_list => FND_API.G_FALSE,

2376: -- Bug 5903208 -- call to GMF
2377: --
2378: GMF_VIB.Update_Batch_Requirements
2379: ( p_api_version => 1.0,
2380: p_init_msg_list => FND_API.G_FALSE,
2381: p_batch_id => p_batch_header_rec.batch_id,
2382: x_return_status => x_return_status,
2383: x_msg_count => l_message_count,
2384: x_msg_data => l_message_list);

Line 2385: IF x_return_status <> FND_API.G_RET_STS_SUCCESS

2381: p_batch_id => p_batch_header_rec.batch_id,
2382: x_return_status => x_return_status,
2383: x_msg_count => l_message_count,
2384: x_msg_data => l_message_list);
2385: IF x_return_status <> FND_API.G_RET_STS_SUCCESS
2386: THEN
2387: RAISE gmf_cost_failure;
2388: END IF;
2389: -- End Bug 5903208

Line 2403: IF x_return_status <> fnd_api.g_ret_sts_success THEN

2399: ,P_PARENT_EVENT => NULL
2400: ,P_PARENT_EVENT_KEY => NULL
2401: ,P_PARENT_ERECORD_ID => NULL
2402: ,X_STATUS => x_return_status);
2403: IF x_return_status <> fnd_api.g_ret_sts_success THEN
2404: RAISE insert_step_failed;
2405: END IF;
2406: gme_common_pvt.log_message ('GME_INSERT_STEP');
2407: IF (g_debug <= gme_debug.g_log_procedure) THEN

Line 2416: x_return_status := FND_API.G_RET_STS_ERROR;

2412: END IF;
2413: EXCEPTION
2414: WHEN gmf_cost_failure THEN
2415: -- Bug 5903208
2416: x_return_status := FND_API.G_RET_STS_ERROR;
2417:
2418: WHEN setup_failure THEN
2419: ROLLBACK TO SAVEPOINT insert_step;
2420: x_batch_step := NULL;

Line 2421: x_return_status := fnd_api.g_ret_sts_error;

2417:
2418: WHEN setup_failure THEN
2419: ROLLBACK TO SAVEPOINT insert_step;
2420: x_batch_step := NULL;
2421: x_return_status := fnd_api.g_ret_sts_error;
2422: gme_common_pvt.count_and_get (x_count => x_message_count
2423: ,p_encoded => fnd_api.g_false
2424: ,x_data => x_message_list);
2425: WHEN insert_step_failed OR batch_save_failed THEN

Line 2423: ,p_encoded => fnd_api.g_false

2419: ROLLBACK TO SAVEPOINT insert_step;
2420: x_batch_step := NULL;
2421: x_return_status := fnd_api.g_ret_sts_error;
2422: gme_common_pvt.count_and_get (x_count => x_message_count
2423: ,p_encoded => fnd_api.g_false
2424: ,x_data => x_message_list);
2425: WHEN insert_step_failed OR batch_save_failed THEN
2426: ROLLBACK TO SAVEPOINT insert_step;
2427: x_batch_step := NULL;

Line 2429: ,p_encoded => fnd_api.g_false

2425: WHEN insert_step_failed OR batch_save_failed THEN
2426: ROLLBACK TO SAVEPOINT insert_step;
2427: x_batch_step := NULL;
2428: gme_common_pvt.count_and_get (x_count => x_message_count
2429: ,p_encoded => fnd_api.g_false
2430: ,x_data => x_message_list);
2431: WHEN OTHERS THEN
2432: ROLLBACK TO SAVEPOINT insert_step;
2433: x_batch_step := NULL;

Line 2436: ,p_encoded => fnd_api.g_false

2432: ROLLBACK TO SAVEPOINT insert_step;
2433: x_batch_step := NULL;
2434: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2435: gme_common_pvt.count_and_get (x_count => x_message_count
2436: ,p_encoded => fnd_api.g_false
2437: ,x_data => x_message_list);
2438: x_return_status := fnd_api.g_ret_sts_unexp_error;
2439: END insert_step;
2440:

Line 2438: x_return_status := fnd_api.g_ret_sts_unexp_error;

2434: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2435: gme_common_pvt.count_and_get (x_count => x_message_count
2436: ,p_encoded => fnd_api.g_false
2437: ,x_data => x_message_list);
2438: x_return_status := fnd_api.g_ret_sts_unexp_error;
2439: END insert_step;
2440:
2441:
2442: PROCEDURE revert_batch (

Line 2444: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE

2440:
2441:
2442: PROCEDURE revert_batch (
2443: p_validation_level IN NUMBER := gme_common_pvt.g_max_errors
2444: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
2445: ,x_message_count OUT NOCOPY NUMBER
2446: ,x_message_list OUT NOCOPY VARCHAR2
2447: ,x_return_status OUT NOCOPY VARCHAR2
2448: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 2470: x_return_status := fnd_api.g_ret_sts_success;

2466: || 'Entering');
2467: END IF;
2468:
2469: /* Set the return status to success initially */
2470: x_return_status := fnd_api.g_ret_sts_success;
2471:
2472: IF NOT gme_common_pvt.g_setup_done THEN
2473: gme_common_pvt.g_setup_done :=
2474: gme_common_pvt.setup (p_batch_header_rec.organization_id);

Line 2477: x_return_status := fnd_api.g_ret_sts_error;

2473: gme_common_pvt.g_setup_done :=
2474: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2475:
2476: IF NOT gme_common_pvt.g_setup_done THEN
2477: x_return_status := fnd_api.g_ret_sts_error;
2478: RAISE setup_failure;
2479: END IF;
2480: END IF;
2481:

Line 2483: IF p_init_msg_list = fnd_api.g_true THEN

2479: END IF;
2480: END IF;
2481:
2482: -- Initialize message list and count if needed
2483: IF p_init_msg_list = fnd_api.g_true THEN
2484: fnd_msg_pub.initialize;
2485: gme_common_pvt.g_error_count := 0;
2486: END IF;
2487:

Line 2512: IF x_return_status <> fnd_api.g_ret_sts_success THEN

2508: || 'x_return_status='
2509: || x_return_status);
2510: END IF;
2511:
2512: IF x_return_status <> fnd_api.g_ret_sts_success THEN
2513: RAISE batch_revert_failure;
2514: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
2515:
2516:

Line 2514: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

2510: END IF;
2511:
2512: IF x_return_status <> fnd_api.g_ret_sts_success THEN
2513: RAISE batch_revert_failure;
2514: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
2515:
2516:
2517: gme_common_pvt.log_message ('GME_API_BATCH_UNCERTIFIED');
2518:

Line 2521: p_encoded => fnd_api.g_false,

2517: gme_common_pvt.log_message ('GME_API_BATCH_UNCERTIFIED');
2518:
2519:
2520: gme_common_pvt.count_and_get (x_count => x_message_count,
2521: p_encoded => fnd_api.g_false,
2522: x_data => x_message_list);
2523:
2524: IF (g_debug IS NOT NULL) THEN
2525: gme_debug.put_line ( 'Completed '

Line 2543: p_encoded => fnd_api.g_false,

2539: WHEN batch_revert_failure THEN
2540: ROLLBACK TO SAVEPOINT revert_batch;
2541: x_batch_header_rec := NULL;
2542: gme_common_pvt.count_and_get (x_count => x_message_count,
2543: p_encoded => fnd_api.g_false,
2544: x_data => x_message_list);
2545: WHEN setup_failure THEN
2546: ROLLBACK TO SAVEPOINT revert_batch;
2547: x_batch_header_rec := NULL;

Line 2549: p_encoded => fnd_api.g_false,

2545: WHEN setup_failure THEN
2546: ROLLBACK TO SAVEPOINT revert_batch;
2547: x_batch_header_rec := NULL;
2548: gme_common_pvt.count_and_get (x_count => x_message_count,
2549: p_encoded => fnd_api.g_false,
2550: x_data => x_message_list);
2551: x_return_status := fnd_api.g_ret_sts_error;
2552: WHEN OTHERS THEN
2553: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 2551: x_return_status := fnd_api.g_ret_sts_error;

2547: x_batch_header_rec := NULL;
2548: gme_common_pvt.count_and_get (x_count => x_message_count,
2549: p_encoded => fnd_api.g_false,
2550: x_data => x_message_list);
2551: x_return_status := fnd_api.g_ret_sts_error;
2552: WHEN OTHERS THEN
2553: IF g_debug <= gme_debug.g_log_unexpected THEN
2554: gme_debug.put_line ( 'When others exception in '
2555: || g_pkg_name

Line 2565: p_encoded => fnd_api.g_false,

2561:
2562: ROLLBACK TO SAVEPOINT revert_batch;
2563: x_batch_header_rec := NULL;
2564: gme_common_pvt.count_and_get (x_count => x_message_count,
2565: p_encoded => fnd_api.g_false,
2566: x_data => x_message_list);
2567: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2568:
2569:

Line 2567: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2563: x_batch_header_rec := NULL;
2564: gme_common_pvt.count_and_get (x_count => x_message_count,
2565: p_encoded => fnd_api.g_false,
2566: x_data => x_message_list);
2567: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2568:
2569:
2570: END revert_batch;
2571:

Line 2574: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE

2570: END revert_batch;
2571:
2572: PROCEDURE revert_step (
2573: p_validation_level IN NUMBER := gme_common_pvt.g_max_errors
2574: ,p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE
2575: ,x_message_count OUT NOCOPY NUMBER
2576: ,x_message_list OUT NOCOPY VARCHAR2
2577: ,x_return_status OUT NOCOPY VARCHAR2
2578: ,p_batch_step_rec IN gme_batch_steps%ROWTYPE

Line 2601: x_return_status := fnd_api.g_ret_sts_success;

2597: || 'Entering');
2598: END IF;
2599:
2600: /* Set the return status to success initially */
2601: x_return_status := fnd_api.g_ret_sts_success;
2602:
2603: IF NOT gme_common_pvt.g_setup_done THEN
2604: gme_common_pvt.g_setup_done :=
2605: gme_common_pvt.setup (p_batch_header_rec.organization_id);

Line 2608: x_return_status := fnd_api.g_ret_sts_error;

2604: gme_common_pvt.g_setup_done :=
2605: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2606:
2607: IF NOT gme_common_pvt.g_setup_done THEN
2608: x_return_status := fnd_api.g_ret_sts_error;
2609: RAISE setup_failure;
2610: END IF;
2611: END IF;
2612:

Line 2614: IF p_init_msg_list = fnd_api.g_true THEN

2610: END IF;
2611: END IF;
2612:
2613: -- Initialize message list and count if needed
2614: IF p_init_msg_list = fnd_api.g_true THEN
2615: fnd_msg_pub.initialize;
2616: gme_common_pvt.g_error_count := 0;
2617: END IF;
2618:

Line 2644: IF x_return_status <> fnd_api.g_ret_sts_success THEN

2640: || 'x_return_status='
2641: || x_return_status);
2642: END IF;
2643:
2644: IF x_return_status <> fnd_api.g_ret_sts_success THEN
2645: RAISE step_revert_failure;
2646: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
2647:
2648:

Line 2646: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

2642: END IF;
2643:
2644: IF x_return_status <> fnd_api.g_ret_sts_success THEN
2645: RAISE step_revert_failure;
2646: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
2647:
2648:
2649: gme_common_pvt.log_message ('GME_BATCH_STEP_UNCERTIFIED');
2650:

Line 2653: p_encoded => fnd_api.g_false,

2649: gme_common_pvt.log_message ('GME_BATCH_STEP_UNCERTIFIED');
2650:
2651:
2652: gme_common_pvt.count_and_get (x_count => x_message_count,
2653: p_encoded => fnd_api.g_false,
2654: x_data => x_message_list);
2655:
2656: IF (g_debug IS NOT NULL) THEN
2657: gme_debug.put_line ( 'Completed '

Line 2675: p_encoded => fnd_api.g_false,

2671: WHEN step_revert_failure THEN
2672: ROLLBACK TO SAVEPOINT revert_step;
2673: x_batch_step_rec := NULL;
2674: gme_common_pvt.count_and_get (x_count => x_message_count,
2675: p_encoded => fnd_api.g_false,
2676: x_data => x_message_list);
2677: WHEN setup_failure THEN
2678: ROLLBACK TO SAVEPOINT revert_step;
2679: x_batch_step_rec := NULL;

Line 2681: p_encoded => fnd_api.g_false,

2677: WHEN setup_failure THEN
2678: ROLLBACK TO SAVEPOINT revert_step;
2679: x_batch_step_rec := NULL;
2680: gme_common_pvt.count_and_get (x_count => x_message_count,
2681: p_encoded => fnd_api.g_false,
2682: x_data => x_message_list);
2683: x_return_status := fnd_api.g_ret_sts_error;
2684: WHEN OTHERS THEN
2685: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 2683: x_return_status := fnd_api.g_ret_sts_error;

2679: x_batch_step_rec := NULL;
2680: gme_common_pvt.count_and_get (x_count => x_message_count,
2681: p_encoded => fnd_api.g_false,
2682: x_data => x_message_list);
2683: x_return_status := fnd_api.g_ret_sts_error;
2684: WHEN OTHERS THEN
2685: IF g_debug <= gme_debug.g_log_unexpected THEN
2686: gme_debug.put_line ( 'When others exception in '
2687: || g_pkg_name

Line 2697: p_encoded => fnd_api.g_false,

2693:
2694: ROLLBACK TO SAVEPOINT revert_step;
2695: x_batch_step_rec := NULL;
2696: gme_common_pvt.count_and_get (x_count => x_message_count,
2697: p_encoded => fnd_api.g_false,
2698: x_data => x_message_list);
2699: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2700: END revert_step;
2701: /*************************************************************************/

Line 2699: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2695: x_batch_step_rec := NULL;
2696: gme_common_pvt.count_and_get (x_count => x_message_count,
2697: p_encoded => fnd_api.g_false,
2698: x_data => x_message_list);
2699: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2700: END revert_step;
2701: /*************************************************************************/
2702: PROCEDURE close_batch (
2703: p_validation_level IN NUMBER

Line 2733: x_return_status := fnd_api.g_ret_sts_error;

2729: gme_common_pvt.g_setup_done :=
2730: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2731:
2732: IF NOT gme_common_pvt.g_setup_done THEN
2733: x_return_status := fnd_api.g_ret_sts_error;
2734: RAISE setup_failure;
2735: END IF;
2736: END IF;
2737:

Line 2739: IF p_init_msg_list = fnd_api.g_true THEN

2735: END IF;
2736: END IF;
2737:
2738: /* Initialize message list and count if needed */
2739: IF p_init_msg_list = fnd_api.g_true THEN
2740: fnd_msg_pub.initialize;
2741: gme_common_pvt.g_error_count := 0;
2742: END IF;
2743:

Line 2760: IF x_return_status = fnd_api.g_ret_sts_success THEN

2756: gme_debug.put_line ( 'Came back from Pvt Close Batch with status '
2757: || x_return_status);
2758: END IF;
2759:
2760: IF x_return_status = fnd_api.g_ret_sts_success THEN
2761: /* This comment has to be removed after this api becomes available.
2762: GME_TRANS_ENGINE_PVT.inform_OM
2763: ( p_action => 'DELETE'
2764: , p_trans_id => NULL

Line 2780: ,p_encoded => fnd_api.g_false

2776: gme_common_pvt.log_message ('GME_API_BATCH_CLOSED');
2777:
2778:
2779: gme_common_pvt.count_and_get (x_count => x_message_count
2780: ,p_encoded => fnd_api.g_false
2781: ,x_data => x_message_list);
2782:
2783: IF g_debug <= gme_debug.g_log_procedure THEN
2784: gme_debug.put_line ( 'Completed '

Line 2794: ,p_encoded => fnd_api.g_false

2790: WHEN setup_failure OR batch_close_failure OR batch_save_failed THEN
2791: ROLLBACK TO SAVEPOINT close_batch;
2792: x_batch_header_rec := NULL;
2793: gme_common_pvt.count_and_get (x_count => x_message_count
2794: ,p_encoded => fnd_api.g_false
2795: ,x_data => x_message_list);
2796: WHEN OTHERS THEN
2797: ROLLBACK TO SAVEPOINT close_batch;
2798: x_batch_header_rec := NULL;

Line 2801: ,p_encoded => fnd_api.g_false

2797: ROLLBACK TO SAVEPOINT close_batch;
2798: x_batch_header_rec := NULL;
2799: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2800: gme_common_pvt.count_and_get (x_count => x_message_count
2801: ,p_encoded => fnd_api.g_false
2802: ,x_data => x_message_list);
2803: x_return_status := fnd_api.g_ret_sts_unexp_error;
2804: END close_batch;
2805:

Line 2803: x_return_status := fnd_api.g_ret_sts_unexp_error;

2799: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2800: gme_common_pvt.count_and_get (x_count => x_message_count
2801: ,p_encoded => fnd_api.g_false
2802: ,x_data => x_message_list);
2803: x_return_status := fnd_api.g_ret_sts_unexp_error;
2804: END close_batch;
2805:
2806: /*************************************************************************/
2807: PROCEDURE close_step (

Line 2811: p_init_msg_list IN VARCHAR2 := fnd_api.g_false

2807: PROCEDURE close_step (
2808: p_validation_level IN NUMBER
2809: := gme_common_pvt.g_max_errors
2810: , /* Punit Kumar */
2811: p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2812: ,x_message_count OUT NOCOPY NUMBER
2813: ,x_message_list OUT NOCOPY VARCHAR2
2814: ,x_return_status OUT NOCOPY VARCHAR2
2815: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 2817: ,p_delete_pending IN VARCHAR2 := fnd_api.g_false

2813: ,x_message_list OUT NOCOPY VARCHAR2
2814: ,x_return_status OUT NOCOPY VARCHAR2
2815: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
2816: ,p_batch_step_rec IN gme_batch_steps%ROWTYPE
2817: ,p_delete_pending IN VARCHAR2 := fnd_api.g_false
2818: ,x_batch_step_rec OUT NOCOPY gme_batch_steps%ROWTYPE)
2819: IS
2820: l_api_name CONSTANT VARCHAR2 (30) := 'CLOSE_STEP';
2821: setup_failure EXCEPTION;

Line 2839: x_return_status := fnd_api.g_ret_sts_success;

2835: || 'Entering');
2836: END IF;
2837:
2838: /* Set the return status to success initially */
2839: x_return_status := fnd_api.g_ret_sts_success;
2840:
2841: IF NOT gme_common_pvt.g_setup_done THEN
2842: gme_common_pvt.g_setup_done :=
2843: gme_common_pvt.setup (p_batch_header_rec.organization_id);

Line 2846: x_return_status := fnd_api.g_ret_sts_error;

2842: gme_common_pvt.g_setup_done :=
2843: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2844:
2845: IF NOT gme_common_pvt.g_setup_done THEN
2846: x_return_status := fnd_api.g_ret_sts_error;
2847: RAISE setup_failure;
2848: END IF;
2849: END IF;
2850: /* Initialize message list and count if needed */

Line 2851: IF p_init_msg_list = fnd_api.g_true THEN

2847: RAISE setup_failure;
2848: END IF;
2849: END IF;
2850: /* Initialize message list and count if needed */
2851: IF p_init_msg_list = fnd_api.g_true THEN
2852: fnd_msg_pub.initialize;
2853: gme_common_pvt.g_error_count := 0;
2854: END IF;
2855:

Line 2863: IF x_return_status = fnd_api.g_ret_sts_success THEN

2859: ,p_delete_pending => p_delete_pending
2860: ,x_batch_step_rec => x_batch_step_rec
2861: ,x_return_status => x_return_status);
2862:
2863: IF x_return_status = fnd_api.g_ret_sts_success THEN
2864: NULL;
2865: ELSE
2866: RAISE step_close_failed;
2867: END IF;

Line 2881: ,p_encoded => fnd_api.g_false

2877: gme_common_pvt.log_message ('GME_BATCH_STEP_CLOSED');
2878:
2879:
2880: gme_common_pvt.count_and_get (x_count => x_message_count
2881: ,p_encoded => fnd_api.g_false
2882: ,x_data => x_message_list);
2883: EXCEPTION
2884: WHEN setup_failure OR step_close_failed OR batch_save_failed THEN
2885: ROLLBACK TO SAVEPOINT close_batch_step;

Line 2889: ,p_encoded => fnd_api.g_false

2885: ROLLBACK TO SAVEPOINT close_batch_step;
2886: x_batch_step_rec := NULL;
2887: /*N Punit Kumar */
2888: gme_common_pvt.count_and_get (x_count => x_message_count
2889: ,p_encoded => fnd_api.g_false
2890: ,x_data => x_message_list);
2891: WHEN OTHERS THEN
2892: ROLLBACK TO SAVEPOINT close_batch_step;
2893: x_batch_step_rec := NULL;

Line 2897: ,p_encoded => fnd_api.g_false

2893: x_batch_step_rec := NULL;
2894: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
2895: /*N Punit Kumar */
2896: gme_common_pvt.count_and_get (x_count => x_message_count
2897: ,p_encoded => fnd_api.g_false
2898: ,x_data => x_message_list);
2899: x_return_status := fnd_api.g_ret_sts_unexp_error;
2900: END close_step;
2901:

Line 2899: x_return_status := fnd_api.g_ret_sts_unexp_error;

2895: /*N Punit Kumar */
2896: gme_common_pvt.count_and_get (x_count => x_message_count
2897: ,p_encoded => fnd_api.g_false
2898: ,x_data => x_message_list);
2899: x_return_status := fnd_api.g_ret_sts_unexp_error;
2900: END close_step;
2901:
2902: /*************************************************************************/
2903: PROCEDURE reopen_batch (

Line 2907: p_init_msg_list IN VARCHAR2 := fnd_api.g_false

2903: PROCEDURE reopen_batch (
2904: p_validation_level IN NUMBER
2905: := gme_common_pvt.g_max_errors
2906: ,
2907: p_init_msg_list IN VARCHAR2 := fnd_api.g_false
2908: ,x_message_count OUT NOCOPY NUMBER
2909: ,x_message_list OUT NOCOPY VARCHAR2
2910: ,x_return_status OUT NOCOPY VARCHAR2
2911: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 2912: ,p_reopen_steps IN VARCHAR2 := fnd_api.g_false

2908: ,x_message_count OUT NOCOPY NUMBER
2909: ,x_message_list OUT NOCOPY VARCHAR2
2910: ,x_return_status OUT NOCOPY VARCHAR2
2911: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
2912: ,p_reopen_steps IN VARCHAR2 := fnd_api.g_false
2913: ,x_batch_header_rec OUT NOCOPY gme_batch_header%ROWTYPE)
2914: IS
2915: l_api_name CONSTANT VARCHAR2 (30) := 'REOPEN_BATCH';
2916: setup_failure EXCEPTION;

Line 2933: IF p_init_msg_list = fnd_api.g_true THEN

2929: || 'Entering');
2930: END IF;
2931:
2932: /* Initialize message list and count if needed*/
2933: IF p_init_msg_list = fnd_api.g_true THEN
2934: fnd_msg_pub.initialize;
2935: gme_common_pvt.g_error_count := 0;
2936: END IF;
2937:

Line 2939: x_return_status := fnd_api.g_ret_sts_success;

2935: gme_common_pvt.g_error_count := 0;
2936: END IF;
2937:
2938: /* Set the success staus to success inititally*/
2939: x_return_status := fnd_api.g_ret_sts_success;
2940:
2941: -- Pawan kumar added for bug 4956087
2942: IF NOT gme_common_pvt.g_setup_done THEN
2943: gme_common_pvt.g_setup_done :=

Line 2947: x_return_status := fnd_api.g_ret_sts_error;

2943: gme_common_pvt.g_setup_done :=
2944: gme_common_pvt.setup (p_batch_header_rec.organization_id);
2945:
2946: IF NOT gme_common_pvt.g_setup_done THEN
2947: x_return_status := fnd_api.g_ret_sts_error;
2948: RAISE setup_failure;
2949: END IF;
2950: END IF;
2951: gme_common_pvt.set_timestamp;

Line 2969: IF (x_return_status = fnd_api.g_ret_sts_success) THEN

2965: gme_debug.put_line (g_pkg_name || '.' || l_api_name || ':'
2966: || 'after private layer with sts'||x_return_status);
2967: END IF;
2968:
2969: IF (x_return_status = fnd_api.g_ret_sts_success) THEN
2970: NULL;
2971: ELSE
2972: RAISE batch_reopen_failure;
2973: END IF;

Line 2987: ,p_encoded => fnd_api.g_false

2983: END IF;
2984:
2985:
2986: gme_common_pvt.count_and_get (x_count => x_message_count
2987: ,p_encoded => fnd_api.g_false
2988: ,x_data => x_message_list);
2989:
2990:
2991: EXCEPTION

Line 3002: x_return_status := fnd_api.g_ret_sts_error;

2998: ||'reopen_batch error : SETUP_FAILURE'
2999: );
3000: END IF;
3001:
3002: x_return_status := fnd_api.g_ret_sts_error;
3003: /*N Punit Kumar */
3004: gme_common_pvt.count_and_get (x_count => x_message_count
3005: ,p_encoded => fnd_api.g_false
3006: ,x_data => x_message_list);

Line 3005: ,p_encoded => fnd_api.g_false

3001:
3002: x_return_status := fnd_api.g_ret_sts_error;
3003: /*N Punit Kumar */
3004: gme_common_pvt.count_and_get (x_count => x_message_count
3005: ,p_encoded => fnd_api.g_false
3006: ,x_data => x_message_list);
3007: WHEN batch_reopen_failure OR batch_save_failed THEN
3008: ROLLBACK TO SAVEPOINT reopen_batch;
3009: x_batch_header_rec := NULL;

Line 3019: ,p_encoded => fnd_api.g_false

3015: END IF;
3016:
3017: /*N Punit Kumar */
3018: gme_common_pvt.count_and_get (x_count => x_message_count
3019: ,p_encoded => fnd_api.g_false
3020: ,x_data => x_message_list);
3021: x_return_status := fnd_api.g_ret_sts_error;
3022: WHEN OTHERS THEN
3023: ROLLBACK TO SAVEPOINT reopen_batch;

Line 3021: x_return_status := fnd_api.g_ret_sts_error;

3017: /*N Punit Kumar */
3018: gme_common_pvt.count_and_get (x_count => x_message_count
3019: ,p_encoded => fnd_api.g_false
3020: ,x_data => x_message_list);
3021: x_return_status := fnd_api.g_ret_sts_error;
3022: WHEN OTHERS THEN
3023: ROLLBACK TO SAVEPOINT reopen_batch;
3024: x_batch_header_rec := NULL;
3025:

Line 3035: ,p_encoded => fnd_api.g_false

3031:
3032: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3033:
3034: gme_common_pvt.count_and_get (x_count => x_message_count
3035: ,p_encoded => fnd_api.g_false
3036: ,x_data => x_message_list);
3037: x_return_status := fnd_api.g_ret_sts_unexp_error;
3038: END reopen_batch;
3039:

Line 3037: x_return_status := fnd_api.g_ret_sts_unexp_error;

3033:
3034: gme_common_pvt.count_and_get (x_count => x_message_count
3035: ,p_encoded => fnd_api.g_false
3036: ,x_data => x_message_list);
3037: x_return_status := fnd_api.g_ret_sts_unexp_error;
3038: END reopen_batch;
3039:
3040: /*************************************************************************/
3041: PROCEDURE reopen_step (

Line 3045: p_init_msg_list IN VARCHAR2 := fnd_api.g_false

3041: PROCEDURE reopen_step (
3042: p_validation_level IN NUMBER
3043: := gme_common_pvt.g_max_errors
3044: , /* Punit Kumar */
3045: p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3046: ,x_message_count OUT NOCOPY NUMBER
3047: ,x_message_list OUT NOCOPY VARCHAR2
3048: ,x_return_status OUT NOCOPY VARCHAR2
3049: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 3063: IF p_init_msg_list = fnd_api.g_true THEN

3059: -- Set the save point before proceeding
3060: SAVEPOINT reopen_batch_step;
3061:
3062: /* Initialize message list and count if needed*/
3063: IF p_init_msg_list = fnd_api.g_true THEN
3064: fnd_msg_pub.initialize;
3065: gme_common_pvt.g_error_count := 0; /* Punit Kumar */
3066: END IF;
3067:

Line 3081: x_return_status := fnd_api.g_ret_sts_error;

3077: gme_common_pvt.g_setup_done :=
3078: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3079:
3080: IF NOT gme_common_pvt.g_setup_done THEN
3081: x_return_status := fnd_api.g_ret_sts_error;
3082: RAISE setup_failure;
3083: END IF;
3084: END IF;
3085: /* Set the success staus to success inititally*/

Line 3086: x_return_status := fnd_api.g_ret_sts_success;

3082: RAISE setup_failure;
3083: END IF;
3084: END IF;
3085: /* Set the success staus to success inititally*/
3086: x_return_status := fnd_api.g_ret_sts_success;
3087: /* Punit Kumar */
3088: gme_common_pvt.set_timestamp;
3089:
3090: IF (g_debug <= gme_debug.g_log_procedure) THEN

Line 3104: IF (x_return_status = fnd_api.g_ret_sts_success) THEN

3100: gme_debug.put_line (g_pkg_name || '.' || l_api_name || ':'
3101: || 'existing private layer with status'||x_return_status );
3102: END IF;
3103:
3104: IF (x_return_status = fnd_api.g_ret_sts_success) THEN
3105: NULL;
3106: ELSE
3107: RAISE step_reopen_failure;
3108: END IF;

Line 3122: ,p_encoded => fnd_api.g_false

3118: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
3119: END IF;
3120:
3121: gme_common_pvt.count_and_get (x_count => x_message_count
3122: ,p_encoded => fnd_api.g_false
3123: ,x_data => x_message_list);
3124:
3125: IF (g_debug <= gme_debug.g_log_procedure) THEN
3126: gme_debug.put_line ('Normal end of Public Reopen_Step.'

Line 3141: x_return_status := fnd_api.g_ret_sts_error;

3137: ||'reopen_step error : SETUP_FAILURE.'
3138: );
3139: END IF;
3140:
3141: x_return_status := fnd_api.g_ret_sts_error;
3142: /* Punit Kumar */
3143: gme_common_pvt.count_and_get (x_count => x_message_count
3144: ,p_encoded => fnd_api.g_false
3145: ,x_data => x_message_list);

Line 3144: ,p_encoded => fnd_api.g_false

3140:
3141: x_return_status := fnd_api.g_ret_sts_error;
3142: /* Punit Kumar */
3143: gme_common_pvt.count_and_get (x_count => x_message_count
3144: ,p_encoded => fnd_api.g_false
3145: ,x_data => x_message_list);
3146: WHEN step_reopen_failure OR step_save_failed THEN
3147: ROLLBACK TO SAVEPOINT reopen_batch_step;
3148: x_batch_step_rec := NULL;

Line 3159: ,p_encoded => fnd_api.g_false

3155: END IF;
3156:
3157: /* Punit Kumar */
3158: gme_common_pvt.count_and_get (x_count => x_message_count
3159: ,p_encoded => fnd_api.g_false
3160: ,x_data => x_message_list);
3161: x_return_status := fnd_api.g_ret_sts_error;
3162: WHEN OTHERS THEN
3163: ROLLBACK TO SAVEPOINT reopen_batch_step;

Line 3161: x_return_status := fnd_api.g_ret_sts_error;

3157: /* Punit Kumar */
3158: gme_common_pvt.count_and_get (x_count => x_message_count
3159: ,p_encoded => fnd_api.g_false
3160: ,x_data => x_message_list);
3161: x_return_status := fnd_api.g_ret_sts_error;
3162: WHEN OTHERS THEN
3163: ROLLBACK TO SAVEPOINT reopen_batch_step;
3164: x_batch_step_rec := NULL;
3165:

Line 3175: ,p_encoded => fnd_api.g_false

3171:
3172: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3173: /* Punit Kumar */
3174: gme_common_pvt.count_and_get (x_count => x_message_count
3175: ,p_encoded => fnd_api.g_false
3176: ,x_data => x_message_list);
3177: x_return_status := fnd_api.g_ret_sts_unexp_error;
3178: END reopen_step;
3179:

Line 3177: x_return_status := fnd_api.g_ret_sts_unexp_error;

3173: /* Punit Kumar */
3174: gme_common_pvt.count_and_get (x_count => x_message_count
3175: ,p_encoded => fnd_api.g_false
3176: ,x_data => x_message_list);
3177: x_return_status := fnd_api.g_ret_sts_unexp_error;
3178: END reopen_step;
3179:
3180: /*================================================================================
3181: Procedure

Line 3208: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

3204: ================================================================================*/
3205: PROCEDURE incremental_backflush (
3206: p_validation_level IN NUMBER
3207: := gme_common_pvt.g_max_errors
3208: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3209: ,x_message_count OUT NOCOPY NUMBER
3210: ,x_message_list OUT NOCOPY VARCHAR2
3211: ,x_return_status OUT NOCOPY VARCHAR2
3212: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 3234: x_return_status := fnd_api.g_ret_sts_success;

3230: IF (g_debug IS NOT NULL) THEN
3231: gme_debug.log_initialize ('IncrementalBackflush');
3232: END IF;
3233: /* Set the return status to success initially */
3234: x_return_status := fnd_api.g_ret_sts_success;
3235:
3236: /* Setup the common constants used across the apis */
3237: IF NOT gme_common_pvt.g_setup_done THEN
3238: gme_common_pvt.g_setup_done :=

Line 3242: x_return_status := fnd_api.g_ret_sts_error;

3238: gme_common_pvt.g_setup_done :=
3239: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3240:
3241: IF NOT gme_common_pvt.g_setup_done THEN
3242: x_return_status := fnd_api.g_ret_sts_error;
3243: RAISE setup_failure;
3244: END IF;
3245: END IF;
3246:

Line 3248: IF p_init_msg_list = fnd_api.g_true THEN

3244: END IF;
3245: END IF;
3246:
3247: /* Initialize message list and count if needed */
3248: IF p_init_msg_list = fnd_api.g_true THEN
3249: fnd_msg_pub.initialize;
3250: gme_common_pvt.g_error_count := 0;
3251: END IF;
3252:

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

3277: ,x_exception_material_tbl => x_exception_material_tbl
3278: ,x_return_status => x_return_status);
3279:
3280: IF x_return_status NOT IN
3281: (fnd_api.g_ret_sts_success, gme_common_pvt.g_exceptions_err) THEN
3282: IF ( NVL(G_DEBUG,-1) = GME_DEBUG.G_LOG_STATEMENT ) THEN
3283: gme_debug.put_line (g_pkg_name||'.'||l_api_name||' after gme_incremental_backflush_pvt.incremental_backflush; x_return_status= '||x_return_status);
3284: END IF;
3285: RAISE incremental_backflush_failed;

Line 3303: ,p_encoded => fnd_api.g_false

3299: || TO_CHAR (SYSDATE, 'MM/DD/YYYY HH24:MI:SS') );
3300: END IF;
3301:
3302: gme_common_pvt.count_and_get (x_count => x_message_count
3303: ,p_encoded => fnd_api.g_false
3304: ,x_data => x_message_list);
3305: EXCEPTION
3306: WHEN setup_failure THEN
3307: ROLLBACK TO SAVEPOINT incremental_backflush;

Line 3308: x_return_status := fnd_api.g_ret_sts_error;

3304: ,x_data => x_message_list);
3305: EXCEPTION
3306: WHEN setup_failure THEN
3307: ROLLBACK TO SAVEPOINT incremental_backflush;
3308: x_return_status := fnd_api.g_ret_sts_error;
3309: gme_common_pvt.count_and_get (x_count => x_message_count
3310: ,p_encoded => fnd_api.g_false
3311: ,x_data => x_message_list);
3312: WHEN incremental_backflush_failed THEN

Line 3310: ,p_encoded => fnd_api.g_false

3306: WHEN setup_failure THEN
3307: ROLLBACK TO SAVEPOINT incremental_backflush;
3308: x_return_status := fnd_api.g_ret_sts_error;
3309: gme_common_pvt.count_and_get (x_count => x_message_count
3310: ,p_encoded => fnd_api.g_false
3311: ,x_data => x_message_list);
3312: WHEN incremental_backflush_failed THEN
3313: ROLLBACK TO SAVEPOINT incremental_backflush;
3314: gme_common_pvt.count_and_get (x_count => x_message_count

Line 3315: ,p_encoded => fnd_api.g_false

3311: ,x_data => x_message_list);
3312: WHEN incremental_backflush_failed THEN
3313: ROLLBACK TO SAVEPOINT incremental_backflush;
3314: gme_common_pvt.count_and_get (x_count => x_message_count
3315: ,p_encoded => fnd_api.g_false
3316: ,x_data => x_message_list);
3317: IF ( NVL(G_DEBUG,-1) = GME_DEBUG.G_LOG_STATEMENT ) THEN
3318: gme_debug.put_line (g_pkg_name||'.'||l_api_name||' in exception block; x_return_status= '||x_return_status);
3319: END IF;

Line 3324: ,p_encoded => fnd_api.g_false

3320: WHEN OTHERS THEN
3321: ROLLBACK TO SAVEPOINT incremental_backflush;
3322: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3323: gme_common_pvt.count_and_get (x_count => x_message_count
3324: ,p_encoded => fnd_api.g_false
3325: ,x_data => x_message_list);
3326: x_return_status := fnd_api.g_ret_sts_unexp_error;
3327: END incremental_backflush;
3328:

Line 3326: x_return_status := fnd_api.g_ret_sts_unexp_error;

3322: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3323: gme_common_pvt.count_and_get (x_count => x_message_count
3324: ,p_encoded => fnd_api.g_false
3325: ,x_data => x_message_list);
3326: x_return_status := fnd_api.g_ret_sts_unexp_error;
3327: END incremental_backflush;
3328:
3329: /*================================================================================
3330: Procedure

Line 3351: ,p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false

3347: ================================================================================*/
3348: PROCEDURE reroute_batch (
3349: p_validation_level IN NUMBER
3350: := gme_common_pvt.g_max_errors
3351: ,p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false
3352: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
3353: ,p_validity_rule_id IN NUMBER
3354: ,p_use_workday_cal IN VARCHAR2 DEFAULT fnd_api.g_false
3355: ,p_contiguity_override IN VARCHAR2 DEFAULT fnd_api.g_false

Line 3354: ,p_use_workday_cal IN VARCHAR2 DEFAULT fnd_api.g_false

3350: := gme_common_pvt.g_max_errors
3351: ,p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false
3352: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
3353: ,p_validity_rule_id IN NUMBER
3354: ,p_use_workday_cal IN VARCHAR2 DEFAULT fnd_api.g_false
3355: ,p_contiguity_override IN VARCHAR2 DEFAULT fnd_api.g_false
3356: ,x_message_count OUT NOCOPY NUMBER
3357: ,x_message_list OUT NOCOPY VARCHAR2
3358: ,x_return_status OUT NOCOPY VARCHAR2

Line 3355: ,p_contiguity_override IN VARCHAR2 DEFAULT fnd_api.g_false

3351: ,p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false
3352: ,p_batch_header_rec IN gme_batch_header%ROWTYPE
3353: ,p_validity_rule_id IN NUMBER
3354: ,p_use_workday_cal IN VARCHAR2 DEFAULT fnd_api.g_false
3355: ,p_contiguity_override IN VARCHAR2 DEFAULT fnd_api.g_false
3356: ,x_message_count OUT NOCOPY NUMBER
3357: ,x_message_list OUT NOCOPY VARCHAR2
3358: ,x_return_status OUT NOCOPY VARCHAR2
3359: ,x_batch_header_rec OUT NOCOPY gme_batch_header%ROWTYPE)

Line 3378: IF (fnd_api.to_boolean (p_init_msg_list) ) THEN

3374: gme_debug.put_line (g_pkg_name || '.' || l_api_name || ':'
3375: || 'Entering');
3376: END IF;
3377:
3378: IF (fnd_api.to_boolean (p_init_msg_list) ) THEN
3379: fnd_msg_pub.initialize;
3380: gme_common_pvt.g_error_count := 0;
3381: END IF;
3382:

Line 3384: x_return_status := fnd_api.g_ret_sts_success;

3380: gme_common_pvt.g_error_count := 0;
3381: END IF;
3382:
3383: /* Set the return status to success initially */
3384: x_return_status := fnd_api.g_ret_sts_success;
3385:
3386: IF NOT gme_common_pvt.g_setup_done THEN
3387: gme_common_pvt.g_setup_done :=
3388: gme_common_pvt.setup (p_batch_header_rec.organization_id);

Line 3391: x_return_status := fnd_api.g_ret_sts_error;

3387: gme_common_pvt.g_setup_done :=
3388: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3389:
3390: IF NOT gme_common_pvt.g_setup_done THEN
3391: x_return_status := fnd_api.g_ret_sts_error;
3392: RAISE setup_failure;
3393: END IF;
3394: END IF;
3395:

Line 3407: ELSIF (x_return_status = fnd_api.g_ret_sts_error) THEN

3403: ,x_batch_header_rec => x_batch_header_rec);
3404:
3405: IF (x_return_status = 'C') THEN
3406: RAISE no_continous_periods;
3407: ELSIF (x_return_status = fnd_api.g_ret_sts_error) THEN
3408: RAISE fnd_api.g_exc_error;
3409: ELSIF (x_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3410: RAISE fnd_api.g_exc_unexpected_error;
3411: ELSE

Line 3408: RAISE fnd_api.g_exc_error;

3404:
3405: IF (x_return_status = 'C') THEN
3406: RAISE no_continous_periods;
3407: ELSIF (x_return_status = fnd_api.g_ret_sts_error) THEN
3408: RAISE fnd_api.g_exc_error;
3409: ELSIF (x_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3410: RAISE fnd_api.g_exc_unexpected_error;
3411: ELSE
3412: --FPBug#5040865 Begin

Line 3409: ELSIF (x_return_status = fnd_api.g_ret_sts_unexp_error) THEN

3405: IF (x_return_status = 'C') THEN
3406: RAISE no_continous_periods;
3407: ELSIF (x_return_status = fnd_api.g_ret_sts_error) THEN
3408: RAISE fnd_api.g_exc_error;
3409: ELSIF (x_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3410: RAISE fnd_api.g_exc_unexpected_error;
3411: ELSE
3412: --FPBug#5040865 Begin
3413: IF x_batch_header_rec.batch_type = 0 THEN

Line 3410: RAISE fnd_api.g_exc_unexpected_error;

3406: RAISE no_continous_periods;
3407: ELSIF (x_return_status = fnd_api.g_ret_sts_error) THEN
3408: RAISE fnd_api.g_exc_error;
3409: ELSIF (x_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3410: RAISE fnd_api.g_exc_unexpected_error;
3411: ELSE
3412: --FPBug#5040865 Begin
3413: IF x_batch_header_rec.batch_type = 0 THEN
3414: FND_MESSAGE.SET_NAME('GME','GME_BATCH');

Line 3423: ,p_encoded => fnd_api.g_false

3419: --FPBug#5040865 End
3420: END IF;
3421:
3422: gme_common_pvt.count_and_get (x_count => x_message_count
3423: ,p_encoded => fnd_api.g_false
3424: ,x_data => x_message_list);
3425:
3426: IF (NVL (g_debug, 0) IN
3427: (gme_debug.g_log_statement, gme_debug.g_log_procedure) ) THEN

Line 3440: ,p_encoded => fnd_api.g_false

3436: WHEN setup_failure THEN
3437: ROLLBACK TO SAVEPOINT reroute_batch_main;
3438: x_batch_header_rec := NULL;
3439: gme_common_pvt.count_and_get (x_count => x_message_count
3440: ,p_encoded => fnd_api.g_false
3441: ,x_data => x_message_list);
3442: x_return_status := fnd_api.g_ret_sts_error;
3443: WHEN no_continous_periods THEN
3444: gme_common_pvt.count_and_get (x_count => x_message_count

Line 3442: x_return_status := fnd_api.g_ret_sts_error;

3438: x_batch_header_rec := NULL;
3439: gme_common_pvt.count_and_get (x_count => x_message_count
3440: ,p_encoded => fnd_api.g_false
3441: ,x_data => x_message_list);
3442: x_return_status := fnd_api.g_ret_sts_error;
3443: WHEN no_continous_periods THEN
3444: gme_common_pvt.count_and_get (x_count => x_message_count
3445: ,p_encoded => fnd_api.g_false
3446: ,x_data => x_message_list);

Line 3445: ,p_encoded => fnd_api.g_false

3441: ,x_data => x_message_list);
3442: x_return_status := fnd_api.g_ret_sts_error;
3443: WHEN no_continous_periods THEN
3444: gme_common_pvt.count_and_get (x_count => x_message_count
3445: ,p_encoded => fnd_api.g_false
3446: ,x_data => x_message_list);
3447: WHEN fnd_api.g_exc_error THEN
3448: ROLLBACK TO SAVEPOINT reroute_batch_main;
3449: x_batch_header_rec := NULL;

Line 3447: WHEN fnd_api.g_exc_error THEN

3443: WHEN no_continous_periods THEN
3444: gme_common_pvt.count_and_get (x_count => x_message_count
3445: ,p_encoded => fnd_api.g_false
3446: ,x_data => x_message_list);
3447: WHEN fnd_api.g_exc_error THEN
3448: ROLLBACK TO SAVEPOINT reroute_batch_main;
3449: x_batch_header_rec := NULL;
3450: x_return_status := fnd_api.g_ret_sts_error;
3451: gme_common_pvt.count_and_get (x_count => x_message_count

Line 3450: x_return_status := fnd_api.g_ret_sts_error;

3446: ,x_data => x_message_list);
3447: WHEN fnd_api.g_exc_error THEN
3448: ROLLBACK TO SAVEPOINT reroute_batch_main;
3449: x_batch_header_rec := NULL;
3450: x_return_status := fnd_api.g_ret_sts_error;
3451: gme_common_pvt.count_and_get (x_count => x_message_count
3452: ,p_encoded => fnd_api.g_false
3453: ,x_data => x_message_list);
3454: WHEN fnd_api.g_exc_unexpected_error THEN

Line 3452: ,p_encoded => fnd_api.g_false

3448: ROLLBACK TO SAVEPOINT reroute_batch_main;
3449: x_batch_header_rec := NULL;
3450: x_return_status := fnd_api.g_ret_sts_error;
3451: gme_common_pvt.count_and_get (x_count => x_message_count
3452: ,p_encoded => fnd_api.g_false
3453: ,x_data => x_message_list);
3454: WHEN fnd_api.g_exc_unexpected_error THEN
3455: ROLLBACK TO SAVEPOINT reroute_batch_main;
3456: x_batch_header_rec := NULL;

Line 3454: WHEN fnd_api.g_exc_unexpected_error THEN

3450: x_return_status := fnd_api.g_ret_sts_error;
3451: gme_common_pvt.count_and_get (x_count => x_message_count
3452: ,p_encoded => fnd_api.g_false
3453: ,x_data => x_message_list);
3454: WHEN fnd_api.g_exc_unexpected_error THEN
3455: ROLLBACK TO SAVEPOINT reroute_batch_main;
3456: x_batch_header_rec := NULL;
3457: x_return_status := fnd_api.g_ret_sts_unexp_error;
3458:

Line 3457: x_return_status := fnd_api.g_ret_sts_unexp_error;

3453: ,x_data => x_message_list);
3454: WHEN fnd_api.g_exc_unexpected_error THEN
3455: ROLLBACK TO SAVEPOINT reroute_batch_main;
3456: x_batch_header_rec := NULL;
3457: x_return_status := fnd_api.g_ret_sts_unexp_error;
3458:
3459: IF (NVL (g_debug, 0) > 0) THEN
3460: gme_debug.put_line ( g_pkg_name
3461: || '.'

Line 3469: ,p_encoded => fnd_api.g_false

3465: || SQLERRM);
3466: END IF;
3467:
3468: gme_common_pvt.count_and_get (x_count => x_message_count
3469: ,p_encoded => fnd_api.g_false
3470: ,x_data => x_message_list);
3471: WHEN OTHERS THEN
3472: ROLLBACK TO SAVEPOINT reroute_batch_main;
3473: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);

Line 3475: x_return_status := fnd_api.g_ret_sts_unexp_error;

3471: WHEN OTHERS THEN
3472: ROLLBACK TO SAVEPOINT reroute_batch_main;
3473: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3474: x_batch_header_rec := NULL;
3475: x_return_status := fnd_api.g_ret_sts_unexp_error;
3476:
3477: IF (NVL (g_debug, 0) > 0) THEN
3478: gme_debug.put_line ( g_pkg_name
3479: || '.'

Line 3487: ,p_encoded => fnd_api.g_false

3483: || SQLERRM);
3484: END IF;
3485:
3486: gme_common_pvt.count_and_get (x_count => x_message_count
3487: ,p_encoded => fnd_api.g_false
3488: ,x_data => x_message_list);
3489: END reroute_batch;
3490:
3491: /*================================================================================

Line 3511: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

3507: ================================================================================*/
3508: PROCEDURE cancel_batch (
3509: p_validation_level IN NUMBER
3510: := gme_common_pvt.g_max_errors
3511: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3512: ,x_message_count OUT NOCOPY NUMBER
3513: ,x_message_list OUT NOCOPY VARCHAR2
3514: ,x_return_status OUT NOCOPY VARCHAR2
3515: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 3534: x_return_status := fnd_api.g_ret_sts_success;

3530: || 'Entering');
3531: END IF;
3532:
3533: /* Set the return status to success initially */
3534: x_return_status := fnd_api.g_ret_sts_success;
3535:
3536: IF NOT gme_common_pvt.g_setup_done THEN
3537: gme_common_pvt.g_setup_done :=
3538: gme_common_pvt.setup (p_batch_header_rec.organization_id);

Line 3541: x_return_status := fnd_api.g_ret_sts_error;

3537: gme_common_pvt.g_setup_done :=
3538: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3539:
3540: IF NOT gme_common_pvt.g_setup_done THEN
3541: x_return_status := fnd_api.g_ret_sts_error;
3542: RAISE setup_failure;
3543: END IF;
3544: END IF;
3545:

Line 3547: IF p_init_msg_list = fnd_api.g_true THEN

3543: END IF;
3544: END IF;
3545:
3546: -- Initialize message list and count if needed
3547: IF p_init_msg_list = fnd_api.g_true THEN
3548: fnd_msg_pub.initialize;
3549: gme_common_pvt.g_error_count := 0;
3550: END IF;
3551:

Line 3576: IF x_return_status <> fnd_api.g_ret_sts_success THEN

3572: || 'x_return_status='
3573: || x_return_status);
3574: END IF;
3575:
3576: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3577: RAISE batch_cancel_failure;
3578: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3579:
3580: --FPBug#5040865 Begin

Line 3578: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

3574: END IF;
3575:
3576: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3577: RAISE batch_cancel_failure;
3578: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3579:
3580: --FPBug#5040865 Begin
3581: IF x_batch_header_rec.batch_type = 0 THEN
3582: FND_MESSAGE.SET_NAME('GME','GME_BATCH');

Line 3590: ,p_encoded => fnd_api.g_false

3586: gme_common_pvt.log_message ('GME_API_BATCH_CANCELLED','DOC',FND_MESSAGE.GET);
3587: --FPBug#5040865 End
3588:
3589: gme_common_pvt.count_and_get (x_count => x_message_count
3590: ,p_encoded => fnd_api.g_false
3591: ,x_data => x_message_list);
3592:
3593: IF (g_debug IS NOT NULL) THEN
3594: gme_debug.put_line ( 'Completed '

Line 3612: ,p_encoded => fnd_api.g_false

3608: WHEN batch_cancel_failure THEN
3609: ROLLBACK TO SAVEPOINT cancel_batch;
3610: x_batch_header_rec := NULL;
3611: gme_common_pvt.count_and_get (x_count => x_message_count
3612: ,p_encoded => fnd_api.g_false
3613: ,x_data => x_message_list);
3614: WHEN setup_failure THEN
3615: ROLLBACK TO SAVEPOINT cancel_batch;
3616: x_batch_header_rec := NULL;

Line 3618: ,p_encoded => fnd_api.g_false

3614: WHEN setup_failure THEN
3615: ROLLBACK TO SAVEPOINT cancel_batch;
3616: x_batch_header_rec := NULL;
3617: gme_common_pvt.count_and_get (x_count => x_message_count
3618: ,p_encoded => fnd_api.g_false
3619: ,x_data => x_message_list);
3620: x_return_status := fnd_api.g_ret_sts_error;
3621: WHEN OTHERS THEN
3622: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 3620: x_return_status := fnd_api.g_ret_sts_error;

3616: x_batch_header_rec := NULL;
3617: gme_common_pvt.count_and_get (x_count => x_message_count
3618: ,p_encoded => fnd_api.g_false
3619: ,x_data => x_message_list);
3620: x_return_status := fnd_api.g_ret_sts_error;
3621: WHEN OTHERS THEN
3622: IF g_debug <= gme_debug.g_log_unexpected THEN
3623: gme_debug.put_line ( 'When others exception in '
3624: || g_pkg_name

Line 3634: ,p_encoded => fnd_api.g_false

3630:
3631: ROLLBACK TO SAVEPOINT cancel_batch;
3632: x_batch_header_rec := NULL;
3633: gme_common_pvt.count_and_get (x_count => x_message_count
3634: ,p_encoded => fnd_api.g_false
3635: ,x_data => x_message_list);
3636: x_return_status := fnd_api.g_ret_sts_unexp_error;
3637: END cancel_batch;
3638:

Line 3636: x_return_status := fnd_api.g_ret_sts_unexp_error;

3632: x_batch_header_rec := NULL;
3633: gme_common_pvt.count_and_get (x_count => x_message_count
3634: ,p_encoded => fnd_api.g_false
3635: ,x_data => x_message_list);
3636: x_return_status := fnd_api.g_ret_sts_unexp_error;
3637: END cancel_batch;
3638:
3639: /*================================================================================
3640: Procedure

Line 3661: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

3657: ================================================================================*/
3658: PROCEDURE terminate_batch (
3659: p_validation_level IN NUMBER
3660: := gme_common_pvt.g_max_errors
3661: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3662: ,x_message_count OUT NOCOPY NUMBER
3663: ,x_message_list OUT NOCOPY VARCHAR2
3664: ,x_return_status OUT NOCOPY VARCHAR2
3665: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 3685: x_return_status := fnd_api.g_ret_sts_success;

3681: || 'Entering');
3682: END IF;
3683:
3684: /* Set the return status to success initially */
3685: x_return_status := fnd_api.g_ret_sts_success;
3686:
3687: IF NOT gme_common_pvt.g_setup_done THEN
3688: gme_common_pvt.g_setup_done :=
3689: gme_common_pvt.setup (p_batch_header_rec.organization_id);

Line 3692: x_return_status := fnd_api.g_ret_sts_error;

3688: gme_common_pvt.g_setup_done :=
3689: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3690:
3691: IF NOT gme_common_pvt.g_setup_done THEN
3692: x_return_status := fnd_api.g_ret_sts_error;
3693: RAISE setup_failure;
3694: END IF;
3695: END IF;
3696:

Line 3698: IF p_init_msg_list = fnd_api.g_true THEN

3694: END IF;
3695: END IF;
3696:
3697: -- Initialize message list and count if needed
3698: IF p_init_msg_list = fnd_api.g_true THEN
3699: fnd_msg_pub.initialize;
3700: gme_common_pvt.g_error_count := 0;
3701: END IF;
3702:

Line 3727: IF x_return_status <> fnd_api.g_ret_sts_success THEN

3723: || 'x_return_status='
3724: || x_return_status);
3725: END IF;
3726:
3727: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3728: RAISE batch_terminate_failure;
3729: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3730:
3731: gme_common_pvt.log_message ('GME_API_BATCH_TERMINATED');

Line 3729: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

3725: END IF;
3726:
3727: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3728: RAISE batch_terminate_failure;
3729: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3730:
3731: gme_common_pvt.log_message ('GME_API_BATCH_TERMINATED');
3732:
3733:

Line 3735: ,p_encoded => fnd_api.g_false

3731: gme_common_pvt.log_message ('GME_API_BATCH_TERMINATED');
3732:
3733:
3734: gme_common_pvt.count_and_get (x_count => x_message_count
3735: ,p_encoded => fnd_api.g_false
3736: ,x_data => x_message_list);
3737:
3738: IF (g_debug IS NOT NULL) THEN
3739: gme_debug.put_line ( 'Completed '

Line 3766: x_return_status := fnd_api.g_ret_sts_error;

3762: || ':'
3763: || 'SETUP_FAILURE.');
3764: END IF;
3765:
3766: x_return_status := fnd_api.g_ret_sts_error;
3767: gme_common_pvt.count_and_get (x_count => x_message_count
3768: ,p_encoded => fnd_api.g_false
3769: ,x_data => x_message_list);
3770: WHEN batch_terminate_failure THEN

Line 3768: ,p_encoded => fnd_api.g_false

3764: END IF;
3765:
3766: x_return_status := fnd_api.g_ret_sts_error;
3767: gme_common_pvt.count_and_get (x_count => x_message_count
3768: ,p_encoded => fnd_api.g_false
3769: ,x_data => x_message_list);
3770: WHEN batch_terminate_failure THEN
3771: ROLLBACK TO SAVEPOINT terminate_batch;
3772: x_batch_header_rec := NULL;

Line 3784: ,p_encoded => fnd_api.g_false

3780: || 'BATCH_TERMINATE_FAILURE OR BATCH_SAVE_FAILED.');
3781: END IF;
3782:
3783: gme_common_pvt.count_and_get (x_count => x_message_count
3784: ,p_encoded => fnd_api.g_false
3785: ,x_data => x_message_list);
3786: WHEN OTHERS THEN
3787: ROLLBACK TO SAVEPOINT terminate_batch;
3788: x_batch_header_rec := NULL;

Line 3801: ,p_encoded => fnd_api.g_false

3797: END IF;
3798:
3799: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3800: gme_common_pvt.count_and_get (x_count => x_message_count
3801: ,p_encoded => fnd_api.g_false
3802: ,x_data => x_message_list);
3803: x_return_status := fnd_api.g_ret_sts_unexp_error;
3804: END terminate_batch;
3805:

Line 3803: x_return_status := fnd_api.g_ret_sts_unexp_error;

3799: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
3800: gme_common_pvt.count_and_get (x_count => x_message_count
3801: ,p_encoded => fnd_api.g_false
3802: ,x_data => x_message_list);
3803: x_return_status := fnd_api.g_ret_sts_unexp_error;
3804: END terminate_batch;
3805:
3806: /*************************************************************************/
3807: PROCEDURE unrelease_batch (

Line 3810: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

3806: /*************************************************************************/
3807: PROCEDURE unrelease_batch (
3808: p_validation_level IN NUMBER
3809: := gme_common_pvt.g_max_errors
3810: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3811: ,x_message_count OUT NOCOPY NUMBER
3812: ,x_message_list OUT NOCOPY VARCHAR2
3813: ,x_return_status OUT NOCOPY VARCHAR2
3814: ,p_batch_header_rec IN gme_batch_header%ROWTYPE

Line 3838: x_return_status := fnd_api.g_ret_sts_error;

3834: gme_common_pvt.g_setup_done :=
3835: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3836:
3837: IF NOT gme_common_pvt.g_setup_done THEN
3838: x_return_status := fnd_api.g_ret_sts_error;
3839: RAISE setup_failure;
3840: END IF;
3841: END IF;
3842:

Line 3844: x_return_status := fnd_api.g_ret_sts_success;

3840: END IF;
3841: END IF;
3842:
3843: /* Set the return status to success initially */
3844: x_return_status := fnd_api.g_ret_sts_success;
3845:
3846: -- Initialize message list and count if needed
3847: IF p_init_msg_list = fnd_api.g_true THEN
3848: fnd_msg_pub.initialize;

Line 3847: IF p_init_msg_list = fnd_api.g_true THEN

3843: /* Set the return status to success initially */
3844: x_return_status := fnd_api.g_ret_sts_success;
3845:
3846: -- Initialize message list and count if needed
3847: IF p_init_msg_list = fnd_api.g_true THEN
3848: fnd_msg_pub.initialize;
3849: gme_common_pvt.g_error_count := 0;
3850: END IF;
3851:

Line 3860: IF x_return_status <> fnd_api.g_ret_sts_success THEN

3856: ,p_create_resv_pend_lots => p_create_resv_pend_lots
3857: ,x_batch_header_rec => x_batch_header_rec
3858: ,x_return_status => x_return_status);
3859:
3860: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3861: RAISE batch_unrelease_failure;
3862: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3863:
3864: gme_common_pvt.log_message ('GME_API_BATCH_UNRELEASED');

Line 3862: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

3858: ,x_return_status => x_return_status);
3859:
3860: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3861: RAISE batch_unrelease_failure;
3862: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3863:
3864: gme_common_pvt.log_message ('GME_API_BATCH_UNRELEASED');
3865:
3866: gme_common_pvt.count_and_get (x_count => x_message_count

Line 3867: ,p_encoded => fnd_api.g_false

3863:
3864: gme_common_pvt.log_message ('GME_API_BATCH_UNRELEASED');
3865:
3866: gme_common_pvt.count_and_get (x_count => x_message_count
3867: ,p_encoded => fnd_api.g_false
3868: ,x_data => x_message_list);
3869:
3870: IF (g_debug IS NOT NULL) THEN
3871: gme_debug.put_line ( 'Completed '

Line 3885: ,p_encoded => fnd_api.g_false

3881: WHEN batch_unrelease_failure THEN
3882: ROLLBACK TO SAVEPOINT unrelease_batch;
3883: x_batch_header_rec := NULL;
3884: gme_common_pvt.count_and_get (x_count => x_message_count
3885: ,p_encoded => fnd_api.g_false
3886: ,x_data => x_message_list);
3887: WHEN setup_failure THEN
3888: ROLLBACK TO SAVEPOINT unrelease_batch;
3889: x_batch_header_rec := NULL;

Line 3891: ,p_encoded => fnd_api.g_false

3887: WHEN setup_failure THEN
3888: ROLLBACK TO SAVEPOINT unrelease_batch;
3889: x_batch_header_rec := NULL;
3890: gme_common_pvt.count_and_get (x_count => x_message_count
3891: ,p_encoded => fnd_api.g_false
3892: ,x_data => x_message_list);
3893: x_return_status := fnd_api.g_ret_sts_error;
3894: WHEN OTHERS THEN
3895: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 3893: x_return_status := fnd_api.g_ret_sts_error;

3889: x_batch_header_rec := NULL;
3890: gme_common_pvt.count_and_get (x_count => x_message_count
3891: ,p_encoded => fnd_api.g_false
3892: ,x_data => x_message_list);
3893: x_return_status := fnd_api.g_ret_sts_error;
3894: WHEN OTHERS THEN
3895: IF g_debug <= gme_debug.g_log_unexpected THEN
3896: gme_debug.put_line ( 'When others exception in '
3897: || g_pkg_name

Line 3907: ,p_encoded => fnd_api.g_false

3903:
3904: ROLLBACK TO SAVEPOINT unrelease_batch;
3905: x_batch_header_rec := NULL;
3906: gme_common_pvt.count_and_get (x_count => x_message_count
3907: ,p_encoded => fnd_api.g_false
3908: ,x_data => x_message_list);
3909: x_return_status := fnd_api.g_ret_sts_unexp_error;
3910: END unrelease_batch;
3911:

Line 3909: x_return_status := fnd_api.g_ret_sts_unexp_error;

3905: x_batch_header_rec := NULL;
3906: gme_common_pvt.count_and_get (x_count => x_message_count
3907: ,p_encoded => fnd_api.g_false
3908: ,x_data => x_message_list);
3909: x_return_status := fnd_api.g_ret_sts_unexp_error;
3910: END unrelease_batch;
3911:
3912: /*************************************************************************/
3913: PROCEDURE unrelease_step (

Line 3916: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

3912: /*************************************************************************/
3913: PROCEDURE unrelease_step (
3914: p_validation_level IN NUMBER
3915: := gme_common_pvt.g_max_errors
3916: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
3917: ,x_message_count OUT NOCOPY NUMBER
3918: ,x_message_list OUT NOCOPY VARCHAR2
3919: ,x_return_status OUT NOCOPY VARCHAR2
3920: ,p_batch_step_rec IN gme_batch_steps%ROWTYPE

Line 3945: x_return_status := fnd_api.g_ret_sts_error;

3941: gme_common_pvt.g_setup_done :=
3942: gme_common_pvt.setup (p_batch_header_rec.organization_id);
3943:
3944: IF NOT gme_common_pvt.g_setup_done THEN
3945: x_return_status := fnd_api.g_ret_sts_error;
3946: RAISE setup_failure;
3947: END IF;
3948: END IF;
3949:

Line 3951: x_return_status := fnd_api.g_ret_sts_success;

3947: END IF;
3948: END IF;
3949:
3950: /* Set the return status to success initially */
3951: x_return_status := fnd_api.g_ret_sts_success;
3952:
3953: -- Initialize message list and count if needed
3954: IF p_init_msg_list = fnd_api.g_true THEN
3955: fnd_msg_pub.initialize;

Line 3954: IF p_init_msg_list = fnd_api.g_true THEN

3950: /* Set the return status to success initially */
3951: x_return_status := fnd_api.g_ret_sts_success;
3952:
3953: -- Initialize message list and count if needed
3954: IF p_init_msg_list = fnd_api.g_true THEN
3955: fnd_msg_pub.initialize;
3956: gme_common_pvt.g_error_count := 0;
3957: END IF;
3958:

Line 3969: IF x_return_status <> fnd_api.g_ret_sts_success THEN

3965: ,p_from_unrelease_batch => 0
3966: ,x_batch_step_rec => x_batch_step_rec
3967: ,x_return_status => x_return_status);
3968:
3969: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3970: RAISE step_unrelease_failure;
3971: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3972:
3973:

Line 3971: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

3967: ,x_return_status => x_return_status);
3968:
3969: IF x_return_status <> fnd_api.g_ret_sts_success THEN
3970: RAISE step_unrelease_failure;
3971: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
3972:
3973:
3974: gme_common_pvt.log_message ('GME_BATCH_STEP_UNRELEASED');
3975:

Line 3977: ,p_encoded => fnd_api.g_false

3973:
3974: gme_common_pvt.log_message ('GME_BATCH_STEP_UNRELEASED');
3975:
3976: gme_common_pvt.count_and_get (x_count => x_message_count
3977: ,p_encoded => fnd_api.g_false
3978: ,x_data => x_message_list);
3979:
3980: IF (g_debug IS NOT NULL) THEN
3981: gme_debug.put_line ( 'Completed '

Line 3995: ,p_encoded => fnd_api.g_false

3991: WHEN step_unrelease_failure THEN
3992: ROLLBACK TO SAVEPOINT unrelease_step;
3993: x_batch_step_rec := NULL;
3994: gme_common_pvt.count_and_get (x_count => x_message_count
3995: ,p_encoded => fnd_api.g_false
3996: ,x_data => x_message_list);
3997: WHEN setup_failure THEN
3998: ROLLBACK TO SAVEPOINT unrelease_step;
3999: x_batch_step_rec := NULL;

Line 4001: ,p_encoded => fnd_api.g_false

3997: WHEN setup_failure THEN
3998: ROLLBACK TO SAVEPOINT unrelease_step;
3999: x_batch_step_rec := NULL;
4000: gme_common_pvt.count_and_get (x_count => x_message_count
4001: ,p_encoded => fnd_api.g_false
4002: ,x_data => x_message_list);
4003: x_return_status := fnd_api.g_ret_sts_error;
4004: WHEN OTHERS THEN
4005: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 4003: x_return_status := fnd_api.g_ret_sts_error;

3999: x_batch_step_rec := NULL;
4000: gme_common_pvt.count_and_get (x_count => x_message_count
4001: ,p_encoded => fnd_api.g_false
4002: ,x_data => x_message_list);
4003: x_return_status := fnd_api.g_ret_sts_error;
4004: WHEN OTHERS THEN
4005: IF g_debug <= gme_debug.g_log_unexpected THEN
4006: gme_debug.put_line ( 'When others exception in '
4007: || g_pkg_name

Line 4017: ,p_encoded => fnd_api.g_false

4013:
4014: ROLLBACK TO SAVEPOINT unrelease_step;
4015: x_batch_step_rec := NULL;
4016: gme_common_pvt.count_and_get (x_count => x_message_count
4017: ,p_encoded => fnd_api.g_false
4018: ,x_data => x_message_list);
4019: x_return_status := fnd_api.g_ret_sts_unexp_error;
4020: END unrelease_step;
4021:

Line 4019: x_return_status := fnd_api.g_ret_sts_unexp_error;

4015: x_batch_step_rec := NULL;
4016: gme_common_pvt.count_and_get (x_count => x_message_count
4017: ,p_encoded => fnd_api.g_false
4018: ,x_data => x_message_list);
4019: x_return_status := fnd_api.g_ret_sts_unexp_error;
4020: END unrelease_step;
4021:
4022: /*************************************************************************/
4023: PROCEDURE auto_detail_line (

Line 4024: p_init_msg_list IN VARCHAR2 := fnd_api.g_false

4020: END unrelease_step;
4021:
4022: /*************************************************************************/
4023: PROCEDURE auto_detail_line (
4024: p_init_msg_list IN VARCHAR2 := fnd_api.g_false
4025: ,x_message_count OUT NOCOPY NUMBER
4026: ,x_message_list OUT NOCOPY VARCHAR2
4027: ,x_return_status OUT NOCOPY VARCHAR2
4028: ,p_material_detail_rec IN gme_material_details%ROWTYPE)

Line 4051: x_return_status := fnd_api.g_ret_sts_error;

4047: gme_common_pvt.g_setup_done :=
4048: gme_common_pvt.setup (p_material_detail_rec.organization_id);
4049:
4050: IF NOT gme_common_pvt.g_setup_done THEN
4051: x_return_status := fnd_api.g_ret_sts_error;
4052: RAISE setup_failure;
4053: END IF;
4054: END IF;
4055:

Line 4057: IF p_init_msg_list = fnd_api.g_true THEN

4053: END IF;
4054: END IF;
4055:
4056: -- Initialize message list and count if needed
4057: IF p_init_msg_list = fnd_api.g_true THEN
4058: fnd_msg_pub.initialize;
4059: gme_common_pvt.g_error_count := 0;
4060: END IF;
4061:

Line 4063: x_return_status := fnd_api.g_ret_sts_success;

4059: gme_common_pvt.g_error_count := 0;
4060: END IF;
4061:
4062: /* Set the return status to success initially */
4063: x_return_status := fnd_api.g_ret_sts_success;
4064: /* Set the timestamp */
4065: gme_common_pvt.set_timestamp;
4066: gme_reservations_pvt.auto_detail_line
4067: (p_material_details_rec => p_material_detail_rec

Line 4070: IF x_return_status <> fnd_api.g_ret_sts_success THEN

4066: gme_reservations_pvt.auto_detail_line
4067: (p_material_details_rec => p_material_detail_rec
4068: ,x_return_status => x_return_status);
4069:
4070: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4071: RAISE auto_detail_failure;
4072: END IF;
4073:
4074: gme_common_pvt.log_message ('GME_BATCH_AUTO_DETAIL_LINE');

Line 4086: ,p_encoded => fnd_api.g_false

4082: EXCEPTION
4083: WHEN auto_detail_failure OR setup_failure THEN
4084: ROLLBACK TO SAVEPOINT auto_detail_line;
4085: gme_common_pvt.count_and_get (x_count => x_message_count
4086: ,p_encoded => fnd_api.g_false
4087: ,x_data => x_message_list);
4088: WHEN OTHERS THEN
4089: IF g_debug <= gme_debug.g_log_unexpected THEN
4090: gme_debug.put_line ( 'When others exception in '

Line 4101: ,p_encoded => fnd_api.g_false

4097:
4098: ROLLBACK TO SAVEPOINT auto_detail_line;
4099: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
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_unexp_error;
4104: END auto_detail_line;
4105: /*************************************************************************/

Line 4103: x_return_status := fnd_api.g_ret_sts_unexp_error;

4099: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
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_unexp_error;
4104: END auto_detail_line;
4105: /*************************************************************************/
4106: PROCEDURE auto_detail_batch(
4107: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,

Line 4107: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,

4103: x_return_status := fnd_api.g_ret_sts_unexp_error;
4104: END auto_detail_line;
4105: /*************************************************************************/
4106: PROCEDURE auto_detail_batch(
4107: p_init_msg_list IN VARCHAR2 := FND_API.G_FALSE,
4108: x_message_count OUT NOCOPY NUMBER,
4109: x_message_list OUT NOCOPY VARCHAR2,
4110: x_return_status OUT NOCOPY VARCHAR2,
4111: p_batch_rec IN gme_batch_header%ROWTYPE) IS

Line 4135: x_return_status := fnd_api.g_ret_sts_error;

4131: gme_common_pvt.g_setup_done :=
4132: gme_common_pvt.setup (p_batch_rec.organization_id);
4133:
4134: IF NOT gme_common_pvt.g_setup_done THEN
4135: x_return_status := fnd_api.g_ret_sts_error;
4136: RAISE setup_failure;
4137: END IF;
4138: END IF;
4139:

Line 4141: IF p_init_msg_list = fnd_api.g_true THEN

4137: END IF;
4138: END IF;
4139:
4140: -- Initialize message list and count if needed
4141: IF p_init_msg_list = fnd_api.g_true THEN
4142: fnd_msg_pub.initialize;
4143: gme_common_pvt.g_error_count := 0;
4144: END IF;
4145:

Line 4147: x_return_status := fnd_api.g_ret_sts_success;

4143: gme_common_pvt.g_error_count := 0;
4144: END IF;
4145:
4146: /* Set the return status to success initially */
4147: x_return_status := fnd_api.g_ret_sts_success;
4148:
4149: /* Set the timestamp */
4150: gme_common_pvt.set_timestamp;
4151:

Line 4155: IF x_return_status <> fnd_api.g_ret_sts_success THEN

4151:
4152: gme_reservations_pvt.auto_detail_batch(p_batch_rec => p_batch_rec
4153: ,x_return_status => x_return_status);
4154:
4155: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4156: RAISE auto_detail_failure;
4157: END IF;
4158: gme_common_pvt.log_message ('GME_BATCH_AUTO_DETAIL_BATCH');
4159: IF (g_debug <= gme_debug.g_log_procedure) THEN

Line 4169: p_encoded => fnd_api.g_false,

4165: EXCEPTION
4166: WHEN auto_detail_failure OR setup_failure THEN
4167: ROLLBACK TO SAVEPOINT auto_detail_batch;
4168: gme_common_pvt.count_and_get (x_count => x_message_count,
4169: p_encoded => fnd_api.g_false,
4170: x_data => x_message_list);
4171: WHEN OTHERS THEN
4172: IF g_debug <= gme_debug.g_log_unexpected THEN
4173: gme_debug.put_line ( 'When others exception in '

Line 4184: p_encoded => fnd_api.g_false,

4180:
4181: ROLLBACK TO SAVEPOINT auto_detail_batch;
4182: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
4183: gme_common_pvt.count_and_get (x_count => x_message_count,
4184: p_encoded => fnd_api.g_false,
4185: x_data => x_message_list);
4186: x_return_status := fnd_api.g_ret_sts_unexp_error;
4187: END auto_detail_batch;
4188:

Line 4186: x_return_status := fnd_api.g_ret_sts_unexp_error;

4182: fnd_msg_pub.add_exc_msg (g_pkg_name, l_api_name);
4183: gme_common_pvt.count_and_get (x_count => x_message_count,
4184: p_encoded => fnd_api.g_false,
4185: x_data => x_message_list);
4186: x_return_status := fnd_api.g_ret_sts_unexp_error;
4187: END auto_detail_batch;
4188:
4189: /*************************************************************************/
4190: PROCEDURE create_pending_product_lot (

Line 4193: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

4189: /*************************************************************************/
4190: PROCEDURE create_pending_product_lot (
4191: p_validation_level IN NUMBER
4192: := gme_common_pvt.g_max_errors
4193: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
4194: ,x_message_count OUT NOCOPY NUMBER
4195: ,x_message_list OUT NOCOPY VARCHAR2
4196: ,x_return_status OUT NOCOPY VARCHAR2
4197: ,p_org_id IN NUMBER

Line 4221: x_return_status := fnd_api.g_ret_sts_error;

4217: gme_common_pvt.g_setup_done :=
4218: gme_common_pvt.setup (p_org_id);
4219:
4220: IF NOT gme_common_pvt.g_setup_done THEN
4221: x_return_status := fnd_api.g_ret_sts_error;
4222: RAISE setup_failure;
4223: END IF;
4224: END IF;
4225:

Line 4227: x_return_status := fnd_api.g_ret_sts_success;

4223: END IF;
4224: END IF;
4225:
4226: /* Set the return status to success initially */
4227: x_return_status := fnd_api.g_ret_sts_success;
4228:
4229: -- Initialize message list and count if needed
4230: IF p_init_msg_list = fnd_api.g_true THEN
4231: fnd_msg_pub.initialize;

Line 4230: IF p_init_msg_list = fnd_api.g_true THEN

4226: /* Set the return status to success initially */
4227: x_return_status := fnd_api.g_ret_sts_success;
4228:
4229: -- Initialize message list and count if needed
4230: IF p_init_msg_list = fnd_api.g_true THEN
4231: fnd_msg_pub.initialize;
4232: gme_common_pvt.g_error_count := 0;
4233: END IF;
4234:

Line 4241: IF x_return_status <> fnd_api.g_ret_sts_success THEN

4237: (p_pending_product_lots_rec => p_pending_product_lots_rec
4238: ,x_pending_product_lots_rec => x_pending_product_lots_rec
4239: ,x_return_status => x_return_status);
4240:
4241: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4242: RAISE create_pp_lot_failure;
4243: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4244:
4245:

Line 4243: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

4239: ,x_return_status => x_return_status);
4240:
4241: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4242: RAISE create_pp_lot_failure;
4243: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4244:
4245:
4246: gme_common_pvt.log_message ('GME_API_PP_LOT_CREATED');
4247:

Line 4249: ,p_encoded => fnd_api.g_false

4245:
4246: gme_common_pvt.log_message ('GME_API_PP_LOT_CREATED');
4247:
4248: gme_common_pvt.count_and_get (x_count => x_message_count
4249: ,p_encoded => fnd_api.g_false
4250: ,x_data => x_message_list);
4251:
4252: IF (g_debug IS NOT NULL) THEN
4253: gme_debug.put_line ( 'Completed '

Line 4267: ,p_encoded => fnd_api.g_false

4263: WHEN create_pp_lot_failure THEN
4264: ROLLBACK TO SAVEPOINT create_pp_lot;
4265: x_pending_product_lots_rec := NULL;
4266: gme_common_pvt.count_and_get (x_count => x_message_count
4267: ,p_encoded => fnd_api.g_false
4268: ,x_data => x_message_list);
4269: WHEN setup_failure THEN
4270: ROLLBACK TO SAVEPOINT create_pp_lot;
4271: x_pending_product_lots_rec := NULL;

Line 4273: ,p_encoded => fnd_api.g_false

4269: WHEN setup_failure THEN
4270: ROLLBACK TO SAVEPOINT create_pp_lot;
4271: x_pending_product_lots_rec := NULL;
4272: gme_common_pvt.count_and_get (x_count => x_message_count
4273: ,p_encoded => fnd_api.g_false
4274: ,x_data => x_message_list);
4275: x_return_status := fnd_api.g_ret_sts_error;
4276: WHEN OTHERS THEN
4277: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 4275: x_return_status := fnd_api.g_ret_sts_error;

4271: x_pending_product_lots_rec := NULL;
4272: gme_common_pvt.count_and_get (x_count => x_message_count
4273: ,p_encoded => fnd_api.g_false
4274: ,x_data => x_message_list);
4275: x_return_status := fnd_api.g_ret_sts_error;
4276: WHEN OTHERS THEN
4277: IF g_debug <= gme_debug.g_log_unexpected THEN
4278: gme_debug.put_line ( 'When others exception in '
4279: || g_pkg_name

Line 4289: ,p_encoded => fnd_api.g_false

4285:
4286: ROLLBACK TO SAVEPOINT create_pp_lot;
4287: x_pending_product_lots_rec := NULL;
4288: gme_common_pvt.count_and_get (x_count => x_message_count
4289: ,p_encoded => fnd_api.g_false
4290: ,x_data => x_message_list);
4291: x_return_status := fnd_api.g_ret_sts_unexp_error;
4292: END create_pending_product_lot;
4293:

Line 4291: x_return_status := fnd_api.g_ret_sts_unexp_error;

4287: x_pending_product_lots_rec := NULL;
4288: gme_common_pvt.count_and_get (x_count => x_message_count
4289: ,p_encoded => fnd_api.g_false
4290: ,x_data => x_message_list);
4291: x_return_status := fnd_api.g_ret_sts_unexp_error;
4292: END create_pending_product_lot;
4293:
4294: PROCEDURE update_pending_product_lot (
4295: p_validation_level IN NUMBER

Line 4297: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

4293:
4294: PROCEDURE update_pending_product_lot (
4295: p_validation_level IN NUMBER
4296: := gme_common_pvt.g_max_errors
4297: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
4298: ,x_message_count OUT NOCOPY NUMBER
4299: ,x_message_list OUT NOCOPY VARCHAR2
4300: ,x_return_status OUT NOCOPY VARCHAR2
4301: ,p_org_id IN NUMBER

Line 4325: x_return_status := fnd_api.g_ret_sts_error;

4321: gme_common_pvt.g_setup_done :=
4322: gme_common_pvt.setup (p_org_id);
4323:
4324: IF NOT gme_common_pvt.g_setup_done THEN
4325: x_return_status := fnd_api.g_ret_sts_error;
4326: RAISE setup_failure;
4327: END IF;
4328: END IF;
4329:

Line 4331: x_return_status := fnd_api.g_ret_sts_success;

4327: END IF;
4328: END IF;
4329:
4330: /* Set the return status to success initially */
4331: x_return_status := fnd_api.g_ret_sts_success;
4332:
4333: -- Initialize message list and count if needed
4334: IF p_init_msg_list = fnd_api.g_true THEN
4335: fnd_msg_pub.initialize;

Line 4334: IF p_init_msg_list = fnd_api.g_true THEN

4330: /* Set the return status to success initially */
4331: x_return_status := fnd_api.g_ret_sts_success;
4332:
4333: -- Initialize message list and count if needed
4334: IF p_init_msg_list = fnd_api.g_true THEN
4335: fnd_msg_pub.initialize;
4336: gme_common_pvt.g_error_count := 0;
4337: END IF;
4338:

Line 4345: IF x_return_status <> fnd_api.g_ret_sts_success THEN

4341: (p_pending_product_lots_rec => p_pending_product_lots_rec
4342: ,x_pending_product_lots_rec => x_pending_product_lots_rec
4343: ,x_return_status => x_return_status);
4344:
4345: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4346: RAISE update_pp_lot_failure;
4347: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4348:
4349:

Line 4347: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

4343: ,x_return_status => x_return_status);
4344:
4345: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4346: RAISE update_pp_lot_failure;
4347: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4348:
4349:
4350: gme_common_pvt.log_message ('GME_API_PP_LOT_UPDATED');
4351:

Line 4354: ,p_encoded => fnd_api.g_false

4350: gme_common_pvt.log_message ('GME_API_PP_LOT_UPDATED');
4351:
4352:
4353: gme_common_pvt.count_and_get (x_count => x_message_count
4354: ,p_encoded => fnd_api.g_false
4355: ,x_data => x_message_list);
4356:
4357: IF (g_debug IS NOT NULL) THEN
4358: gme_debug.put_line ( 'Completed '

Line 4372: ,p_encoded => fnd_api.g_false

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

Line 4378: ,p_encoded => fnd_api.g_false

4374: WHEN setup_failure THEN
4375: ROLLBACK TO SAVEPOINT update_pp_lot;
4376: x_pending_product_lots_rec := NULL;
4377: gme_common_pvt.count_and_get (x_count => x_message_count
4378: ,p_encoded => fnd_api.g_false
4379: ,x_data => x_message_list);
4380: x_return_status := fnd_api.g_ret_sts_error;
4381: WHEN OTHERS THEN
4382: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 4380: x_return_status := fnd_api.g_ret_sts_error;

4376: x_pending_product_lots_rec := NULL;
4377: gme_common_pvt.count_and_get (x_count => x_message_count
4378: ,p_encoded => fnd_api.g_false
4379: ,x_data => x_message_list);
4380: x_return_status := fnd_api.g_ret_sts_error;
4381: WHEN OTHERS THEN
4382: IF g_debug <= gme_debug.g_log_unexpected THEN
4383: gme_debug.put_line ( 'When others exception in '
4384: || g_pkg_name

Line 4394: ,p_encoded => fnd_api.g_false

4390:
4391: ROLLBACK TO SAVEPOINT update_pp_lot;
4392: x_pending_product_lots_rec := NULL;
4393: gme_common_pvt.count_and_get (x_count => x_message_count
4394: ,p_encoded => fnd_api.g_false
4395: ,x_data => x_message_list);
4396: x_return_status := fnd_api.g_ret_sts_unexp_error;
4397: END update_pending_product_lot;
4398:

Line 4396: x_return_status := fnd_api.g_ret_sts_unexp_error;

4392: x_pending_product_lots_rec := NULL;
4393: gme_common_pvt.count_and_get (x_count => x_message_count
4394: ,p_encoded => fnd_api.g_false
4395: ,x_data => x_message_list);
4396: x_return_status := fnd_api.g_ret_sts_unexp_error;
4397: END update_pending_product_lot;
4398:
4399: PROCEDURE delete_pending_product_lot (
4400: p_validation_level IN NUMBER

Line 4402: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false

4398:
4399: PROCEDURE delete_pending_product_lot (
4400: p_validation_level IN NUMBER
4401: := gme_common_pvt.g_max_errors
4402: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
4403: ,x_message_count OUT NOCOPY NUMBER
4404: ,x_message_list OUT NOCOPY VARCHAR2
4405: ,x_return_status OUT NOCOPY VARCHAR2
4406: ,p_org_id IN NUMBER

Line 4429: x_return_status := fnd_api.g_ret_sts_error;

4425: gme_common_pvt.g_setup_done :=
4426: gme_common_pvt.setup (p_org_id);
4427:
4428: IF NOT gme_common_pvt.g_setup_done THEN
4429: x_return_status := fnd_api.g_ret_sts_error;
4430: RAISE setup_failure;
4431: END IF;
4432: END IF;
4433:

Line 4435: x_return_status := fnd_api.g_ret_sts_success;

4431: END IF;
4432: END IF;
4433:
4434: /* Set the return status to success initially */
4435: x_return_status := fnd_api.g_ret_sts_success;
4436:
4437: -- Initialize message list and count if needed
4438: IF p_init_msg_list = fnd_api.g_true THEN
4439: fnd_msg_pub.initialize;

Line 4438: IF p_init_msg_list = fnd_api.g_true THEN

4434: /* Set the return status to success initially */
4435: x_return_status := fnd_api.g_ret_sts_success;
4436:
4437: -- Initialize message list and count if needed
4438: IF p_init_msg_list = fnd_api.g_true THEN
4439: fnd_msg_pub.initialize;
4440: gme_common_pvt.g_error_count := 0;
4441: END IF;
4442:

Line 4448: IF x_return_status <> fnd_api.g_ret_sts_success THEN

4444: gme_pending_product_lots_pvt.delete_pending_product_lot
4445: (p_pending_product_lots_rec => p_pending_product_lots_rec
4446: ,x_return_status => x_return_status);
4447:
4448: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4449: RAISE delete_pp_lot_failure;
4450: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4451:
4452: gme_common_pvt.log_message ('GME_API_PP_LOT_DELETED');

Line 4450: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */

4446: ,x_return_status => x_return_status);
4447:
4448: IF x_return_status <> fnd_api.g_ret_sts_success THEN
4449: RAISE delete_pp_lot_failure;
4450: END IF; /* IF x_return_status <> FND_API.G_RET_STS_SUCCESS */
4451:
4452: gme_common_pvt.log_message ('GME_API_PP_LOT_DELETED');
4453:
4454:

Line 4456: ,p_encoded => fnd_api.g_false

4452: gme_common_pvt.log_message ('GME_API_PP_LOT_DELETED');
4453:
4454:
4455: gme_common_pvt.count_and_get (x_count => x_message_count
4456: ,p_encoded => fnd_api.g_false
4457: ,x_data => x_message_list);
4458:
4459: IF (g_debug IS NOT NULL) THEN
4460: gme_debug.put_line ( 'Completed '

Line 4473: ,p_encoded => fnd_api.g_false

4469: EXCEPTION
4470: WHEN delete_pp_lot_failure THEN
4471: ROLLBACK TO SAVEPOINT delete_pp_lot;
4472: gme_common_pvt.count_and_get (x_count => x_message_count
4473: ,p_encoded => fnd_api.g_false
4474: ,x_data => x_message_list);
4475: WHEN setup_failure THEN
4476: ROLLBACK TO SAVEPOINT delete_pp_lot;
4477: gme_common_pvt.count_and_get (x_count => x_message_count

Line 4478: ,p_encoded => fnd_api.g_false

4474: ,x_data => x_message_list);
4475: WHEN setup_failure THEN
4476: ROLLBACK TO SAVEPOINT delete_pp_lot;
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
4482: IF g_debug <= gme_debug.g_log_unexpected THEN

Line 4480: x_return_status := fnd_api.g_ret_sts_error;

4476: ROLLBACK TO SAVEPOINT delete_pp_lot;
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
4482: IF g_debug <= gme_debug.g_log_unexpected THEN
4483: gme_debug.put_line ( 'When others exception in '
4484: || g_pkg_name

Line 4493: ,p_encoded => fnd_api.g_false

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

Line 4495: x_return_status := fnd_api.g_ret_sts_unexp_error;

4491: ROLLBACK TO SAVEPOINT delete_pp_lot;
4492: gme_common_pvt.count_and_get (x_count => x_message_count
4493: ,p_encoded => fnd_api.g_false
4494: ,x_data => x_message_list);
4495: x_return_status := fnd_api.g_ret_sts_unexp_error;
4496: END delete_pending_product_lot;
4497:
4498: END gme_api_main;