DBA Data[Home] [Help]

APPS.INV_RESERVATION_VALIDATE_PVT dependencies on FND_API

Line 30: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

26: x_return_status OUT NOCOPY VARCHAR2
27: , p_organization_id IN NUMBER
28: , x_org_cache_index out NOCOPY INTEGER
29: ) IS
30: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
31: l_index NUMBER := NULL;
32: l_rec inv_reservation_global.organization_record;
33:
34: BEGIN

Line 39: RAISE fnd_api.g_exc_error;

35: --
36: IF p_organization_id IS NULL THEN
37: fnd_message.set_name('INV', 'INV_NO ORG INFORMATION');
38: fnd_msg_pub.add;
39: RAISE fnd_api.g_exc_error;
40: END IF;
41: --
42: inv_reservation_util_pvt.search_organization_cache
43: (

Line 49: IF l_return_status = fnd_api.g_ret_sts_error THEN

45: , p_organization_id => p_organization_id
46: , x_index => l_index
47: );
48: --
49: IF l_return_status = fnd_api.g_ret_sts_error THEN
50: RAISE fnd_api.g_exc_error;
51: End IF ;
52: --
53: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 50: RAISE fnd_api.g_exc_error;

46: , x_index => l_index
47: );
48: --
49: IF l_return_status = fnd_api.g_ret_sts_error THEN
50: RAISE fnd_api.g_exc_error;
51: End IF ;
52: --
53: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
54: RAISE fnd_api.g_exc_unexpected_error;

Line 53: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

49: IF l_return_status = fnd_api.g_ret_sts_error THEN
50: RAISE fnd_api.g_exc_error;
51: End IF ;
52: --
53: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
54: RAISE fnd_api.g_exc_unexpected_error;
55: End IF;
56: --
57: IF l_index IS NULL THEN

Line 54: RAISE fnd_api.g_exc_unexpected_error;

50: RAISE fnd_api.g_exc_error;
51: End IF ;
52: --
53: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
54: RAISE fnd_api.g_exc_unexpected_error;
55: End IF;
56: --
57: IF l_index IS NULL THEN
58: /* BEGIN

Line 72: RAISE fnd_api.g_exc_error;

68: EXCEPTION
69: WHEN no_data_found THEN
70: fnd_message.set_name('INV', 'INVALID ORGANIZATION');
71: fnd_msg_pub.add;
72: RAISE fnd_api.g_exc_error;
73: END;
74: */
75: -- Modified to call common API
76: l_rec.organization_id:=p_organization_id;

Line 82: RAISE fnd_api.g_exc_error;

78: p_org => l_rec
79: )=INV_Validate.F THEN
80: fnd_message.set_name('INV', 'INVALID ORGANIZATION');
81: fnd_msg_pub.add;
82: RAISE fnd_api.g_exc_error;
83: END IF;
84:
85: --
86: inv_reservation_util_pvt.add_organization_cache

Line 93: IF l_return_status = fnd_api.g_ret_sts_error THEN

89: , p_organization_record => l_rec
90: , x_index => l_index
91: );
92: --
93: IF l_return_status = fnd_api.g_ret_sts_error THEN
94: RAISE fnd_api.g_exc_error;
95: End IF ;
96:
97: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 94: RAISE fnd_api.g_exc_error;

90: , x_index => l_index
91: );
92: --
93: IF l_return_status = fnd_api.g_ret_sts_error THEN
94: RAISE fnd_api.g_exc_error;
95: End IF ;
96:
97: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
98: RAISE fnd_api.g_exc_unexpected_error;

Line 97: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

93: IF l_return_status = fnd_api.g_ret_sts_error THEN
94: RAISE fnd_api.g_exc_error;
95: End IF ;
96:
97: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
98: RAISE fnd_api.g_exc_unexpected_error;
99: End IF;
100: --
101: END IF;

Line 98: RAISE fnd_api.g_exc_unexpected_error;

94: RAISE fnd_api.g_exc_error;
95: End IF ;
96:
97: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
98: RAISE fnd_api.g_exc_unexpected_error;
99: End IF;
100: --
101: END IF;
102: --

Line 107: WHEN fnd_api.g_exc_error THEN

103: x_org_cache_index := l_index;
104: x_return_status := l_return_status;
105: --
106: EXCEPTION
107: WHEN fnd_api.g_exc_error THEN
108: x_return_status := fnd_api.g_ret_sts_error;
109: --
110: WHEN fnd_api.g_exc_unexpected_error THEN
111: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 108: x_return_status := fnd_api.g_ret_sts_error;

104: x_return_status := l_return_status;
105: --
106: EXCEPTION
107: WHEN fnd_api.g_exc_error THEN
108: x_return_status := fnd_api.g_ret_sts_error;
109: --
110: WHEN fnd_api.g_exc_unexpected_error THEN
111: x_return_status := fnd_api.g_ret_sts_unexp_error ;
112: --

Line 110: WHEN fnd_api.g_exc_unexpected_error THEN

106: EXCEPTION
107: WHEN fnd_api.g_exc_error THEN
108: x_return_status := fnd_api.g_ret_sts_error;
109: --
110: WHEN fnd_api.g_exc_unexpected_error THEN
111: x_return_status := fnd_api.g_ret_sts_unexp_error ;
112: --
113: WHEN OTHERS THEN
114: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 111: x_return_status := fnd_api.g_ret_sts_unexp_error ;

107: WHEN fnd_api.g_exc_error THEN
108: x_return_status := fnd_api.g_ret_sts_error;
109: --
110: WHEN fnd_api.g_exc_unexpected_error THEN
111: x_return_status := fnd_api.g_ret_sts_unexp_error ;
112: --
113: WHEN OTHERS THEN
114: x_return_status := fnd_api.g_ret_sts_unexp_error ;
115: --

Line 114: x_return_status := fnd_api.g_ret_sts_unexp_error ;

110: WHEN fnd_api.g_exc_unexpected_error THEN
111: x_return_status := fnd_api.g_ret_sts_unexp_error ;
112: --
113: WHEN OTHERS THEN
114: x_return_status := fnd_api.g_ret_sts_unexp_error ;
115: --
116: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
117: THEN
118: fnd_msg_pub.add_exc_msg

Line 139: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

135: , p_inventory_item_id IN NUMBER
136: , p_organization_id IN NUMBER
137: , x_item_cache_index OUT NOCOPY INTEGER
138: ) IS
139: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
140: l_rec inv_reservation_global.item_record;
141: l_index NUMBER := NULL;
142: -- Added to call common API
143: l_rec_org inv_reservation_global.organization_record;

Line 151: RAISE fnd_api.g_exc_error;

147: --
148: IF p_inventory_item_id IS NULL THEN
149: fnd_message.set_name('INV', 'INV_ENTER_ITEM');
150: fnd_msg_pub.add;
151: RAISE fnd_api.g_exc_error;
152: END IF;
153: --
154: inv_reservation_util_pvt.search_item_cache
155: (

Line 162: IF l_return_status = fnd_api.g_ret_sts_error THEN

158: , p_organization_id => p_organization_id
159: , x_index => l_index
160: );
161: --
162: IF l_return_status = fnd_api.g_ret_sts_error THEN
163: RAISE fnd_api.g_exc_error;
164: End IF ;
165: --
166: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 163: RAISE fnd_api.g_exc_error;

159: , x_index => l_index
160: );
161: --
162: IF l_return_status = fnd_api.g_ret_sts_error THEN
163: RAISE fnd_api.g_exc_error;
164: End IF ;
165: --
166: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
167: RAISE fnd_api.g_exc_unexpected_error;

Line 166: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

162: IF l_return_status = fnd_api.g_ret_sts_error THEN
163: RAISE fnd_api.g_exc_error;
164: End IF ;
165: --
166: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
167: RAISE fnd_api.g_exc_unexpected_error;
168: End IF;
169: --
170: IF l_index IS NULL THEN

Line 167: RAISE fnd_api.g_exc_unexpected_error;

163: RAISE fnd_api.g_exc_error;
164: End IF ;
165: --
166: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
167: RAISE fnd_api.g_exc_unexpected_error;
168: End IF;
169: --
170: IF l_index IS NULL THEN
171: /* BEGIN -- not in cache, load it

Line 193: RAISE fnd_api.g_exc_error;

189: EXCEPTION
190: WHEN no_data_found THEN
191: fnd_message.set_name('INV', 'INVALID ORGANIZATION');
192: fnd_msg_pub.add;
193: RAISE fnd_api.g_exc_error;
194: END;*/
195: -- Modified to call new common API
196: l_rec.inventory_item_id:=p_inventory_item_id;
197: IF INV_Validate.Inventory_Item(

Line 203: RAISE fnd_api.g_exc_error;

199: p_org => l_rec_org
200: )=INV_Validate.F THEN
201: fnd_message.set_name('INV', 'INVALID ITEM');
202: fnd_msg_pub.add;
203: RAISE fnd_api.g_exc_error;
204: END IF;
205:
206: --
207: IF l_rec.reservable_type = 2 THEN /* non reservable item */

Line 210: RAISE fnd_api.g_exc_error;

206: --
207: IF l_rec.reservable_type = 2 THEN /* non reservable item */
208: fnd_message.set_name('INV','INV-ITEM NOT RESERVABLE');
209: fnd_msg_pub.add;
210: RAISE fnd_api.g_exc_error;
211: END IF;
212: --
213: inv_reservation_util_pvt.add_item_cache
214: (

Line 220: IF l_return_status = fnd_api.g_ret_sts_error THEN

216: , p_item_record => l_rec
217: , x_index => l_index
218: );
219: --
220: IF l_return_status = fnd_api.g_ret_sts_error THEN
221: RAISE fnd_api.g_exc_error;
222: End IF ;
223: --
224: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 221: RAISE fnd_api.g_exc_error;

217: , x_index => l_index
218: );
219: --
220: IF l_return_status = fnd_api.g_ret_sts_error THEN
221: RAISE fnd_api.g_exc_error;
222: End IF ;
223: --
224: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
225: RAISE fnd_api.g_exc_unexpected_error;

Line 224: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

220: IF l_return_status = fnd_api.g_ret_sts_error THEN
221: RAISE fnd_api.g_exc_error;
222: End IF ;
223: --
224: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
225: RAISE fnd_api.g_exc_unexpected_error;
226: END IF;
227: END IF;
228: --

Line 225: RAISE fnd_api.g_exc_unexpected_error;

221: RAISE fnd_api.g_exc_error;
222: End IF ;
223: --
224: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
225: RAISE fnd_api.g_exc_unexpected_error;
226: END IF;
227: END IF;
228: --
229: x_item_cache_index := l_index;

Line 233: WHEN fnd_api.g_exc_error THEN

229: x_item_cache_index := l_index;
230: x_return_status := l_return_status;
231: --
232: EXCEPTION
233: WHEN fnd_api.g_exc_error THEN
234: x_return_status := fnd_api.g_ret_sts_error;
235: --
236: WHEN fnd_api.g_exc_unexpected_error THEN
237: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 234: x_return_status := fnd_api.g_ret_sts_error;

230: x_return_status := l_return_status;
231: --
232: EXCEPTION
233: WHEN fnd_api.g_exc_error THEN
234: x_return_status := fnd_api.g_ret_sts_error;
235: --
236: WHEN fnd_api.g_exc_unexpected_error THEN
237: x_return_status := fnd_api.g_ret_sts_unexp_error ;
238: --

Line 236: WHEN fnd_api.g_exc_unexpected_error THEN

232: EXCEPTION
233: WHEN fnd_api.g_exc_error THEN
234: x_return_status := fnd_api.g_ret_sts_error;
235: --
236: WHEN fnd_api.g_exc_unexpected_error THEN
237: x_return_status := fnd_api.g_ret_sts_unexp_error ;
238: --
239: WHEN OTHERS THEN
240: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 237: x_return_status := fnd_api.g_ret_sts_unexp_error ;

233: WHEN fnd_api.g_exc_error THEN
234: x_return_status := fnd_api.g_ret_sts_error;
235: --
236: WHEN fnd_api.g_exc_unexpected_error THEN
237: x_return_status := fnd_api.g_ret_sts_unexp_error ;
238: --
239: WHEN OTHERS THEN
240: x_return_status := fnd_api.g_ret_sts_unexp_error ;
241: --

Line 240: x_return_status := fnd_api.g_ret_sts_unexp_error ;

236: WHEN fnd_api.g_exc_unexpected_error THEN
237: x_return_status := fnd_api.g_ret_sts_unexp_error ;
238: --
239: WHEN OTHERS THEN
240: x_return_status := fnd_api.g_ret_sts_unexp_error ;
241: --
242: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
243: THEN
244: fnd_msg_pub.add_exc_msg

Line 277: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

273: l_valid_supply VARCHAR2(1);
274: /*** {{ R12 Enhanced reservations code changes }}***/
275: l_dropship_count NUMBER := 0;
276: l_debug NUMBER;
277: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
278: l_msg_count NUMBER;
279: l_msg_data VARCHAR2(1000);
280: l_valid_status VARCHAR2(1);
281: /*** End R12 }} ***/

Line 307: RAISE fnd_api.g_exc_error;

303:
304: --error message
305: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_PO');
306: fnd_msg_pub.add;
307: RAISE fnd_api.g_exc_error;
308: END IF;
309: *** End R12 }} ***/
310:
311: /*** {{ R12 Enhanced reservations code changes ***/

Line 340: , p_init_msg_lst => fnd_api.g_false

336: , p_supply_demand_line_detail => p_supply_source_line_detail
337: , p_demand_ship_date => p_demand_ship_date
338: , p_expected_receipt_date => p_supply_receipt_date
339: , p_api_version_number => 1.0
340: , p_init_msg_lst => fnd_api.g_false
341: );
342:
343: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
344: RAISE fnd_api.g_exc_error;

Line 343: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

339: , p_api_version_number => 1.0
340: , p_init_msg_lst => fnd_api.g_false
341: );
342:
343: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
344: RAISE fnd_api.g_exc_error;
345: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
346: RAISE fnd_api.g_exc_unexpected_error;
347: END IF;

Line 344: RAISE fnd_api.g_exc_error;

340: , p_init_msg_lst => fnd_api.g_false
341: );
342:
343: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
344: RAISE fnd_api.g_exc_error;
345: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
346: RAISE fnd_api.g_exc_unexpected_error;
347: END IF;
348:

Line 345: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

341: );
342:
343: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
344: RAISE fnd_api.g_exc_error;
345: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
346: RAISE fnd_api.g_exc_unexpected_error;
347: END IF;
348:
349: IF (l_debug = 1) THEN

Line 346: RAISE fnd_api.g_exc_unexpected_error;

342:
343: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
344: RAISE fnd_api.g_exc_error;
345: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
346: RAISE fnd_api.g_exc_unexpected_error;
347: END IF;
348:
349: IF (l_debug = 1) THEN
350: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 356: RAISE fnd_api.g_exc_error;

352:
353: IF (l_valid_status = 'N') THEN
354: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_PO');
355: fnd_msg_pub.ADD;
356: RAISE fnd_api.g_exc_error;
357: END IF;
358:
359: select count(1)
360: into l_dropship_count

Line 373: RAISE fnd_api.g_exc_error;

369: IF (l_dropship_count >= 1) THEN
370: fnd_message.set_name('INV', 'INV_RSV_DS_SO_SUP');
371: fnd_message.set_name('SOURCE', 'PO');
372: fnd_msg_pub.add;
373: RAISE fnd_api.g_exc_error;
374: END IF;
375: ELSE
376: IF (l_debug = 1) THEN
377: debug_print('The transation source type is not PO');

Line 379: RAISE fnd_api.g_exc_error;

375: ELSE
376: IF (l_debug = 1) THEN
377: debug_print('The transation source type is not PO');
378: END IF;
379: RAISE fnd_api.g_exc_error;
380:
381: END IF;
382: /*** End R12 }} ***/
383:

Line 387: WHEN fnd_api.g_exc_error THEN

383:
384: x_return_status := l_return_status;
385:
386: EXCEPTION
387: WHEN fnd_api.g_exc_error THEN
388: x_return_status := fnd_api.g_ret_sts_error;
389: --
390: WHEN fnd_api.g_exc_unexpected_error THEN
391: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 388: x_return_status := fnd_api.g_ret_sts_error;

384: x_return_status := l_return_status;
385:
386: EXCEPTION
387: WHEN fnd_api.g_exc_error THEN
388: x_return_status := fnd_api.g_ret_sts_error;
389: --
390: WHEN fnd_api.g_exc_unexpected_error THEN
391: x_return_status := fnd_api.g_ret_sts_unexp_error ;
392: --

Line 390: WHEN fnd_api.g_exc_unexpected_error THEN

386: EXCEPTION
387: WHEN fnd_api.g_exc_error THEN
388: x_return_status := fnd_api.g_ret_sts_error;
389: --
390: WHEN fnd_api.g_exc_unexpected_error THEN
391: x_return_status := fnd_api.g_ret_sts_unexp_error ;
392: --
393: WHEN OTHERS THEN
394: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 391: x_return_status := fnd_api.g_ret_sts_unexp_error ;

387: WHEN fnd_api.g_exc_error THEN
388: x_return_status := fnd_api.g_ret_sts_error;
389: --
390: WHEN fnd_api.g_exc_unexpected_error THEN
391: x_return_status := fnd_api.g_ret_sts_unexp_error ;
392: --
393: WHEN OTHERS THEN
394: x_return_status := fnd_api.g_ret_sts_unexp_error ;
395: --

Line 394: x_return_status := fnd_api.g_ret_sts_unexp_error ;

390: WHEN fnd_api.g_exc_unexpected_error THEN
391: x_return_status := fnd_api.g_ret_sts_unexp_error ;
392: --
393: WHEN OTHERS THEN
394: x_return_status := fnd_api.g_ret_sts_unexp_error ;
395: --
396: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
397: THEN
398: fnd_msg_pub.add_exc_msg

Line 432: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

428: l_valid_supply VARCHAR2(1);
429: /*** {{ R12 Enhanced reservations code changes }}***/
430: l_dropship_count NUMBER := 0;
431: l_debug NUMBER;
432: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
433: l_msg_count NUMBER;
434: l_msg_data VARCHAR2(1000);
435: l_valid_status VARCHAR2(1);
436: /*** End R12 }} ***/

Line 469: RAISE fnd_api.g_exc_error;

465:
466: --error message
467: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_REQ');
468: fnd_msg_pub.add;
469: RAISE fnd_api.g_exc_error;
470: END IF;
471:
472: select count(1)
473: into l_dropship_count

Line 486: RAISE fnd_api.g_exc_error;

482: IF (l_dropship_count >= 1) THEN
483: fnd_message.set_name('INV', 'INV_RSV_DS_SO_SUP');
484: fnd_message.set_token('SOURCE', 'requisition');
485: fnd_msg_pub.add;
486: RAISE fnd_api.g_exc_error;
487: END IF;
488: ELSE
489: IF (l_debug = 1) THEN
490: debug_print('The transation source type is not requisition');

Line 492: RAISE fnd_api.g_exc_error;

488: ELSE
489: IF (l_debug = 1) THEN
490: debug_print('The transation source type is not requisition');
491: END IF;
492: RAISE fnd_api.g_exc_error;
493:
494: END IF;
495: /*** End R12 }} ***/
496:

Line 500: WHEN fnd_api.g_exc_error THEN

496:
497: x_return_status := l_return_status;
498:
499: EXCEPTION
500: WHEN fnd_api.g_exc_error THEN
501: x_return_status := fnd_api.g_ret_sts_error;
502: --
503: WHEN fnd_api.g_exc_unexpected_error THEN
504: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 501: x_return_status := fnd_api.g_ret_sts_error;

497: x_return_status := l_return_status;
498:
499: EXCEPTION
500: WHEN fnd_api.g_exc_error THEN
501: x_return_status := fnd_api.g_ret_sts_error;
502: --
503: WHEN fnd_api.g_exc_unexpected_error THEN
504: x_return_status := fnd_api.g_ret_sts_unexp_error ;
505: --

Line 503: WHEN fnd_api.g_exc_unexpected_error THEN

499: EXCEPTION
500: WHEN fnd_api.g_exc_error THEN
501: x_return_status := fnd_api.g_ret_sts_error;
502: --
503: WHEN fnd_api.g_exc_unexpected_error THEN
504: x_return_status := fnd_api.g_ret_sts_unexp_error ;
505: --
506: WHEN OTHERS THEN
507: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 504: x_return_status := fnd_api.g_ret_sts_unexp_error ;

500: WHEN fnd_api.g_exc_error THEN
501: x_return_status := fnd_api.g_ret_sts_error;
502: --
503: WHEN fnd_api.g_exc_unexpected_error THEN
504: x_return_status := fnd_api.g_ret_sts_unexp_error ;
505: --
506: WHEN OTHERS THEN
507: x_return_status := fnd_api.g_ret_sts_unexp_error ;
508: --

Line 507: x_return_status := fnd_api.g_ret_sts_unexp_error ;

503: WHEN fnd_api.g_exc_unexpected_error THEN
504: x_return_status := fnd_api.g_ret_sts_unexp_error ;
505: --
506: WHEN OTHERS THEN
507: x_return_status := fnd_api.g_ret_sts_unexp_error ;
508: --
509: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
510: THEN
511: fnd_msg_pub.add_exc_msg

Line 538: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

534: , p_supply_source_line_id IN NUMBER
535: , p_supply_source_line_detail IN NUMBER
536: ) IS
537: l_debug NUMBER;
538: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
539: l_msg_count NUMBER;
540: l_msg_data VARCHAR2(1000);
541: l_valid_status VARCHAR2(1);
542:

Line 573: , p_init_msg_lst => fnd_api.g_false

569: , p_supply_demand_line_detail => p_supply_source_line_detail
570: , p_demand_ship_date => p_demand_ship_date
571: , p_expected_receipt_date => p_supply_receipt_date
572: , p_api_version_number => 1.0
573: , p_init_msg_lst => fnd_api.g_false
574: );
575:
576: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
577: RAISE fnd_api.g_exc_error;

Line 576: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

572: , p_api_version_number => 1.0
573: , p_init_msg_lst => fnd_api.g_false
574: );
575:
576: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
577: RAISE fnd_api.g_exc_error;
578: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
579: RAISE fnd_api.g_exc_unexpected_error;
580: END IF;

Line 577: RAISE fnd_api.g_exc_error;

573: , p_init_msg_lst => fnd_api.g_false
574: );
575:
576: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
577: RAISE fnd_api.g_exc_error;
578: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
579: RAISE fnd_api.g_exc_unexpected_error;
580: END IF;
581:

Line 578: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

574: );
575:
576: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
577: RAISE fnd_api.g_exc_error;
578: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
579: RAISE fnd_api.g_exc_unexpected_error;
580: END IF;
581:
582: IF (l_debug = 1) THEN

Line 579: RAISE fnd_api.g_exc_unexpected_error;

575:
576: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
577: RAISE fnd_api.g_exc_error;
578: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
579: RAISE fnd_api.g_exc_unexpected_error;
580: END IF;
581:
582: IF (l_debug = 1) THEN
583: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 589: RAISE fnd_api.g_exc_error;

585:
586: IF (l_valid_status = 'N') THEN
587: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_INTREQ');
588: fnd_msg_pub.ADD;
589: RAISE fnd_api.g_exc_error;
590: END IF;
591: ELSE
592: IF (l_debug = 1) THEN
593: debug_print('The transation source type is not internal requisition');

Line 595: RAISE fnd_api.g_exc_error;

591: ELSE
592: IF (l_debug = 1) THEN
593: debug_print('The transation source type is not internal requisition');
594: END IF;
595: RAISE fnd_api.g_exc_error;
596:
597: END IF;
598: /*** End R12 }} ***/
599:

Line 603: WHEN fnd_api.g_exc_error THEN

599:
600: x_return_status := l_return_status;
601:
602: EXCEPTION
603: WHEN fnd_api.g_exc_error THEN
604: x_return_status := fnd_api.g_ret_sts_error;
605: --
606: WHEN fnd_api.g_exc_unexpected_error THEN
607: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 604: x_return_status := fnd_api.g_ret_sts_error;

600: x_return_status := l_return_status;
601:
602: EXCEPTION
603: WHEN fnd_api.g_exc_error THEN
604: x_return_status := fnd_api.g_ret_sts_error;
605: --
606: WHEN fnd_api.g_exc_unexpected_error THEN
607: x_return_status := fnd_api.g_ret_sts_unexp_error ;
608: --

Line 606: WHEN fnd_api.g_exc_unexpected_error THEN

602: EXCEPTION
603: WHEN fnd_api.g_exc_error THEN
604: x_return_status := fnd_api.g_ret_sts_error;
605: --
606: WHEN fnd_api.g_exc_unexpected_error THEN
607: x_return_status := fnd_api.g_ret_sts_unexp_error ;
608: --
609: WHEN OTHERS THEN
610: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 607: x_return_status := fnd_api.g_ret_sts_unexp_error ;

603: WHEN fnd_api.g_exc_error THEN
604: x_return_status := fnd_api.g_ret_sts_error;
605: --
606: WHEN fnd_api.g_exc_unexpected_error THEN
607: x_return_status := fnd_api.g_ret_sts_unexp_error ;
608: --
609: WHEN OTHERS THEN
610: x_return_status := fnd_api.g_ret_sts_unexp_error ;
611: --

Line 610: x_return_status := fnd_api.g_ret_sts_unexp_error ;

606: WHEN fnd_api.g_exc_unexpected_error THEN
607: x_return_status := fnd_api.g_ret_sts_unexp_error ;
608: --
609: WHEN OTHERS THEN
610: x_return_status := fnd_api.g_ret_sts_unexp_error ;
611: --
612: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
613: THEN
614: fnd_msg_pub.add_exc_msg

Line 643: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

639: ) IS
640:
641: l_wms_enabled VARCHAR2(1) := 'N';
642: l_debug NUMBER;
643: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
644: l_msg_count NUMBER;
645: l_msg_data VARCHAR2(1000);
646: l_valid_status VARCHAR2(1);
647: BEGIN

Line 678: , p_init_msg_lst => fnd_api.g_false

674: , p_supply_demand_line_detail => p_supply_source_line_detail
675: , p_demand_ship_date => p_demand_ship_date
676: , p_expected_receipt_date => p_supply_receipt_date
677: , p_api_version_number => 1.0
678: , p_init_msg_lst => fnd_api.g_false
679: );
680:
681: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
682: RAISE fnd_api.g_exc_error;

Line 681: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

677: , p_api_version_number => 1.0
678: , p_init_msg_lst => fnd_api.g_false
679: );
680:
681: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
682: RAISE fnd_api.g_exc_error;
683: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
684: RAISE fnd_api.g_exc_unexpected_error;
685: END IF;

Line 682: RAISE fnd_api.g_exc_error;

678: , p_init_msg_lst => fnd_api.g_false
679: );
680:
681: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
682: RAISE fnd_api.g_exc_error;
683: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
684: RAISE fnd_api.g_exc_unexpected_error;
685: END IF;
686:

Line 683: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

679: );
680:
681: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
682: RAISE fnd_api.g_exc_error;
683: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
684: RAISE fnd_api.g_exc_unexpected_error;
685: END IF;
686:
687: IF (l_debug = 1) THEN

Line 684: RAISE fnd_api.g_exc_unexpected_error;

680:
681: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
682: RAISE fnd_api.g_exc_error;
683: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
684: RAISE fnd_api.g_exc_unexpected_error;
685: END IF;
686:
687: IF (l_debug = 1) THEN
688: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 694: RAISE fnd_api.g_exc_error;

690:
691: IF (l_valid_status = 'N') THEN
692: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_ASN');
693: fnd_msg_pub.ADD;
694: RAISE fnd_api.g_exc_error;
695: END IF;
696:
697: SELECT wms_enabled_flag
698: INTO l_wms_enabled

Line 710: RAISE fnd_api.g_exc_error;

706: IF (l_wms_enabled = 'N') THEN
707: fnd_message.set_name('INV', 'INV_RSV_NON_WMS');
708: fnd_message.set_name('SOURCE', 'ASN');
709: fnd_msg_pub.add;
710: RAISE fnd_api.g_exc_error;
711: END IF;
712: ELSE
713: IF (l_debug = 1) THEN
714: debug_print('The transation source type is not ASN');

Line 716: RAISE fnd_api.g_exc_error;

712: ELSE
713: IF (l_debug = 1) THEN
714: debug_print('The transation source type is not ASN');
715: END IF;
716: RAISE fnd_api.g_exc_error;
717:
718: END IF;
719: x_return_status := l_return_status;
720:

Line 722: WHEN fnd_api.g_exc_error THEN

718: END IF;
719: x_return_status := l_return_status;
720:
721: EXCEPTION
722: WHEN fnd_api.g_exc_error THEN
723: x_return_status := fnd_api.g_ret_sts_error;
724: --
725: WHEN fnd_api.g_exc_unexpected_error THEN
726: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 723: x_return_status := fnd_api.g_ret_sts_error;

719: x_return_status := l_return_status;
720:
721: EXCEPTION
722: WHEN fnd_api.g_exc_error THEN
723: x_return_status := fnd_api.g_ret_sts_error;
724: --
725: WHEN fnd_api.g_exc_unexpected_error THEN
726: x_return_status := fnd_api.g_ret_sts_unexp_error ;
727: --

Line 725: WHEN fnd_api.g_exc_unexpected_error THEN

721: EXCEPTION
722: WHEN fnd_api.g_exc_error THEN
723: x_return_status := fnd_api.g_ret_sts_error;
724: --
725: WHEN fnd_api.g_exc_unexpected_error THEN
726: x_return_status := fnd_api.g_ret_sts_unexp_error ;
727: --
728: WHEN OTHERS THEN
729: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 726: x_return_status := fnd_api.g_ret_sts_unexp_error ;

722: WHEN fnd_api.g_exc_error THEN
723: x_return_status := fnd_api.g_ret_sts_error;
724: --
725: WHEN fnd_api.g_exc_unexpected_error THEN
726: x_return_status := fnd_api.g_ret_sts_unexp_error ;
727: --
728: WHEN OTHERS THEN
729: x_return_status := fnd_api.g_ret_sts_unexp_error ;
730: --

Line 729: x_return_status := fnd_api.g_ret_sts_unexp_error ;

725: WHEN fnd_api.g_exc_unexpected_error THEN
726: x_return_status := fnd_api.g_ret_sts_unexp_error ;
727: --
728: WHEN OTHERS THEN
729: x_return_status := fnd_api.g_ret_sts_unexp_error ;
730: --
731: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
732: THEN
733: fnd_msg_pub.add_exc_msg

Line 762: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

758:
759: l_wms_enabled VARCHAR2(1) := 'N';
760: l_replenish_to_order VARCHAR2(1) := 'N';
761: l_debug NUMBER;
762: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
763: l_msg_count NUMBER;
764: l_msg_data VARCHAR2(1000);
765: l_valid_status VARCHAR2(1);
766: BEGIN

Line 797: , p_init_msg_lst => fnd_api.g_false

793: , p_supply_demand_line_detail => p_supply_source_line_detail
794: , p_demand_ship_date => p_demand_ship_date
795: , p_expected_receipt_date => p_supply_receipt_date
796: , p_api_version_number => 1.0
797: , p_init_msg_lst => fnd_api.g_false
798: );
799:
800: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
801: RAISE fnd_api.g_exc_error;

Line 800: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

796: , p_api_version_number => 1.0
797: , p_init_msg_lst => fnd_api.g_false
798: );
799:
800: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
801: RAISE fnd_api.g_exc_error;
802: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
803: RAISE fnd_api.g_exc_unexpected_error;
804: END IF;

Line 801: RAISE fnd_api.g_exc_error;

797: , p_init_msg_lst => fnd_api.g_false
798: );
799:
800: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
801: RAISE fnd_api.g_exc_error;
802: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
803: RAISE fnd_api.g_exc_unexpected_error;
804: END IF;
805:

Line 802: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

798: );
799:
800: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
801: RAISE fnd_api.g_exc_error;
802: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
803: RAISE fnd_api.g_exc_unexpected_error;
804: END IF;
805:
806: IF (l_debug = 1) THEN

Line 803: RAISE fnd_api.g_exc_unexpected_error;

799:
800: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
801: RAISE fnd_api.g_exc_error;
802: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
803: RAISE fnd_api.g_exc_unexpected_error;
804: END IF;
805:
806: IF (l_debug = 1) THEN
807: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 813: RAISE fnd_api.g_exc_error;

809:
810: IF (l_valid_status = 'N') THEN
811: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_INTRAN');
812: fnd_msg_pub.ADD;
813: RAISE fnd_api.g_exc_error;
814: END IF;
815:
816: SELECT wms_enabled_flag
817: INTO l_wms_enabled

Line 829: RAISE fnd_api.g_exc_error;

825: IF (l_wms_enabled = 'N') THEN
826: fnd_message.set_name('INV', 'INV_RSV_NON_WMS');
827: fnd_message.set_name('SOURCE', 'intransit shipment');
828: fnd_msg_pub.add;
829: RAISE fnd_api.g_exc_error;
830: END IF;
831:
832: SELECT replenish_to_order_flag
833: INTO l_replenish_to_order

Line 846: RAISE fnd_api.g_exc_error;

842: IF (l_replenish_to_order = 'Y') THEN
843: fnd_message.set_name('INV', 'INV_RSV_INT_REPLEN');
844: fnd_message.set_token('SOURCE', 'intransit shipment');
845: fnd_msg_pub.add;
846: RAISE fnd_api.g_exc_error;
847: END IF;
848: ELSE
849: IF (l_debug = 1) THEN
850: debug_print('The transation source type is not intransit shipment');

Line 852: RAISE fnd_api.g_exc_error;

848: ELSE
849: IF (l_debug = 1) THEN
850: debug_print('The transation source type is not intransit shipment');
851: END IF;
852: RAISE fnd_api.g_exc_error;
853:
854: END IF;
855: x_return_status := l_return_status;
856:

Line 858: WHEN fnd_api.g_exc_error THEN

854: END IF;
855: x_return_status := l_return_status;
856:
857: EXCEPTION
858: WHEN fnd_api.g_exc_error THEN
859: x_return_status := fnd_api.g_ret_sts_error;
860: --
861: WHEN fnd_api.g_exc_unexpected_error THEN
862: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 859: x_return_status := fnd_api.g_ret_sts_error;

855: x_return_status := l_return_status;
856:
857: EXCEPTION
858: WHEN fnd_api.g_exc_error THEN
859: x_return_status := fnd_api.g_ret_sts_error;
860: --
861: WHEN fnd_api.g_exc_unexpected_error THEN
862: x_return_status := fnd_api.g_ret_sts_unexp_error ;
863: --

Line 861: WHEN fnd_api.g_exc_unexpected_error THEN

857: EXCEPTION
858: WHEN fnd_api.g_exc_error THEN
859: x_return_status := fnd_api.g_ret_sts_error;
860: --
861: WHEN fnd_api.g_exc_unexpected_error THEN
862: x_return_status := fnd_api.g_ret_sts_unexp_error ;
863: --
864: WHEN OTHERS THEN
865: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 862: x_return_status := fnd_api.g_ret_sts_unexp_error ;

858: WHEN fnd_api.g_exc_error THEN
859: x_return_status := fnd_api.g_ret_sts_error;
860: --
861: WHEN fnd_api.g_exc_unexpected_error THEN
862: x_return_status := fnd_api.g_ret_sts_unexp_error ;
863: --
864: WHEN OTHERS THEN
865: x_return_status := fnd_api.g_ret_sts_unexp_error ;
866: --

Line 865: x_return_status := fnd_api.g_ret_sts_unexp_error ;

861: WHEN fnd_api.g_exc_unexpected_error THEN
862: x_return_status := fnd_api.g_ret_sts_unexp_error ;
863: --
864: WHEN OTHERS THEN
865: x_return_status := fnd_api.g_ret_sts_unexp_error ;
866: --
867: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
868: THEN
869: fnd_msg_pub.add_exc_msg

Line 897: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

893: ) IS
894:
895: l_wms_enabled VARCHAR2(1) := 'N';
896: l_debug NUMBER;
897: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
898: l_msg_count NUMBER;
899: l_msg_data VARCHAR2(1000);
900: l_valid_status VARCHAR2(1);
901: BEGIN

Line 933: , p_init_msg_lst => fnd_api.g_false

929: , p_supply_demand_line_detail => p_supply_source_line_detail
930: , p_demand_ship_date => p_demand_ship_date
931: , p_expected_receipt_date => p_supply_receipt_date
932: , p_api_version_number => 1.0
933: , p_init_msg_lst => fnd_api.g_false
934: );
935: */
936:
937: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

Line 937: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

933: , p_init_msg_lst => fnd_api.g_false
934: );
935: */
936:
937: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
938: RAISE fnd_api.g_exc_error;
939: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
940: RAISE fnd_api.g_exc_unexpected_error;
941: END IF;

Line 938: RAISE fnd_api.g_exc_error;

934: );
935: */
936:
937: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
938: RAISE fnd_api.g_exc_error;
939: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
940: RAISE fnd_api.g_exc_unexpected_error;
941: END IF;
942:

Line 939: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

935: */
936:
937: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
938: RAISE fnd_api.g_exc_error;
939: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
940: RAISE fnd_api.g_exc_unexpected_error;
941: END IF;
942:
943: IF (l_debug = 1) THEN

Line 940: RAISE fnd_api.g_exc_unexpected_error;

936:
937: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
938: RAISE fnd_api.g_exc_error;
939: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
940: RAISE fnd_api.g_exc_unexpected_error;
941: END IF;
942:
943: IF (l_debug = 1) THEN
944: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 950: RAISE fnd_api.g_exc_error;

946:
947: IF (l_valid_status = 'N') THEN
948: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_RCV');
949: fnd_msg_pub.ADD;
950: RAISE fnd_api.g_exc_error;
951: END IF;
952:
953: SELECT wms_enabled_flag
954: INTO l_wms_enabled

Line 966: RAISE fnd_api.g_exc_error;

962: IF (l_wms_enabled = 'N') THEN
963: fnd_message.set_name('INV', 'INV_RSV_NON_WMS');
964: fnd_message.set_name('SOURCE', 'receiving');
965: fnd_msg_pub.add;
966: RAISE fnd_api.g_exc_error;
967: END IF;
968: ELSE
969: IF (l_debug = 1) THEN
970: debug_print('The transaction source type is not receiving');

Line 972: RAISE fnd_api.g_exc_error;

968: ELSE
969: IF (l_debug = 1) THEN
970: debug_print('The transaction source type is not receiving');
971: END IF;
972: RAISE fnd_api.g_exc_error;
973: END IF;
974: x_return_status := l_return_status;
975:
976: EXCEPTION

Line 977: WHEN fnd_api.g_exc_error THEN

973: END IF;
974: x_return_status := l_return_status;
975:
976: EXCEPTION
977: WHEN fnd_api.g_exc_error THEN
978: x_return_status := fnd_api.g_ret_sts_error;
979: --
980: WHEN fnd_api.g_exc_unexpected_error THEN
981: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 978: x_return_status := fnd_api.g_ret_sts_error;

974: x_return_status := l_return_status;
975:
976: EXCEPTION
977: WHEN fnd_api.g_exc_error THEN
978: x_return_status := fnd_api.g_ret_sts_error;
979: --
980: WHEN fnd_api.g_exc_unexpected_error THEN
981: x_return_status := fnd_api.g_ret_sts_unexp_error ;
982: --

Line 980: WHEN fnd_api.g_exc_unexpected_error THEN

976: EXCEPTION
977: WHEN fnd_api.g_exc_error THEN
978: x_return_status := fnd_api.g_ret_sts_error;
979: --
980: WHEN fnd_api.g_exc_unexpected_error THEN
981: x_return_status := fnd_api.g_ret_sts_unexp_error ;
982: --
983: WHEN OTHERS THEN
984: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 981: x_return_status := fnd_api.g_ret_sts_unexp_error ;

977: WHEN fnd_api.g_exc_error THEN
978: x_return_status := fnd_api.g_ret_sts_error;
979: --
980: WHEN fnd_api.g_exc_unexpected_error THEN
981: x_return_status := fnd_api.g_ret_sts_unexp_error ;
982: --
983: WHEN OTHERS THEN
984: x_return_status := fnd_api.g_ret_sts_unexp_error ;
985: --

Line 984: x_return_status := fnd_api.g_ret_sts_unexp_error ;

980: WHEN fnd_api.g_exc_unexpected_error THEN
981: x_return_status := fnd_api.g_ret_sts_unexp_error ;
982: --
983: WHEN OTHERS THEN
984: x_return_status := fnd_api.g_ret_sts_unexp_error ;
985: --
986: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
987: THEN
988: fnd_msg_pub.add_exc_msg

Line 1014: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1010: , p_supply_source_line_detail IN NUMBER
1011: , p_wip_entity_type IN NUMBER
1012: ) IS
1013:
1014: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1015: l_msg_count NUMBER;
1016: l_msg_data VARCHAR2(1000);
1017: l_valid_status VARCHAR2(1);
1018: l_debug NUMBER;

Line 1052: , p_init_msg_lst => fnd_api.g_false

1048: , p_supply_demand_line_detail => p_supply_source_line_detail
1049: , p_demand_ship_date => p_demand_ship_date
1050: , p_expected_receipt_date => p_supply_receipt_date
1051: , p_api_version_number => 1.0
1052: , p_init_msg_lst => fnd_api.g_false
1053: );
1054:
1055: IF (l_debug = 1) THEN
1056: debug_print('Return status after calling validate supply demand wipdisc: ' || l_valid_status || ' : ' || l_return_status);

Line 1059: IF (l_valid_status = 'N') OR (l_return_status = fnd_api.g_ret_sts_error) THEN

1055: IF (l_debug = 1) THEN
1056: debug_print('Return status after calling validate supply demand wipdisc: ' || l_valid_status || ' : ' || l_return_status);
1057: END IF;
1058:
1059: IF (l_valid_status = 'N') OR (l_return_status = fnd_api.g_ret_sts_error) THEN
1060: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_DISC');
1061: fnd_msg_pub.ADD;
1062: RAISE fnd_api.g_exc_error;
1063: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

Line 1062: RAISE fnd_api.g_exc_error;

1058:
1059: IF (l_valid_status = 'N') OR (l_return_status = fnd_api.g_ret_sts_error) THEN
1060: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_DISC');
1061: fnd_msg_pub.ADD;
1062: RAISE fnd_api.g_exc_error;
1063: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1064: RAISE fnd_api.g_exc_unexpected_error;
1065: END IF;
1066: ELSE

Line 1063: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

1059: IF (l_valid_status = 'N') OR (l_return_status = fnd_api.g_ret_sts_error) THEN
1060: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_DISC');
1061: fnd_msg_pub.ADD;
1062: RAISE fnd_api.g_exc_error;
1063: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1064: RAISE fnd_api.g_exc_unexpected_error;
1065: END IF;
1066: ELSE
1067: IF (l_debug = 1) THEN

Line 1064: RAISE fnd_api.g_exc_unexpected_error;

1060: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_DISC');
1061: fnd_msg_pub.ADD;
1062: RAISE fnd_api.g_exc_error;
1063: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1064: RAISE fnd_api.g_exc_unexpected_error;
1065: END IF;
1066: ELSE
1067: IF (l_debug = 1) THEN
1068: debug_print('The wip entity type is not Discrete');

Line 1070: RAISE fnd_api.g_exc_error;

1066: ELSE
1067: IF (l_debug = 1) THEN
1068: debug_print('The wip entity type is not Discrete');
1069: END IF;
1070: RAISE fnd_api.g_exc_error;
1071: END IF;
1072: ELSE
1073: IF (l_debug = 1) THEN
1074: debug_print('The transation source type is not WIP discrete');

Line 1076: RAISE fnd_api.g_exc_error;

1072: ELSE
1073: IF (l_debug = 1) THEN
1074: debug_print('The transation source type is not WIP discrete');
1075: END IF;
1076: RAISE fnd_api.g_exc_error;
1077:
1078: END IF;
1079:
1080: x_return_status := l_return_status;

Line 1082: WHEN fnd_api.g_exc_error THEN

1078: END IF;
1079:
1080: x_return_status := l_return_status;
1081: EXCEPTION
1082: WHEN fnd_api.g_exc_error THEN
1083: x_return_status := fnd_api.g_ret_sts_error;
1084: --
1085: WHEN fnd_api.g_exc_unexpected_error THEN
1086: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1083: x_return_status := fnd_api.g_ret_sts_error;

1079:
1080: x_return_status := l_return_status;
1081: EXCEPTION
1082: WHEN fnd_api.g_exc_error THEN
1083: x_return_status := fnd_api.g_ret_sts_error;
1084: --
1085: WHEN fnd_api.g_exc_unexpected_error THEN
1086: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1087: --

Line 1085: WHEN fnd_api.g_exc_unexpected_error THEN

1081: EXCEPTION
1082: WHEN fnd_api.g_exc_error THEN
1083: x_return_status := fnd_api.g_ret_sts_error;
1084: --
1085: WHEN fnd_api.g_exc_unexpected_error THEN
1086: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1087: --
1088: WHEN OTHERS THEN
1089: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1086: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1082: WHEN fnd_api.g_exc_error THEN
1083: x_return_status := fnd_api.g_ret_sts_error;
1084: --
1085: WHEN fnd_api.g_exc_unexpected_error THEN
1086: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1087: --
1088: WHEN OTHERS THEN
1089: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1090: --

Line 1089: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1085: WHEN fnd_api.g_exc_unexpected_error THEN
1086: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1087: --
1088: WHEN OTHERS THEN
1089: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1090: --
1091: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1092: THEN
1093: fnd_msg_pub.add_exc_msg

Line 1121: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1117: , p_wip_entity_type IN NUMBER
1118: ) IS
1119:
1120: l_replenish_to_order VARCHAR2(1) := 'N';
1121: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1122: l_msg_count NUMBER;
1123: l_msg_data VARCHAR2(1000);
1124: l_valid_status VARCHAR2(1);
1125: l_debug NUMBER;

Line 1158: , p_init_msg_lst => fnd_api.g_false

1154: , p_supply_demand_line_detail => p_supply_source_line_detail
1155: , p_demand_ship_date => p_demand_ship_date
1156: , p_expected_receipt_date => p_supply_receipt_date
1157: , p_api_version_number => 1.0
1158: , p_init_msg_lst => fnd_api.g_false
1159: );
1160:
1161: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1162: RAISE fnd_api.g_exc_error;

Line 1161: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

1157: , p_api_version_number => 1.0
1158: , p_init_msg_lst => fnd_api.g_false
1159: );
1160:
1161: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1162: RAISE fnd_api.g_exc_error;
1163: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1164: RAISE fnd_api.g_exc_unexpected_error;
1165: END IF;

Line 1162: RAISE fnd_api.g_exc_error;

1158: , p_init_msg_lst => fnd_api.g_false
1159: );
1160:
1161: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1162: RAISE fnd_api.g_exc_error;
1163: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1164: RAISE fnd_api.g_exc_unexpected_error;
1165: END IF;
1166:

Line 1163: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

1159: );
1160:
1161: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1162: RAISE fnd_api.g_exc_error;
1163: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1164: RAISE fnd_api.g_exc_unexpected_error;
1165: END IF;
1166:
1167: IF (l_debug = 1) THEN

Line 1164: RAISE fnd_api.g_exc_unexpected_error;

1160:
1161: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1162: RAISE fnd_api.g_exc_error;
1163: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1164: RAISE fnd_api.g_exc_unexpected_error;
1165: END IF;
1166:
1167: IF (l_debug = 1) THEN
1168: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 1174: RAISE fnd_api.g_exc_error;

1170:
1171: IF (l_valid_status = 'N') THEN
1172: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_OSFM');
1173: fnd_msg_pub.ADD;
1174: RAISE fnd_api.g_exc_error;
1175: END IF;
1176:
1177: SELECT replenish_to_order_flag
1178: INTO l_replenish_to_order

Line 1191: RAISE fnd_api.g_exc_error;

1187: IF (l_replenish_to_order = 'Y') THEN
1188: fnd_message.set_name('INV', 'INV_RSV_REPLEN');
1189: fnd_message.set_token('SOURCE', 'OSFM');
1190: fnd_msg_pub.add;
1191: RAISE fnd_api.g_exc_error;
1192: END IF;
1193: ELSE
1194: IF (l_debug = 1) THEN
1195: debug_print('The wip entity type is not OSFM');

Line 1197: RAISE fnd_api.g_exc_error;

1193: ELSE
1194: IF (l_debug = 1) THEN
1195: debug_print('The wip entity type is not OSFM');
1196: END IF;
1197: RAISE fnd_api.g_exc_error;
1198: END IF;
1199: ELSE
1200: IF (l_debug = 1) THEN
1201: debug_print('The transation source type is not WIP');

Line 1203: RAISE fnd_api.g_exc_error;

1199: ELSE
1200: IF (l_debug = 1) THEN
1201: debug_print('The transation source type is not WIP');
1202: END IF;
1203: RAISE fnd_api.g_exc_error;
1204:
1205: END IF;
1206:
1207: x_return_status := l_return_status;

Line 1209: WHEN fnd_api.g_exc_error THEN

1205: END IF;
1206:
1207: x_return_status := l_return_status;
1208: EXCEPTION
1209: WHEN fnd_api.g_exc_error THEN
1210: x_return_status := fnd_api.g_ret_sts_error;
1211: --
1212: WHEN fnd_api.g_exc_unexpected_error THEN
1213: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1210: x_return_status := fnd_api.g_ret_sts_error;

1206:
1207: x_return_status := l_return_status;
1208: EXCEPTION
1209: WHEN fnd_api.g_exc_error THEN
1210: x_return_status := fnd_api.g_ret_sts_error;
1211: --
1212: WHEN fnd_api.g_exc_unexpected_error THEN
1213: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1214: --

Line 1212: WHEN fnd_api.g_exc_unexpected_error THEN

1208: EXCEPTION
1209: WHEN fnd_api.g_exc_error THEN
1210: x_return_status := fnd_api.g_ret_sts_error;
1211: --
1212: WHEN fnd_api.g_exc_unexpected_error THEN
1213: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1214: --
1215: WHEN OTHERS THEN
1216: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1213: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1209: WHEN fnd_api.g_exc_error THEN
1210: x_return_status := fnd_api.g_ret_sts_error;
1211: --
1212: WHEN fnd_api.g_exc_unexpected_error THEN
1213: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1214: --
1215: WHEN OTHERS THEN
1216: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1217: --

Line 1216: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1212: WHEN fnd_api.g_exc_unexpected_error THEN
1213: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1214: --
1215: WHEN OTHERS THEN
1216: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1217: --
1218: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1219: THEN
1220: fnd_msg_pub.add_exc_msg

Line 1248: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1244: , p_wip_entity_type IN NUMBER
1245: ) IS
1246:
1247: l_replenish_to_order VARCHAR2(1) := 'N';
1248: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1249: l_msg_count NUMBER;
1250: l_msg_data VARCHAR2(1000);
1251: l_valid_status VARCHAR2(1);
1252: l_debug NUMBER;

Line 1286: , p_init_msg_lst => fnd_api.g_false

1282: , p_supply_demand_line_detail => p_supply_source_line_detail
1283: , p_demand_ship_date => p_demand_ship_date
1284: , p_expected_receipt_date => p_supply_receipt_date
1285: , p_api_version_number => 1.0
1286: , p_init_msg_lst => fnd_api.g_false
1287: );
1288: */
1289:
1290: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

Line 1290: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

1286: , p_init_msg_lst => fnd_api.g_false
1287: );
1288: */
1289:
1290: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1291: RAISE fnd_api.g_exc_error;
1292: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1293: RAISE fnd_api.g_exc_unexpected_error;
1294: END IF;

Line 1291: RAISE fnd_api.g_exc_error;

1287: );
1288: */
1289:
1290: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1291: RAISE fnd_api.g_exc_error;
1292: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1293: RAISE fnd_api.g_exc_unexpected_error;
1294: END IF;
1295:

Line 1292: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

1288: */
1289:
1290: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1291: RAISE fnd_api.g_exc_error;
1292: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1293: RAISE fnd_api.g_exc_unexpected_error;
1294: END IF;
1295:
1296: IF (l_debug = 1) THEN

Line 1293: RAISE fnd_api.g_exc_unexpected_error;

1289:
1290: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1291: RAISE fnd_api.g_exc_error;
1292: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1293: RAISE fnd_api.g_exc_unexpected_error;
1294: END IF;
1295:
1296: IF (l_debug = 1) THEN
1297: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 1303: RAISE fnd_api.g_exc_error;

1299:
1300: IF (l_valid_status = 'N') THEN
1301: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_FPO');
1302: fnd_msg_pub.ADD;
1303: RAISE fnd_api.g_exc_error;
1304: END IF;
1305:
1306: SELECT replenish_to_order_flag
1307: INTO l_replenish_to_order

Line 1320: RAISE fnd_api.g_exc_error;

1316: IF (l_replenish_to_order = 'Y') THEN
1317: fnd_message.set_name('INV', 'INV_RSV_REPLEN');
1318: fnd_message.set_token('SOURCE', 'FPO');
1319: fnd_msg_pub.add;
1320: RAISE fnd_api.g_exc_error;
1321: END IF;
1322: ELSE
1323: IF (l_debug = 1) THEN
1324: debug_print('The wip entity type is not FPO');

Line 1326: RAISE fnd_api.g_exc_error;

1322: ELSE
1323: IF (l_debug = 1) THEN
1324: debug_print('The wip entity type is not FPO');
1325: END IF;
1326: RAISE fnd_api.g_exc_error;
1327: END IF;
1328: ELSE
1329: IF (l_debug = 1) THEN
1330: debug_print('The transation source type is not WIP');

Line 1332: RAISE fnd_api.g_exc_error;

1328: ELSE
1329: IF (l_debug = 1) THEN
1330: debug_print('The transation source type is not WIP');
1331: END IF;
1332: RAISE fnd_api.g_exc_error;
1333:
1334: END IF;
1335:
1336: x_return_status := l_return_status;

Line 1338: WHEN fnd_api.g_exc_error THEN

1334: END IF;
1335:
1336: x_return_status := l_return_status;
1337: EXCEPTION
1338: WHEN fnd_api.g_exc_error THEN
1339: x_return_status := fnd_api.g_ret_sts_error;
1340: --
1341: WHEN fnd_api.g_exc_unexpected_error THEN
1342: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1339: x_return_status := fnd_api.g_ret_sts_error;

1335:
1336: x_return_status := l_return_status;
1337: EXCEPTION
1338: WHEN fnd_api.g_exc_error THEN
1339: x_return_status := fnd_api.g_ret_sts_error;
1340: --
1341: WHEN fnd_api.g_exc_unexpected_error THEN
1342: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1343: --

Line 1341: WHEN fnd_api.g_exc_unexpected_error THEN

1337: EXCEPTION
1338: WHEN fnd_api.g_exc_error THEN
1339: x_return_status := fnd_api.g_ret_sts_error;
1340: --
1341: WHEN fnd_api.g_exc_unexpected_error THEN
1342: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1343: --
1344: WHEN OTHERS THEN
1345: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1342: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1338: WHEN fnd_api.g_exc_error THEN
1339: x_return_status := fnd_api.g_ret_sts_error;
1340: --
1341: WHEN fnd_api.g_exc_unexpected_error THEN
1342: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1343: --
1344: WHEN OTHERS THEN
1345: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1346: --

Line 1345: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1341: WHEN fnd_api.g_exc_unexpected_error THEN
1342: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1343: --
1344: WHEN OTHERS THEN
1345: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1346: --
1347: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1348: THEN
1349: fnd_msg_pub.add_exc_msg

Line 1377: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1373: , p_wip_entity_type IN NUMBER
1374: ) IS
1375:
1376: l_replenish_to_order VARCHAR2(1) := 'N';
1377: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1378: l_msg_count NUMBER;
1379: l_msg_data VARCHAR2(1000);
1380: l_valid_status VARCHAR2(1);
1381: l_debug NUMBER;

Line 1415: , p_init_msg_lst => fnd_api.g_false

1411: , p_supply_demand_line_detail => p_supply_source_line_detail
1412: , p_demand_ship_date => p_demand_ship_date
1413: , p_expected_receipt_date => p_supply_receipt_date
1414: , p_api_version_number => 1.0
1415: , p_init_msg_lst => fnd_api.g_false
1416: );
1417: */
1418:
1419: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

Line 1419: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

1415: , p_init_msg_lst => fnd_api.g_false
1416: );
1417: */
1418:
1419: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1420: RAISE fnd_api.g_exc_error;
1421: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1422: RAISE fnd_api.g_exc_unexpected_error;
1423: END IF;

Line 1420: RAISE fnd_api.g_exc_error;

1416: );
1417: */
1418:
1419: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1420: RAISE fnd_api.g_exc_error;
1421: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1422: RAISE fnd_api.g_exc_unexpected_error;
1423: END IF;
1424:

Line 1421: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

1417: */
1418:
1419: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1420: RAISE fnd_api.g_exc_error;
1421: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1422: RAISE fnd_api.g_exc_unexpected_error;
1423: END IF;
1424:
1425: IF (l_debug = 1) THEN

Line 1422: RAISE fnd_api.g_exc_unexpected_error;

1418:
1419: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1420: RAISE fnd_api.g_exc_error;
1421: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1422: RAISE fnd_api.g_exc_unexpected_error;
1423: END IF;
1424:
1425: IF (l_debug = 1) THEN
1426: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 1432: RAISE fnd_api.g_exc_error;

1428:
1429: IF (l_valid_status = 'N') THEN
1430: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_BATCH');
1431: fnd_msg_pub.ADD;
1432: RAISE fnd_api.g_exc_error;
1433: END IF;
1434:
1435: SELECT replenish_to_order_flag
1436: INTO l_replenish_to_order

Line 1448: RAISE fnd_api.g_exc_error;

1444: IF (l_replenish_to_order = 'Y') THEN
1445: fnd_message.set_name('INV', 'INV_RSV_REPLEN');
1446: fnd_message.set_token('SOURCE', 'Batch');
1447: fnd_msg_pub.add;
1448: RAISE fnd_api.g_exc_error;
1449: END IF;
1450: ELSE
1451: IF (l_debug = 1) THEN
1452: debug_print('The wip entity type is not Batch');

Line 1454: RAISE fnd_api.g_exc_error;

1450: ELSE
1451: IF (l_debug = 1) THEN
1452: debug_print('The wip entity type is not Batch');
1453: END IF;
1454: RAISE fnd_api.g_exc_error;
1455: END IF;
1456: ELSE
1457: IF (l_debug = 1) THEN
1458: debug_print('The transation source type is not WIP');

Line 1460: RAISE fnd_api.g_exc_error;

1456: ELSE
1457: IF (l_debug = 1) THEN
1458: debug_print('The transation source type is not WIP');
1459: END IF;
1460: RAISE fnd_api.g_exc_error;
1461:
1462: END IF;
1463:
1464: x_return_status := l_return_status;

Line 1466: WHEN fnd_api.g_exc_error THEN

1462: END IF;
1463:
1464: x_return_status := l_return_status;
1465: EXCEPTION
1466: WHEN fnd_api.g_exc_error THEN
1467: x_return_status := fnd_api.g_ret_sts_error;
1468: --
1469: WHEN fnd_api.g_exc_unexpected_error THEN
1470: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1467: x_return_status := fnd_api.g_ret_sts_error;

1463:
1464: x_return_status := l_return_status;
1465: EXCEPTION
1466: WHEN fnd_api.g_exc_error THEN
1467: x_return_status := fnd_api.g_ret_sts_error;
1468: --
1469: WHEN fnd_api.g_exc_unexpected_error THEN
1470: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1471: --

Line 1469: WHEN fnd_api.g_exc_unexpected_error THEN

1465: EXCEPTION
1466: WHEN fnd_api.g_exc_error THEN
1467: x_return_status := fnd_api.g_ret_sts_error;
1468: --
1469: WHEN fnd_api.g_exc_unexpected_error THEN
1470: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1471: --
1472: WHEN OTHERS THEN
1473: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1470: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1466: WHEN fnd_api.g_exc_error THEN
1467: x_return_status := fnd_api.g_ret_sts_error;
1468: --
1469: WHEN fnd_api.g_exc_unexpected_error THEN
1470: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1471: --
1472: WHEN OTHERS THEN
1473: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1474: --

Line 1473: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1469: WHEN fnd_api.g_exc_unexpected_error THEN
1470: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1471: --
1472: WHEN OTHERS THEN
1473: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1474: --
1475: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1476: THEN
1477: fnd_msg_pub.add_exc_msg

Line 1507: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1503: , p_wip_entity_type IN NUMBER
1504: ) IS
1505:
1506: l_replenish_to_order VARCHAR2(1) := 'N';
1507: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1508: l_msg_count NUMBER;
1509: l_msg_data VARCHAR2(1000);
1510: l_valid_status VARCHAR2(1);
1511: l_debug NUMBER;

Line 1543: , p_init_msg_lst => fnd_api.g_false

1539: , p_supply_demand_line_detail => NULL
1540: , p_demand_ship_date => p_demand_ship_date
1541: , p_expected_receipt_date => p_supply_receipt_date
1542: , p_api_version_number => 1.0
1543: , p_init_msg_lst => fnd_api.g_false
1544: );
1545:
1546:
1547: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

Line 1547: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

1543: , p_init_msg_lst => fnd_api.g_false
1544: );
1545:
1546:
1547: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1548: RAISE fnd_api.g_exc_error;
1549: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1550: RAISE fnd_api.g_exc_unexpected_error;
1551: END IF;

Line 1548: RAISE fnd_api.g_exc_error;

1544: );
1545:
1546:
1547: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1548: RAISE fnd_api.g_exc_error;
1549: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1550: RAISE fnd_api.g_exc_unexpected_error;
1551: END IF;
1552:

Line 1549: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

1545:
1546:
1547: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1548: RAISE fnd_api.g_exc_error;
1549: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1550: RAISE fnd_api.g_exc_unexpected_error;
1551: END IF;
1552:
1553: IF (l_debug = 1) THEN

Line 1550: RAISE fnd_api.g_exc_unexpected_error;

1546:
1547: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1548: RAISE fnd_api.g_exc_error;
1549: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1550: RAISE fnd_api.g_exc_unexpected_error;
1551: END IF;
1552:
1553: IF (l_debug = 1) THEN
1554: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 1560: RAISE fnd_api.g_exc_error;

1556:
1557: IF (l_valid_status = 'N') THEN
1558: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY_CMRO');
1559: fnd_msg_pub.ADD;
1560: RAISE fnd_api.g_exc_error;
1561: END IF;
1562:
1563: ELSE
1564: IF (l_debug = 1) THEN

Line 1567: RAISE fnd_api.g_exc_error;

1563: ELSE
1564: IF (l_debug = 1) THEN
1565: debug_print('The wip entity type is not CMRO');
1566: END IF;
1567: RAISE fnd_api.g_exc_error;
1568: END IF;
1569: ELSE
1570: IF (l_debug = 1) THEN
1571: debug_print('The transation source type is not WIP');

Line 1573: RAISE fnd_api.g_exc_error;

1569: ELSE
1570: IF (l_debug = 1) THEN
1571: debug_print('The transation source type is not WIP');
1572: END IF;
1573: RAISE fnd_api.g_exc_error;
1574:
1575: END IF;
1576:
1577: x_return_status := l_return_status;

Line 1579: WHEN fnd_api.g_exc_error THEN

1575: END IF;
1576:
1577: x_return_status := l_return_status;
1578: EXCEPTION
1579: WHEN fnd_api.g_exc_error THEN
1580: x_return_status := fnd_api.g_ret_sts_error;
1581: --
1582: WHEN fnd_api.g_exc_unexpected_error THEN
1583: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1580: x_return_status := fnd_api.g_ret_sts_error;

1576:
1577: x_return_status := l_return_status;
1578: EXCEPTION
1579: WHEN fnd_api.g_exc_error THEN
1580: x_return_status := fnd_api.g_ret_sts_error;
1581: --
1582: WHEN fnd_api.g_exc_unexpected_error THEN
1583: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1584: --

Line 1582: WHEN fnd_api.g_exc_unexpected_error THEN

1578: EXCEPTION
1579: WHEN fnd_api.g_exc_error THEN
1580: x_return_status := fnd_api.g_ret_sts_error;
1581: --
1582: WHEN fnd_api.g_exc_unexpected_error THEN
1583: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1584: --
1585: WHEN OTHERS THEN
1586: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1583: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1579: WHEN fnd_api.g_exc_error THEN
1580: x_return_status := fnd_api.g_ret_sts_error;
1581: --
1582: WHEN fnd_api.g_exc_unexpected_error THEN
1583: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1584: --
1585: WHEN OTHERS THEN
1586: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1587: --

Line 1586: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1582: WHEN fnd_api.g_exc_unexpected_error THEN
1583: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1584: --
1585: WHEN OTHERS THEN
1586: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1587: --
1588: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1589: THEN
1590: fnd_msg_pub.add_exc_msg

Line 1614: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1610: ) IS
1611:
1612: l_dropship_count NUMBER := 0;
1613: l_debug NUMBER;
1614: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1615:
1616: BEGIN
1617:
1618: IF (g_debug IS NULL) THEN

Line 1643: RAISE fnd_api.g_exc_error;

1639:
1640: IF (l_dropship_count >= 1) THEN
1641: fnd_message.set_name('INV', 'INV_RSV_DS_SO');
1642: fnd_msg_pub.add;
1643: RAISE fnd_api.g_exc_error;
1644: END IF;
1645:
1646: ELSE
1647: IF (l_debug = 1) THEN

Line 1650: RAISE fnd_api.g_exc_error;

1646: ELSE
1647: IF (l_debug = 1) THEN
1648: debug_print('The transation source type is not sales order');
1649: END IF;
1650: RAISE fnd_api.g_exc_error;
1651:
1652: END IF;
1653: IF (l_debug = 1) THEN
1654: debug_print('After drop ship check ' || p_demand_source_type_id);

Line 1659: WHEN fnd_api.g_exc_error THEN

1655: END IF;
1656: x_return_status := l_return_status;
1657:
1658: EXCEPTION
1659: WHEN fnd_api.g_exc_error THEN
1660: x_return_status := fnd_api.g_ret_sts_error;
1661: --
1662: WHEN fnd_api.g_exc_unexpected_error THEN
1663: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1660: x_return_status := fnd_api.g_ret_sts_error;

1656: x_return_status := l_return_status;
1657:
1658: EXCEPTION
1659: WHEN fnd_api.g_exc_error THEN
1660: x_return_status := fnd_api.g_ret_sts_error;
1661: --
1662: WHEN fnd_api.g_exc_unexpected_error THEN
1663: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1664: --

Line 1662: WHEN fnd_api.g_exc_unexpected_error THEN

1658: EXCEPTION
1659: WHEN fnd_api.g_exc_error THEN
1660: x_return_status := fnd_api.g_ret_sts_error;
1661: --
1662: WHEN fnd_api.g_exc_unexpected_error THEN
1663: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1664: --
1665: WHEN OTHERS THEN
1666: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1663: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1659: WHEN fnd_api.g_exc_error THEN
1660: x_return_status := fnd_api.g_ret_sts_error;
1661: --
1662: WHEN fnd_api.g_exc_unexpected_error THEN
1663: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1664: --
1665: WHEN OTHERS THEN
1666: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1667: --

Line 1666: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1662: WHEN fnd_api.g_exc_unexpected_error THEN
1663: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1664: --
1665: WHEN OTHERS THEN
1666: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1667: --
1668: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1669: THEN
1670: fnd_msg_pub.add_exc_msg

Line 1697: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1693: , p_demand_source_line_detail IN NUMBER
1694: , p_wip_entity_type IN NUMBER
1695: ) IS
1696:
1697: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1698: l_msg_count NUMBER;
1699: l_msg_data VARCHAR2(1000);
1700: l_valid_status VARCHAR2(1);
1701: l_debug NUMBER;

Line 1738: , p_init_msg_lst => fnd_api.g_false

1734: , p_supply_demand_line_detail => p_demand_source_line_detail
1735: , p_demand_ship_date => p_demand_ship_date
1736: , p_expected_receipt_date => p_supply_receipt_date
1737: , p_api_version_number => 1.0
1738: , p_init_msg_lst => fnd_api.g_false
1739: );
1740:
1741: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1742: RAISE fnd_api.g_exc_error;

Line 1741: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

1737: , p_api_version_number => 1.0
1738: , p_init_msg_lst => fnd_api.g_false
1739: );
1740:
1741: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1742: RAISE fnd_api.g_exc_error;
1743: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1744: RAISE fnd_api.g_exc_unexpected_error;
1745: END IF;

Line 1742: RAISE fnd_api.g_exc_error;

1738: , p_init_msg_lst => fnd_api.g_false
1739: );
1740:
1741: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1742: RAISE fnd_api.g_exc_error;
1743: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1744: RAISE fnd_api.g_exc_unexpected_error;
1745: END IF;
1746:

Line 1743: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

1739: );
1740:
1741: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1742: RAISE fnd_api.g_exc_error;
1743: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1744: RAISE fnd_api.g_exc_unexpected_error;
1745: END IF;
1746:
1747: IF (l_debug = 1) THEN

Line 1744: RAISE fnd_api.g_exc_unexpected_error;

1740:
1741: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1742: RAISE fnd_api.g_exc_error;
1743: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1744: RAISE fnd_api.g_exc_unexpected_error;
1745: END IF;
1746:
1747: IF (l_debug = 1) THEN
1748: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 1754: RAISE fnd_api.g_exc_error;

1750:
1751: IF (l_valid_status = 'N') THEN
1752: fnd_message.set_name('INV', 'INV_RSV_INVALID_DEMAND_CMRO');
1753: fnd_msg_pub.ADD;
1754: RAISE fnd_api.g_exc_error;
1755: END IF;
1756: ELSE
1757: -- return error since this is not wip demand source or not CMRO entity type
1758: fnd_message.set_name('INV', 'INV_INVALID_DEMAND_SOURCE');

Line 1760: RAISE fnd_api.g_exc_error;

1756: ELSE
1757: -- return error since this is not wip demand source or not CMRO entity type
1758: fnd_message.set_name('INV', 'INV_INVALID_DEMAND_SOURCE');
1759: fnd_msg_pub.ADD;
1760: RAISE fnd_api.g_exc_error;
1761: END IF;
1762:
1763: x_return_status := l_return_status;
1764:

Line 1766: WHEN fnd_api.g_exc_error THEN

1762:
1763: x_return_status := l_return_status;
1764:
1765: EXCEPTION
1766: WHEN fnd_api.g_exc_error THEN
1767: x_return_status := fnd_api.g_ret_sts_error;
1768: --
1769: WHEN fnd_api.g_exc_unexpected_error THEN
1770: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1767: x_return_status := fnd_api.g_ret_sts_error;

1763: x_return_status := l_return_status;
1764:
1765: EXCEPTION
1766: WHEN fnd_api.g_exc_error THEN
1767: x_return_status := fnd_api.g_ret_sts_error;
1768: --
1769: WHEN fnd_api.g_exc_unexpected_error THEN
1770: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1771: --

Line 1769: WHEN fnd_api.g_exc_unexpected_error THEN

1765: EXCEPTION
1766: WHEN fnd_api.g_exc_error THEN
1767: x_return_status := fnd_api.g_ret_sts_error;
1768: --
1769: WHEN fnd_api.g_exc_unexpected_error THEN
1770: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1771: --
1772: WHEN OTHERS THEN
1773: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1770: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1766: WHEN fnd_api.g_exc_error THEN
1767: x_return_status := fnd_api.g_ret_sts_error;
1768: --
1769: WHEN fnd_api.g_exc_unexpected_error THEN
1770: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1771: --
1772: WHEN OTHERS THEN
1773: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1774: --

Line 1773: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1769: WHEN fnd_api.g_exc_unexpected_error THEN
1770: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1771: --
1772: WHEN OTHERS THEN
1773: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1774: --
1775: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1776: THEN
1777: fnd_msg_pub.add_exc_msg

Line 1804: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1800: , p_demand_source_line_detail IN NUMBER
1801: , p_wip_entity_type IN NUMBER
1802: ) IS
1803:
1804: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1805: l_msg_count NUMBER;
1806: l_msg_data VARCHAR2(1000);
1807: l_valid_status VARCHAR2(1);
1808: l_debug NUMBER;

Line 1845: , p_init_msg_lst => fnd_api.g_false

1841: , p_supply_demand_line_detail => p_demand_source_line_detail
1842: , p_demand_ship_date => p_demand_ship_date
1843: , p_expected_receipt_date => p_supply_receipt_date
1844: , p_api_version_number => 1.0
1845: , p_init_msg_lst => fnd_api.g_false
1846: );
1847: */
1848:
1849: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

Line 1849: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

1845: , p_init_msg_lst => fnd_api.g_false
1846: );
1847: */
1848:
1849: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1850: RAISE fnd_api.g_exc_error;
1851: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1852: RAISE fnd_api.g_exc_unexpected_error;
1853: END IF;

Line 1850: RAISE fnd_api.g_exc_error;

1846: );
1847: */
1848:
1849: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1850: RAISE fnd_api.g_exc_error;
1851: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1852: RAISE fnd_api.g_exc_unexpected_error;
1853: END IF;
1854:

Line 1851: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

1847: */
1848:
1849: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1850: RAISE fnd_api.g_exc_error;
1851: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1852: RAISE fnd_api.g_exc_unexpected_error;
1853: END IF;
1854:
1855: IF (l_debug = 1) THEN

Line 1852: RAISE fnd_api.g_exc_unexpected_error;

1848:
1849: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1850: RAISE fnd_api.g_exc_error;
1851: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1852: RAISE fnd_api.g_exc_unexpected_error;
1853: END IF;
1854:
1855: IF (l_debug = 1) THEN
1856: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 1862: RAISE fnd_api.g_exc_error;

1858:
1859: IF (l_valid_status = 'N') THEN
1860: fnd_message.set_name('INV', 'INV_RSV_INVALID_DEMAND_FPO');
1861: fnd_msg_pub.ADD;
1862: RAISE fnd_api.g_exc_error;
1863: END IF;
1864: ELSE
1865: -- return error since this is not wip demand source or not FPO entity type
1866: fnd_message.set_name('INV', 'INV_INVALID_DEMAND_SOURCE');

Line 1868: RAISE fnd_api.g_exc_error;

1864: ELSE
1865: -- return error since this is not wip demand source or not FPO entity type
1866: fnd_message.set_name('INV', 'INV_INVALID_DEMAND_SOURCE');
1867: fnd_msg_pub.ADD;
1868: RAISE fnd_api.g_exc_error;
1869: END IF;
1870:
1871: x_return_status := l_return_status;
1872:

Line 1874: WHEN fnd_api.g_exc_error THEN

1870:
1871: x_return_status := l_return_status;
1872:
1873: EXCEPTION
1874: WHEN fnd_api.g_exc_error THEN
1875: x_return_status := fnd_api.g_ret_sts_error;
1876: --
1877: WHEN fnd_api.g_exc_unexpected_error THEN
1878: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1875: x_return_status := fnd_api.g_ret_sts_error;

1871: x_return_status := l_return_status;
1872:
1873: EXCEPTION
1874: WHEN fnd_api.g_exc_error THEN
1875: x_return_status := fnd_api.g_ret_sts_error;
1876: --
1877: WHEN fnd_api.g_exc_unexpected_error THEN
1878: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1879: --

Line 1877: WHEN fnd_api.g_exc_unexpected_error THEN

1873: EXCEPTION
1874: WHEN fnd_api.g_exc_error THEN
1875: x_return_status := fnd_api.g_ret_sts_error;
1876: --
1877: WHEN fnd_api.g_exc_unexpected_error THEN
1878: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1879: --
1880: WHEN OTHERS THEN
1881: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1878: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1874: WHEN fnd_api.g_exc_error THEN
1875: x_return_status := fnd_api.g_ret_sts_error;
1876: --
1877: WHEN fnd_api.g_exc_unexpected_error THEN
1878: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1879: --
1880: WHEN OTHERS THEN
1881: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1882: --

Line 1881: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1877: WHEN fnd_api.g_exc_unexpected_error THEN
1878: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1879: --
1880: WHEN OTHERS THEN
1881: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1882: --
1883: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1884: THEN
1885: fnd_msg_pub.add_exc_msg

Line 1912: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

1908: , p_demand_source_line_detail IN NUMBER
1909: , p_wip_entity_type IN NUMBER
1910: ) IS
1911:
1912: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
1913: l_msg_count NUMBER;
1914: l_msg_data VARCHAR2(1000);
1915: l_valid_status VARCHAR2(1);
1916: l_debug NUMBER;

Line 1953: , p_init_msg_lst => fnd_api.g_false

1949: , p_supply_demand_line_detail => p_demand_source_line_detail
1950: , p_demand_ship_date => p_demand_ship_date
1951: , p_expected_receipt_date => p_supply_receipt_date
1952: , p_api_version_number => 1.0
1953: , p_init_msg_lst => fnd_api.g_false
1954: );
1955: */
1956:
1957: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

Line 1957: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

1953: , p_init_msg_lst => fnd_api.g_false
1954: );
1955: */
1956:
1957: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1958: RAISE fnd_api.g_exc_error;
1959: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1960: RAISE fnd_api.g_exc_unexpected_error;
1961: END IF;

Line 1958: RAISE fnd_api.g_exc_error;

1954: );
1955: */
1956:
1957: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1958: RAISE fnd_api.g_exc_error;
1959: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1960: RAISE fnd_api.g_exc_unexpected_error;
1961: END IF;
1962:

Line 1959: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

1955: */
1956:
1957: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1958: RAISE fnd_api.g_exc_error;
1959: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1960: RAISE fnd_api.g_exc_unexpected_error;
1961: END IF;
1962:
1963: IF (l_debug = 1) THEN

Line 1960: RAISE fnd_api.g_exc_unexpected_error;

1956:
1957: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1958: RAISE fnd_api.g_exc_error;
1959: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
1960: RAISE fnd_api.g_exc_unexpected_error;
1961: END IF;
1962:
1963: IF (l_debug = 1) THEN
1964: debug_print('validate supply demand returns valid status: ' || l_valid_status);

Line 1970: RAISE fnd_api.g_exc_error;

1966:
1967: IF (l_valid_status = 'N') THEN
1968: fnd_message.set_name('INV', 'INV_RSV_INVALID_DEMAND_BATCH');
1969: fnd_msg_pub.ADD;
1970: RAISE fnd_api.g_exc_error;
1971: END IF;
1972: ELSE
1973: -- return error since this is not wip demand source or not OPM Batch entity type
1974: fnd_message.set_name('INV', 'INV_INVALID_DEMAND_SOURCE');

Line 1976: RAISE fnd_api.g_exc_error;

1972: ELSE
1973: -- return error since this is not wip demand source or not OPM Batch entity type
1974: fnd_message.set_name('INV', 'INV_INVALID_DEMAND_SOURCE');
1975: fnd_msg_pub.ADD;
1976: RAISE fnd_api.g_exc_error;
1977: END IF;
1978:
1979: x_return_status := l_return_status;
1980:

Line 1982: WHEN fnd_api.g_exc_error THEN

1978:
1979: x_return_status := l_return_status;
1980:
1981: EXCEPTION
1982: WHEN fnd_api.g_exc_error THEN
1983: x_return_status := fnd_api.g_ret_sts_error;
1984: --
1985: WHEN fnd_api.g_exc_unexpected_error THEN
1986: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1983: x_return_status := fnd_api.g_ret_sts_error;

1979: x_return_status := l_return_status;
1980:
1981: EXCEPTION
1982: WHEN fnd_api.g_exc_error THEN
1983: x_return_status := fnd_api.g_ret_sts_error;
1984: --
1985: WHEN fnd_api.g_exc_unexpected_error THEN
1986: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1987: --

Line 1985: WHEN fnd_api.g_exc_unexpected_error THEN

1981: EXCEPTION
1982: WHEN fnd_api.g_exc_error THEN
1983: x_return_status := fnd_api.g_ret_sts_error;
1984: --
1985: WHEN fnd_api.g_exc_unexpected_error THEN
1986: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1987: --
1988: WHEN OTHERS THEN
1989: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 1986: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1982: WHEN fnd_api.g_exc_error THEN
1983: x_return_status := fnd_api.g_ret_sts_error;
1984: --
1985: WHEN fnd_api.g_exc_unexpected_error THEN
1986: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1987: --
1988: WHEN OTHERS THEN
1989: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1990: --

Line 1989: x_return_status := fnd_api.g_ret_sts_unexp_error ;

1985: WHEN fnd_api.g_exc_unexpected_error THEN
1986: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1987: --
1988: WHEN OTHERS THEN
1989: x_return_status := fnd_api.g_ret_sts_unexp_error ;
1990: --
1991: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
1992: THEN
1993: fnd_msg_pub.add_exc_msg

Line 2056: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

2052: , p_item_cache_index IN INTEGER
2053: , p_org_cache_index IN INTEGER
2054: , x_sub_cache_index OUT NOCOPY INTEGER
2055: ) IS
2056: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
2057: l_resultant_locator_control NUMBER := NULL;
2058: l_loop_index NUMBER := NULL;
2059: l_sub_cache_index NUMBER := NULL;
2060: l_rec inv_reservation_global.sub_record;

Line 2095: RAISE fnd_api.g_exc_error;

2091: inv_reservation_global.g_serial_control_dynamic_inv)
2092: AND p_serial_array.COUNT >0 THEN
2093: fnd_message.set_name('INV', 'INV_EXTRA_SERIAL');
2094: fnd_msg_pub.add;
2095: RAISE fnd_api.g_exc_error;
2096: END IF;
2097: --
2098: IF (l_debug = 1) THEN
2099: debug_print('After item cache: ' || l_return_status);

Line 2110: RAISE fnd_api.g_exc_error;

2106: inv_reservation_global.g_lot_control_no
2107: AND p_lot_number IS NOT NULL THEN
2108: fnd_message.set_name('INV', 'INV_NO_LOT_CONTROL');
2109: fnd_msg_pub.add;
2110: RAISE fnd_api.g_exc_error;
2111: END IF;
2112: IF (l_debug = 1) THEN
2113: debug_print('After lot cache: ' || l_return_status);
2114: END IF;

Line 2125: RAISE fnd_api.g_exc_error;

2121: inv_reservation_global.g_revision_control_no
2122: AND p_revision IS NOT NULL THEN
2123: fnd_message.set_name('INV', 'INV_NO_REVISION_CONTROL');
2124: fnd_msg_pub.add;
2125: RAISE fnd_api.g_exc_error;
2126: END IF;
2127: --
2128: IF (l_debug = 1) THEN
2129: debug_print('After rev cache: ' || l_return_status);

Line 2144: RAISE fnd_api.g_exc_error;

2140: p_locator_id IS NOT NULL
2141: ) THEN
2142: fnd_message.set_name('INV', 'INV_MISSING_REV');
2143: fnd_msg_pub.add;
2144: RAISE fnd_api.g_exc_error;
2145: END IF;
2146:
2147: IF (l_debug = 1) THEN
2148: debug_print('After rev/sub/loc check cache: ' || l_return_status);

Line 2171: RAISE fnd_api.g_exc_error;

2167: END IF;
2168: ELSE
2169: fnd_message.set_name('INV', 'INV_MISSING_LOT');
2170: fnd_msg_pub.add;
2171: RAISE fnd_api.g_exc_error;
2172: END IF;
2173:
2174: END IF;
2175:

Line 2193: RAISE fnd_api.g_exc_error;

2189: AND p_revision IS NULL
2190: AND p_lot_number IS NOT NULL THEN
2191: fnd_message.set_name('INV', 'INV_MISSING_REV');
2192: fnd_msg_pub.add;
2193: RAISE fnd_api.g_exc_error;
2194: END IF;
2195:
2196: IF (l_debug = 1) THEN
2197: debug_print('After lot/rev check cache: ' || l_return_status);

Line 2215: IF l_return_status = fnd_api.g_ret_sts_error THEN

2211: IF (l_debug = 1) THEN
2212: debug_print('After search sub cache: ' || l_return_status);
2213: END IF;
2214: --
2215: IF l_return_status = fnd_api.g_ret_sts_error THEN
2216: RAISE fnd_api.g_exc_error;
2217: END IF ;
2218: --
2219: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 2216: RAISE fnd_api.g_exc_error;

2212: debug_print('After search sub cache: ' || l_return_status);
2213: END IF;
2214: --
2215: IF l_return_status = fnd_api.g_ret_sts_error THEN
2216: RAISE fnd_api.g_exc_error;
2217: END IF ;
2218: --
2219: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2220: RAISE fnd_api.g_exc_unexpected_error;

Line 2219: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

2215: IF l_return_status = fnd_api.g_ret_sts_error THEN
2216: RAISE fnd_api.g_exc_error;
2217: END IF ;
2218: --
2219: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2220: RAISE fnd_api.g_exc_unexpected_error;
2221: END IF;
2222: --
2223: -- if the sub is not in the cache, load it into the cache

Line 2220: RAISE fnd_api.g_exc_unexpected_error;

2216: RAISE fnd_api.g_exc_error;
2217: END IF ;
2218: --
2219: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2220: RAISE fnd_api.g_exc_unexpected_error;
2221: END IF;
2222: --
2223: -- if the sub is not in the cache, load it into the cache
2224: IF l_sub_cache_index IS NULL THEN

Line 2242: RAISE fnd_api.g_exc_error;

2238: EXCEPTION
2239: WHEN NO_DATA_FOUND then
2240: fnd_message.set_name('INV','INVALID_SUB');
2241: fnd_msg_pub.add;
2242: RAISE fnd_api.g_exc_error;
2243: END; */
2244: -- Modified to call common API
2245: l_rec.secondary_inventory_name :=p_subinventory_code;
2246: IF INV_Validate.subinventory

Line 2253: RAISE fnd_api.g_exc_error;

2249: p_org => inv_reservation_global.g_organization_record_cache(p_org_cache_index)
2250: )=INV_Validate.F THEN
2251: fnd_message.set_name('INV','INVALID_SUB');
2252: fnd_msg_pub.add;
2253: RAISE fnd_api.g_exc_error;
2254: END IF;
2255:
2256:
2257: --Bug 2334171 Check whether the sub is reservable

Line 2269: RAISE fnd_api.g_exc_error;

2265: THEN /* non reservable Subinventory */
2266: fnd_message.set_name('INV','INV-SUBINV NOT RESERVABLE');
2267: fnd_message.set_token('SUBINV', l_rec.secondary_inventory_name);
2268: fnd_msg_pub.add;
2269: RAISE fnd_api.g_exc_error;
2270: END IF;
2271: END IF;
2272: -- End of changes for Bug 6870416
2273:

Line 2281: IF l_return_status = fnd_api.g_ret_sts_error THEN

2277: , p_sub_record => l_rec
2278: , x_index => l_sub_cache_index
2279: );
2280: --
2281: IF l_return_status = fnd_api.g_ret_sts_error THEN
2282: RAISE fnd_api.g_exc_error;
2283: END IF ;
2284: --
2285: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 2282: RAISE fnd_api.g_exc_error;

2278: , x_index => l_sub_cache_index
2279: );
2280: --
2281: IF l_return_status = fnd_api.g_ret_sts_error THEN
2282: RAISE fnd_api.g_exc_error;
2283: END IF ;
2284: --
2285: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2286: RAISE fnd_api.g_exc_unexpected_error;

Line 2285: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

2281: IF l_return_status = fnd_api.g_ret_sts_error THEN
2282: RAISE fnd_api.g_exc_error;
2283: END IF ;
2284: --
2285: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2286: RAISE fnd_api.g_exc_unexpected_error;
2287: END IF;
2288: ELSE
2289: l_rec := inv_reservation_global.g_sub_record_cache(l_sub_cache_index);

Line 2286: RAISE fnd_api.g_exc_unexpected_error;

2282: RAISE fnd_api.g_exc_error;
2283: END IF ;
2284: --
2285: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2286: RAISE fnd_api.g_exc_unexpected_error;
2287: END IF;
2288: ELSE
2289: l_rec := inv_reservation_global.g_sub_record_cache(l_sub_cache_index);
2290: END IF;

Line 2313: RAISE fnd_api.g_exc_error;

2309: IF (l_resultant_locator_control = 1
2310: AND p_locator_id IS NOT NULL AND p_locator_id > 0) THEN
2311: fnd_message.set_name('INV', 'INV_NO_LOCATOR_CONTROL');
2312: fnd_msg_pub.add;
2313: RAISE fnd_api.g_exc_error;
2314: END IF;
2315: --
2316: ELSIF p_locator_id IS NOT NULL THEN
2317: -- if the sub is null, but the locator id is not null

Line 2321: RAISE fnd_api.g_exc_error;

2317: -- if the sub is null, but the locator id is not null
2318: -- raise the error
2319: fnd_message.set_name('INV', 'INV_NO_LOCATOR_CONTROL');
2320: fnd_msg_pub.add;
2321: RAISE fnd_api.g_exc_error;
2322: END IF;
2323: --
2324: -- Now we have validated that values are there.
2325: -- Now validate that values are correct

Line 2338: RAISE fnd_api.g_exc_error;

2334: EXCEPTION
2335: WHEN NO_DATA_FOUND THEN
2336: fnd_message.set_name('INV','INVALID_REVISION');
2337: fnd_msg_pub.add;
2338: RAISE fnd_api.g_exc_error;
2339: END;*/
2340: IF INV_Validate.revision
2341: (
2342: p_revision => p_revision,

Line 2349: RAISE fnd_api.g_exc_error;

2345: p_item => inv_reservation_global.g_item_record_cache(p_item_cache_index) )=INV_Validate.F THEN
2346:
2347: fnd_message.set_name('INV','INVALID_REVISION');
2348: fnd_msg_pub.add;
2349: RAISE fnd_api.g_exc_error;
2350: END IF;
2351:
2352: END IF;
2353: --

Line 2367: RAISE fnd_api.g_exc_error;

2363: IF l_lot_expiration_date IS NOT NULL
2364: AND l_lot_expiration_date < Sysdate THEN
2365: fnd_message.set_name('INV', 'INV_LOT_EXPIRED');
2366: fnd_msg_pub.add;
2367: RAISE fnd_api.g_exc_error;
2368: END IF;
2369: --
2370: EXCEPTION
2371: WHEN NO_DATA_FOUND then

Line 2374: RAISE fnd_api.g_exc_error;

2370: EXCEPTION
2371: WHEN NO_DATA_FOUND then
2372: fnd_message.set_name('INV','INV_INVALID_LOT');
2373: fnd_msg_pub.add;
2374: RAISE fnd_api.g_exc_error;
2375: END;
2376: END IF;
2377: --
2378: IF p_subinventory_code IS NOT NULL THEN

Line 2393: RAISE fnd_api.g_exc_error;

2389: EXCEPTION
2390: WHEN no_data_found THEN
2391: fnd_message.set_name('INV', 'INVALID_SUB');
2392: fnd_msg_pub.add;
2393: RAISE fnd_api.g_exc_error;
2394:
2395: END;*/
2396:
2397:

Line 2414: RAISE fnd_api.g_exc_error;

2410: EXCEPTION
2411: WHEN NO_DATA_FOUND THEN
2412: fnd_message.set_name('INV','INVALID_SUB');
2413: fnd_msg_pub.add;
2414: RAISE fnd_api.g_exc_error;
2415: END ;
2416: ELSIF inv_reservation_global.g_item_record_cache
2417: (p_item_cache_index)
2418: .restrict_subinventories_code = 2 THEN

Line 2430: RAISE fnd_api.g_exc_error;

2426: EXCEPTION
2427: WHEN NO_DATA_FOUND THEN
2428: fnd_message.SET_NAME('INV','INVALID_SUB');
2429: fnd_msg_pub.add;
2430: RAISE fnd_api.g_exc_error;
2431: END ;
2432: END IF;
2433: --
2434: -- now if locator id is not null then validate its value

Line 2461: RAISE fnd_api.g_exc_error; */

2457: EXCEPTION
2458: WHEN NO_DATA_FOUND THEN
2459: fnd_message.set_name('INV','INV_LOCATOR_NOT_AVAILABLE');
2460: fnd_msg_pub.add;
2461: RAISE fnd_api.g_exc_error; */
2462:
2463:
2464: IF INV_Validate.validateLocator(
2465: p_locator => l_rec_loc,

Line 2473: RAISE fnd_api.g_exc_error;

2469: p_item => inv_reservation_global.g_item_record_cache(p_item_cache_index)
2470: )=INV_Validate.F THEN
2471: fnd_message.set_name('INV','INV_LOCATOR_NOT_AVAILABLE');
2472: fnd_msg_pub.add;
2473: RAISE fnd_api.g_exc_error;
2474: END IF;
2475: END;
2476: ELSIF inv_reservation_global.g_item_record_cache
2477: (p_item_cache_index)

Line 2493: RAISE fnd_api.g_exc_error;

2489: EXCEPTION
2490: WHEN NO_DATA_FOUND THEN
2491: fnd_message.set_name('INV','INV_LOCATOR_NOT_AVAILABLE');
2492: fnd_msg_pub.add;
2493: RAISE fnd_api.g_exc_error;
2494: END;*/
2495:
2496: -- Modified for common API
2497:

Line 2505: RAISE fnd_api.g_exc_error;

2501: (p_org_cache_index),
2502: p_sub => l_rec)=INV_Validate.F THEN
2503: fnd_message.set_name('INV','INV_LOCATOR_NOT_AVAILABLE');
2504: fnd_msg_pub.add;
2505: RAISE fnd_api.g_exc_error;
2506: END IF;
2507: END IF;
2508: END IF; -- if p_locator_id is not null
2509: END IF; -- if p_subinventory_code is not null

Line 2552: -- RAISE fnd_api.g_exc_error;

2548: -- fnd_message.set_name('INV','INVALID_SERIAL_NUMBER');
2549: -- fnd_message.set_token('NUMBER',p_serial_array(l_loop_index).serial_number,FALSE);
2550: /*** {{ R12 Enhanced ----reservations code changes ***/
2551: -- fnd_msg_pub.add;
2552: -- RAISE fnd_api.g_exc_error;
2553: -- END IF;
2554: -- EXIT WHEN l_loop_index = p_serial_array.last ;
2555: -- l_loop_index := p_serial_array.next(l_loop_index);
2556: -- END LOOP;

Line 2562: -- RAISE fnd_api.g_exc_error;

2558: -- WHEN NO_DATA_FOUND THEN
2559: -- fnd_message.set_name('INV','INVALID_SERIAL_NUMBER');
2560: -- fnd_message.set_token('NUMBER',p_serial_array(l_loop_index),FALSE);
2561: -- fnd_msg_pub.add;
2562: -- RAISE fnd_api.g_exc_error;
2563: -- */
2564: -- END;
2565: -- END IF;
2566: /*** End R12 }} ***/

Line 2588: RAISE fnd_api.g_exc_error;

2584: END IF;
2585: ELSE
2586: fnd_message.set_name('INV', 'INV_INDIVISIBLE_LOT_REQUIRED'); -- INVCONV New Message
2587: fnd_msg_pub.add;
2588: RAISE fnd_api.g_exc_error;
2589: END IF;
2590: END IF;
2591: -- INVCONV END
2592: --

Line 2597: WHEN fnd_api.g_exc_error THEN

2593: x_return_status := l_return_status;
2594: x_sub_cache_index:= l_sub_cache_index;
2595: --
2596: EXCEPTION
2597: WHEN fnd_api.g_exc_error THEN
2598: x_return_status := fnd_api.g_ret_sts_error;
2599: --
2600: WHEN fnd_api.g_exc_unexpected_error THEN
2601: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 2598: x_return_status := fnd_api.g_ret_sts_error;

2594: x_sub_cache_index:= l_sub_cache_index;
2595: --
2596: EXCEPTION
2597: WHEN fnd_api.g_exc_error THEN
2598: x_return_status := fnd_api.g_ret_sts_error;
2599: --
2600: WHEN fnd_api.g_exc_unexpected_error THEN
2601: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2602: --

Line 2600: WHEN fnd_api.g_exc_unexpected_error THEN

2596: EXCEPTION
2597: WHEN fnd_api.g_exc_error THEN
2598: x_return_status := fnd_api.g_ret_sts_error;
2599: --
2600: WHEN fnd_api.g_exc_unexpected_error THEN
2601: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2602: --
2603: WHEN OTHERS THEN
2604: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 2601: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2597: WHEN fnd_api.g_exc_error THEN
2598: x_return_status := fnd_api.g_ret_sts_error;
2599: --
2600: WHEN fnd_api.g_exc_unexpected_error THEN
2601: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2602: --
2603: WHEN OTHERS THEN
2604: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2605: --

Line 2604: x_return_status := fnd_api.g_ret_sts_unexp_error ;

2600: WHEN fnd_api.g_exc_unexpected_error THEN
2601: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2602: --
2603: WHEN OTHERS THEN
2604: x_return_status := fnd_api.g_ret_sts_unexp_error ;
2605: --
2606: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
2607: THEN
2608: fnd_msg_pub.add_exc_msg

Line 2646: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

2642: , p_org_cache_index IN INTEGER
2643: , x_supply_cache_index OUT NOCOPY INTEGER
2644: , x_sub_cache_index OUT NOCOPY INTEGER
2645: ) IS
2646: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
2647: l_structure_num NUMBER := NULL;
2648: l_supply_cache_index NUMBER := NULL;
2649: l_sub_cache_index NUMBER := NULL;
2650: l_is_valid NUMBER := NULL;

Line 2683: RAISE fnd_api.g_exc_error;

2679:
2680: IF p_supply_source_type_id IS NULL THEN
2681: fnd_message.set_name('INV', 'MISSING SUPPLY');
2682: fnd_msg_pub.add;
2683: RAISE fnd_api.g_exc_error;
2684: END IF;
2685: --
2686:
2687: /*** {{ R12 Enhanced reservations code changes ***/

Line 2698: RAISE fnd_api.g_exc_error;

2694: inv_reservation_global.g_source_type_rcv)) THEN
2695:
2696: fnd_message.set_name('INV', 'INV_RSV_INVALID_SUPPLY');
2697: fnd_msg_pub.ADD;
2698: RAISE fnd_api.g_exc_error;
2699: END IF;
2700: /*** End R12 }} ***/
2701:
2702: IF (l_debug = 1) THEN

Line 2717: IF l_return_status = fnd_api.g_ret_sts_error THEN

2713: , p_supply_source_name => p_supply_source_name
2714: , x_index => l_supply_cache_index
2715: );
2716: --
2717: IF l_return_status = fnd_api.g_ret_sts_error THEN
2718: RAISE fnd_api.g_exc_error;
2719: END IF ;
2720: --
2721: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 2718: RAISE fnd_api.g_exc_error;

2714: , x_index => l_supply_cache_index
2715: );
2716: --
2717: IF l_return_status = fnd_api.g_ret_sts_error THEN
2718: RAISE fnd_api.g_exc_error;
2719: END IF ;
2720: --
2721: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2722: RAISE fnd_api.g_exc_unexpected_error;

Line 2721: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

2717: IF l_return_status = fnd_api.g_ret_sts_error THEN
2718: RAISE fnd_api.g_exc_error;
2719: END IF ;
2720: --
2721: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2722: RAISE fnd_api.g_exc_unexpected_error;
2723: END IF;
2724: --
2725: -- for other supply sources (wip, po), call their validation api

Line 2722: RAISE fnd_api.g_exc_unexpected_error;

2718: RAISE fnd_api.g_exc_error;
2719: END IF ;
2720: --
2721: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2722: RAISE fnd_api.g_exc_unexpected_error;
2723: END IF;
2724: --
2725: -- for other supply sources (wip, po), call their validation api
2726: -- when available

Line 2755: IF l_return_status = fnd_api.g_ret_sts_error THEN

2751: IF (l_debug = 1) THEN
2752: debug_print('After calling validate po ' || l_return_status);
2753: END IF;
2754:
2755: IF l_return_status = fnd_api.g_ret_sts_error THEN
2756: RAISE fnd_api.g_exc_error;
2757: END IF ;
2758: --
2759: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 2756: RAISE fnd_api.g_exc_error;

2752: debug_print('After calling validate po ' || l_return_status);
2753: END IF;
2754:
2755: IF l_return_status = fnd_api.g_ret_sts_error THEN
2756: RAISE fnd_api.g_exc_error;
2757: END IF ;
2758: --
2759: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2760: RAISE fnd_api.g_exc_unexpected_error;

Line 2759: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

2755: IF l_return_status = fnd_api.g_ret_sts_error THEN
2756: RAISE fnd_api.g_exc_error;
2757: END IF ;
2758: --
2759: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2760: RAISE fnd_api.g_exc_unexpected_error;
2761: END IF;
2762: ELSIF p_supply_source_type_id = inv_reservation_global.g_source_type_req
2763: THEN

Line 2760: RAISE fnd_api.g_exc_unexpected_error;

2756: RAISE fnd_api.g_exc_error;
2757: END IF ;
2758: --
2759: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2760: RAISE fnd_api.g_exc_unexpected_error;
2761: END IF;
2762: ELSIF p_supply_source_type_id = inv_reservation_global.g_source_type_req
2763: THEN
2764: IF (l_debug = 1) THEN

Line 2782: IF l_return_status = fnd_api.g_ret_sts_error THEN

2778: );
2779: IF (l_debug = 1) THEN
2780: debug_print('After calling validate req ' || l_return_status);
2781: END IF;
2782: IF l_return_status = fnd_api.g_ret_sts_error THEN
2783: RAISE fnd_api.g_exc_error;
2784: END IF ;
2785: --
2786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 2783: RAISE fnd_api.g_exc_error;

2779: IF (l_debug = 1) THEN
2780: debug_print('After calling validate req ' || l_return_status);
2781: END IF;
2782: IF l_return_status = fnd_api.g_ret_sts_error THEN
2783: RAISE fnd_api.g_exc_error;
2784: END IF ;
2785: --
2786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2787: RAISE fnd_api.g_exc_unexpected_error;

Line 2786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

2782: IF l_return_status = fnd_api.g_ret_sts_error THEN
2783: RAISE fnd_api.g_exc_error;
2784: END IF ;
2785: --
2786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2787: RAISE fnd_api.g_exc_unexpected_error;
2788: END IF;
2789:
2790: /*** {{ R12 Enhanced reservations code changes ***/

Line 2787: RAISE fnd_api.g_exc_unexpected_error;

2783: RAISE fnd_api.g_exc_error;
2784: END IF ;
2785: --
2786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
2787: RAISE fnd_api.g_exc_unexpected_error;
2788: END IF;
2789:
2790: /*** {{ R12 Enhanced reservations code changes ***/
2791: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_internal_req) THEN

Line 2805: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

2801: , p_supply_source_line_id => p_supply_source_line_id
2802: , p_supply_source_line_detail => NULL
2803: );
2804:
2805: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2806: RAISE fnd_api.g_exc_error;
2807: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2808: RAISE fnd_api.g_exc_unexpected_error;
2809: END IF;

Line 2806: RAISE fnd_api.g_exc_error;

2802: , p_supply_source_line_detail => NULL
2803: );
2804:
2805: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2806: RAISE fnd_api.g_exc_error;
2807: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2808: RAISE fnd_api.g_exc_unexpected_error;
2809: END IF;
2810: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_asn) THEN

Line 2807: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

2803: );
2804:
2805: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2806: RAISE fnd_api.g_exc_error;
2807: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2808: RAISE fnd_api.g_exc_unexpected_error;
2809: END IF;
2810: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_asn) THEN
2811: validate_supply_source_asn

Line 2808: RAISE fnd_api.g_exc_unexpected_error;

2804:
2805: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2806: RAISE fnd_api.g_exc_error;
2807: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2808: RAISE fnd_api.g_exc_unexpected_error;
2809: END IF;
2810: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_asn) THEN
2811: validate_supply_source_asn
2812: (

Line 2824: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

2820: , p_supply_source_line_id => p_supply_source_line_id
2821: , p_supply_source_line_detail => p_supply_source_line_detail
2822: );
2823:
2824: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2825: RAISE fnd_api.g_exc_error;
2826: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2827: RAISE fnd_api.g_exc_unexpected_error;
2828: END IF;

Line 2825: RAISE fnd_api.g_exc_error;

2821: , p_supply_source_line_detail => p_supply_source_line_detail
2822: );
2823:
2824: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2825: RAISE fnd_api.g_exc_error;
2826: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2827: RAISE fnd_api.g_exc_unexpected_error;
2828: END IF;
2829: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_intransit) THEN

Line 2826: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

2822: );
2823:
2824: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2825: RAISE fnd_api.g_exc_error;
2826: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2827: RAISE fnd_api.g_exc_unexpected_error;
2828: END IF;
2829: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_intransit) THEN
2830: validate_supply_source_intran

Line 2827: RAISE fnd_api.g_exc_unexpected_error;

2823:
2824: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2825: RAISE fnd_api.g_exc_error;
2826: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2827: RAISE fnd_api.g_exc_unexpected_error;
2828: END IF;
2829: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_intransit) THEN
2830: validate_supply_source_intran
2831: (

Line 2843: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

2839: , p_supply_source_line_id => p_supply_source_line_id
2840: , p_supply_source_line_detail => NULL
2841: );
2842:
2843: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2844: RAISE fnd_api.g_exc_error;
2845: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2846: RAISE fnd_api.g_exc_unexpected_error;
2847: END IF;

Line 2844: RAISE fnd_api.g_exc_error;

2840: , p_supply_source_line_detail => NULL
2841: );
2842:
2843: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2844: RAISE fnd_api.g_exc_error;
2845: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2846: RAISE fnd_api.g_exc_unexpected_error;
2847: END IF;
2848: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_rcv) THEN

Line 2845: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

2841: );
2842:
2843: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2844: RAISE fnd_api.g_exc_error;
2845: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2846: RAISE fnd_api.g_exc_unexpected_error;
2847: END IF;
2848: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_rcv) THEN
2849: validate_supply_source_rcv

Line 2846: RAISE fnd_api.g_exc_unexpected_error;

2842:
2843: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2844: RAISE fnd_api.g_exc_error;
2845: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2846: RAISE fnd_api.g_exc_unexpected_error;
2847: END IF;
2848: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_rcv) THEN
2849: validate_supply_source_rcv
2850: (

Line 2862: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

2858: , p_supply_source_line_id => p_supply_source_line_id
2859: , p_supply_source_line_detail => NULL
2860: );
2861:
2862: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2863: RAISE fnd_api.g_exc_error;
2864: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2865: RAISE fnd_api.g_exc_unexpected_error;
2866: END IF;

Line 2863: RAISE fnd_api.g_exc_error;

2859: , p_supply_source_line_detail => NULL
2860: );
2861:
2862: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2863: RAISE fnd_api.g_exc_error;
2864: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2865: RAISE fnd_api.g_exc_unexpected_error;
2866: END IF;
2867:

Line 2864: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

2860: );
2861:
2862: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2863: RAISE fnd_api.g_exc_error;
2864: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2865: RAISE fnd_api.g_exc_unexpected_error;
2866: END IF;
2867:
2868: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_wip) THEN

Line 2865: RAISE fnd_api.g_exc_unexpected_error;

2861:
2862: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2863: RAISE fnd_api.g_exc_error;
2864: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2865: RAISE fnd_api.g_exc_unexpected_error;
2866: END IF;
2867:
2868: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_wip) THEN
2869: -- get wip entity id from wip_record_cache

Line 2876: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

2872: x_return_status => l_return_status
2873: , p_wip_entity_id => p_supply_source_header_id
2874: );
2875:
2876: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2877: RAISE fnd_api.g_exc_error;
2878: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2879: RAISE fnd_api.g_exc_unexpected_error;
2880: ELSE

Line 2877: RAISE fnd_api.g_exc_error;

2873: , p_wip_entity_id => p_supply_source_header_id
2874: );
2875:
2876: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2877: RAISE fnd_api.g_exc_error;
2878: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2879: RAISE fnd_api.g_exc_unexpected_error;
2880: ELSE
2881: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_type;

Line 2878: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

2874: );
2875:
2876: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2877: RAISE fnd_api.g_exc_error;
2878: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2879: RAISE fnd_api.g_exc_unexpected_error;
2880: ELSE
2881: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_type;
2882: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_job;

Line 2879: RAISE fnd_api.g_exc_unexpected_error;

2875:
2876: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2877: RAISE fnd_api.g_exc_error;
2878: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2879: RAISE fnd_api.g_exc_unexpected_error;
2880: ELSE
2881: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_type;
2882: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_job;
2883: END IF;

Line 2893: RAISE fnd_api.g_exc_error;

2889: inv_reservation_global.g_wip_source_type_osfm, inv_reservation_global.g_wip_source_type_fpo,
2890: inv_reservation_global.g_wip_source_type_batch, inv_reservation_global.g_wip_source_type_cmro)) THEN
2891: fnd_message.set_name('INV', 'INV_RSV_WIP_ENT_ERR');
2892: fnd_msg_pub.ADD;
2893: RAISE fnd_api.g_exc_error;
2894: END IF;
2895:
2896: -- add validation to check if the supply is wip discrete and osfm, then the
2897: -- demand source needs to be sales order or internal order, otherwise, error out.

Line 2904: RAISE fnd_api.g_exc_error;

2900: IF (p_demand_source_type_id NOT IN (inv_reservation_global.g_source_type_oe,
2901: inv_reservation_global.g_source_type_internal_ord)) THEN
2902: fnd_message.set_name('INV', 'INV_INVALID_DEMAND_SOURCE');
2903: fnd_msg_pub.ADD;
2904: RAISE fnd_api.g_exc_error;
2905: END IF;
2906: END IF;
2907:
2908: IF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_discrete) THEN

Line 2927: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

2923: IF (l_debug = 1) THEN
2924: debug_print('Return status from supply source wipdisc :' || l_return_status);
2925: END IF;
2926:
2927: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2928: RAISE fnd_api.g_exc_error;
2929: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2930: RAISE fnd_api.g_exc_unexpected_error;
2931: END IF;

Line 2928: RAISE fnd_api.g_exc_error;

2924: debug_print('Return status from supply source wipdisc :' || l_return_status);
2925: END IF;
2926:
2927: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2928: RAISE fnd_api.g_exc_error;
2929: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2930: RAISE fnd_api.g_exc_unexpected_error;
2931: END IF;
2932:

Line 2929: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

2925: END IF;
2926:
2927: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2928: RAISE fnd_api.g_exc_error;
2929: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2930: RAISE fnd_api.g_exc_unexpected_error;
2931: END IF;
2932:
2933: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_osfm) THEN

Line 2930: RAISE fnd_api.g_exc_unexpected_error;

2926:
2927: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2928: RAISE fnd_api.g_exc_error;
2929: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2930: RAISE fnd_api.g_exc_unexpected_error;
2931: END IF;
2932:
2933: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_osfm) THEN
2934: validate_supply_source_osfm

Line 2948: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

2944: , p_supply_source_line_detail => NULL
2945: , p_wip_entity_type => l_wip_entity_type
2946: );
2947:
2948: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2949: RAISE fnd_api.g_exc_error;
2950: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2951: RAISE fnd_api.g_exc_unexpected_error;
2952: END IF;

Line 2949: RAISE fnd_api.g_exc_error;

2945: , p_wip_entity_type => l_wip_entity_type
2946: );
2947:
2948: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2949: RAISE fnd_api.g_exc_error;
2950: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2951: RAISE fnd_api.g_exc_unexpected_error;
2952: END IF;
2953:

Line 2950: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

2946: );
2947:
2948: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2949: RAISE fnd_api.g_exc_error;
2950: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2951: RAISE fnd_api.g_exc_unexpected_error;
2952: END IF;
2953:
2954: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_fpo) THEN

Line 2951: RAISE fnd_api.g_exc_unexpected_error;

2947:
2948: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2949: RAISE fnd_api.g_exc_error;
2950: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2951: RAISE fnd_api.g_exc_unexpected_error;
2952: END IF;
2953:
2954: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_fpo) THEN
2955: validate_supply_source_fpo

Line 2968: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

2964: , p_supply_source_line_id => p_supply_source_line_id
2965: , p_supply_source_line_detail => NULL
2966: , p_wip_entity_type => l_wip_entity_type
2967: );
2968: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2969: RAISE fnd_api.g_exc_error;
2970: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2971: RAISE fnd_api.g_exc_unexpected_error;
2972: END IF;

Line 2969: RAISE fnd_api.g_exc_error;

2965: , p_supply_source_line_detail => NULL
2966: , p_wip_entity_type => l_wip_entity_type
2967: );
2968: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2969: RAISE fnd_api.g_exc_error;
2970: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2971: RAISE fnd_api.g_exc_unexpected_error;
2972: END IF;
2973: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_batch) THEN

Line 2970: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

2966: , p_wip_entity_type => l_wip_entity_type
2967: );
2968: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2969: RAISE fnd_api.g_exc_error;
2970: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2971: RAISE fnd_api.g_exc_unexpected_error;
2972: END IF;
2973: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_batch) THEN
2974: validate_supply_source_batch

Line 2971: RAISE fnd_api.g_exc_unexpected_error;

2967: );
2968: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2969: RAISE fnd_api.g_exc_error;
2970: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2971: RAISE fnd_api.g_exc_unexpected_error;
2972: END IF;
2973: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_batch) THEN
2974: validate_supply_source_batch
2975: (

Line 2987: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

2983: , p_supply_source_line_id => p_supply_source_line_id
2984: , p_supply_source_line_detail => NULL
2985: , p_wip_entity_type => l_wip_entity_type
2986: );
2987: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2988: RAISE fnd_api.g_exc_error;
2989: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2990: RAISE fnd_api.g_exc_unexpected_error;
2991: END IF;

Line 2988: RAISE fnd_api.g_exc_error;

2984: , p_supply_source_line_detail => NULL
2985: , p_wip_entity_type => l_wip_entity_type
2986: );
2987: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2988: RAISE fnd_api.g_exc_error;
2989: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2990: RAISE fnd_api.g_exc_unexpected_error;
2991: END IF;
2992: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_cmro) THEN /* Added for bug 13524480 */

Line 2989: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

2985: , p_wip_entity_type => l_wip_entity_type
2986: );
2987: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2988: RAISE fnd_api.g_exc_error;
2989: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2990: RAISE fnd_api.g_exc_unexpected_error;
2991: END IF;
2992: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_cmro) THEN /* Added for bug 13524480 */
2993: debug_print('Calling validate_supply_source_cmro :' || l_return_status);

Line 2990: RAISE fnd_api.g_exc_unexpected_error;

2986: );
2987: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
2988: RAISE fnd_api.g_exc_error;
2989: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
2990: RAISE fnd_api.g_exc_unexpected_error;
2991: END IF;
2992: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_cmro) THEN /* Added for bug 13524480 */
2993: debug_print('Calling validate_supply_source_cmro :' || l_return_status);
2994:

Line 3008: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

3004: , p_supply_source_line_id => p_supply_source_line_id
3005: , p_supply_source_line_detail => NULL
3006: , p_wip_entity_type => l_wip_entity_type
3007: );
3008: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3009: RAISE fnd_api.g_exc_error;
3010: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3011: RAISE fnd_api.g_exc_unexpected_error;
3012: END IF;

Line 3009: RAISE fnd_api.g_exc_error;

3005: , p_supply_source_line_detail => NULL
3006: , p_wip_entity_type => l_wip_entity_type
3007: );
3008: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3009: RAISE fnd_api.g_exc_error;
3010: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3011: RAISE fnd_api.g_exc_unexpected_error;
3012: END IF;
3013: END IF;

Line 3010: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

3006: , p_wip_entity_type => l_wip_entity_type
3007: );
3008: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3009: RAISE fnd_api.g_exc_error;
3010: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3011: RAISE fnd_api.g_exc_unexpected_error;
3012: END IF;
3013: END IF;
3014: /*** End R12 }} ***/

Line 3011: RAISE fnd_api.g_exc_unexpected_error;

3007: );
3008: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3009: RAISE fnd_api.g_exc_error;
3010: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3011: RAISE fnd_api.g_exc_unexpected_error;
3012: END IF;
3013: END IF;
3014: /*** End R12 }} ***/
3015: END IF;

Line 3038: IF l_return_status = fnd_api.g_ret_sts_error THEN

3034: IF (l_debug = 1) THEN
3035: debug_print('After adding supply cache. Return status :' || l_return_status);
3036: END IF;
3037:
3038: IF l_return_status = fnd_api.g_ret_sts_error THEN
3039: RAISE fnd_api.g_exc_error;
3040: END IF ;
3041: --
3042: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 3039: RAISE fnd_api.g_exc_error;

3035: debug_print('After adding supply cache. Return status :' || l_return_status);
3036: END IF;
3037:
3038: IF l_return_status = fnd_api.g_ret_sts_error THEN
3039: RAISE fnd_api.g_exc_error;
3040: END IF ;
3041: --
3042: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3043: RAISE fnd_api.g_exc_unexpected_error;

Line 3042: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

3038: IF l_return_status = fnd_api.g_ret_sts_error THEN
3039: RAISE fnd_api.g_exc_error;
3040: END IF ;
3041: --
3042: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3043: RAISE fnd_api.g_exc_unexpected_error;
3044: END IF;
3045: END IF;
3046: --

Line 3043: RAISE fnd_api.g_exc_unexpected_error;

3039: RAISE fnd_api.g_exc_error;
3040: END IF ;
3041: --
3042: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3043: RAISE fnd_api.g_exc_unexpected_error;
3044: END IF;
3045: END IF;
3046: --
3047: -- call validate_item_sku

Line 3069: IF l_return_status = fnd_api.g_ret_sts_error THEN

3065: IF (l_debug = 1) THEN
3066: debug_print('After adding validate item sku. Return status :' ||
3067: l_return_status);
3068: END IF;
3069: IF l_return_status = fnd_api.g_ret_sts_error THEN
3070: RAISE fnd_api.g_exc_error;
3071: END IF ;
3072: --
3073: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 3070: RAISE fnd_api.g_exc_error;

3066: debug_print('After adding validate item sku. Return status :' ||
3067: l_return_status);
3068: END IF;
3069: IF l_return_status = fnd_api.g_ret_sts_error THEN
3070: RAISE fnd_api.g_exc_error;
3071: END IF ;
3072: --
3073: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3074: RAISE fnd_api.g_exc_unexpected_error;

Line 3073: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

3069: IF l_return_status = fnd_api.g_ret_sts_error THEN
3070: RAISE fnd_api.g_exc_error;
3071: END IF ;
3072: --
3073: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3074: RAISE fnd_api.g_exc_unexpected_error;
3075: END IF;
3076: ELSIF p_subinventory_code IS NOT NULL
3077: OR p_locator_id IS NOT NULL

Line 3074: RAISE fnd_api.g_exc_unexpected_error;

3070: RAISE fnd_api.g_exc_error;
3071: END IF ;
3072: --
3073: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3074: RAISE fnd_api.g_exc_unexpected_error;
3075: END IF;
3076: ELSIF p_subinventory_code IS NOT NULL
3077: OR p_locator_id IS NOT NULL
3078: THEN

Line 3082: RAISE fnd_api.g_exc_error;

3078: THEN
3079: -- if the supply source is not inv, sub, locator should be null and serial number should be empty
3080: fnd_message.set_name('INV', 'EXTRA_SUPPLY_INFO');
3081: fnd_msg_pub.ADD;
3082: RAISE fnd_api.g_exc_error;
3083: END IF;
3084: --
3085: x_sub_cache_index := l_sub_cache_index;
3086: x_supply_cache_index := l_supply_cache_index;

Line 3090: WHEN fnd_api.g_exc_error THEN

3086: x_supply_cache_index := l_supply_cache_index;
3087: x_return_status := l_return_status;
3088: --
3089: EXCEPTION
3090: WHEN fnd_api.g_exc_error THEN
3091: x_return_status := fnd_api.g_ret_sts_error;
3092: IF (l_debug = 1) THEN
3093: debug_print('Return status from supply source :' || x_return_status);
3094: END IF;

Line 3091: x_return_status := fnd_api.g_ret_sts_error;

3087: x_return_status := l_return_status;
3088: --
3089: EXCEPTION
3090: WHEN fnd_api.g_exc_error THEN
3091: x_return_status := fnd_api.g_ret_sts_error;
3092: IF (l_debug = 1) THEN
3093: debug_print('Return status from supply source :' || x_return_status);
3094: END IF;
3095: --

Line 3096: WHEN fnd_api.g_exc_unexpected_error THEN

3092: IF (l_debug = 1) THEN
3093: debug_print('Return status from supply source :' || x_return_status);
3094: END IF;
3095: --
3096: WHEN fnd_api.g_exc_unexpected_error THEN
3097: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3098: --
3099: WHEN OTHERS THEN
3100: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 3097: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3093: debug_print('Return status from supply source :' || x_return_status);
3094: END IF;
3095: --
3096: WHEN fnd_api.g_exc_unexpected_error THEN
3097: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3098: --
3099: WHEN OTHERS THEN
3100: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3101: --

Line 3100: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3096: WHEN fnd_api.g_exc_unexpected_error THEN
3097: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3098: --
3099: WHEN OTHERS THEN
3100: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3101: --
3102: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
3103: THEN
3104: fnd_msg_pub.add_exc_msg

Line 3118: -- 3. if p_has_serial_number = fnd_api.g_true, p_primary_quantity or

3114: -- Description
3115: -- is valid if all of the following are satisfied
3116: -- 1. p_primary_uom or p_reservation_uom is not null
3117: -- 2. p_primary_quantity or p_reservation_quantity is not null
3118: -- 3. if p_has_serial_number = fnd_api.g_true, p_primary_quantity or
3119: -- if p_primary_quantity is null, p_reservation_quantity is an integer
3120: -- INVCONV
3121: -- Additional validations for single/dual tracking
3122: PROCEDURE validate_quantity

Line 3135: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

3131: , p_lot_number IN VARCHAR2 -- INVCONV
3132: , p_has_serial_number IN VARCHAR2
3133: , p_item_cache_index IN NUMBER -- INVCON
3134: ) IS
3135: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
3136: l_quantity NUMBER;
3137: l_error_message VARCHAR2(1000); -- INVCONV
3138: l_qtys_within_dev NUMBER DEFAULT 1; -- INVCONV
3139: BEGIN

Line 3145: RAISE fnd_api.g_exc_error;

3141: IF p_primary_uom IS NULL
3142: AND p_reservation_uom IS NULL THEN
3143: fnd_message.set_name('INV', 'MISSING UOM');
3144: fnd_msg_pub.add;
3145: RAISE fnd_api.g_exc_error;
3146: END IF;
3147: --
3148: IF p_primary_quantity IS NULL
3149: AND p_reservation_quantity IS NULL THEN

Line 3152: RAISE fnd_api.g_exc_error;

3148: IF p_primary_quantity IS NULL
3149: AND p_reservation_quantity IS NULL THEN
3150: fnd_message.set_name('INV', 'MISSING RSV QUANTITY');
3151: fnd_msg_pub.add;
3152: RAISE fnd_api.g_exc_error;
3153: END IF;
3154: --
3155: IF p_primary_quantity IS NOT NULL THEN
3156: l_quantity := p_primary_quantity;

Line 3164: AND p_has_serial_number = fnd_api.g_true THEN

3160: --
3161: -- the quantity should be an integer
3162: -- if serial number is provided
3163: IF l_quantity <> Trunc(l_quantity)
3164: AND p_has_serial_number = fnd_api.g_true THEN
3165: fnd_message.set_name('INV', 'INV_QTY_EQ_INTEGER');
3166: fnd_msg_pub.add;
3167: RAISE fnd_api.g_exc_error;
3168: END IF;

Line 3167: RAISE fnd_api.g_exc_error;

3163: IF l_quantity <> Trunc(l_quantity)
3164: AND p_has_serial_number = fnd_api.g_true THEN
3165: fnd_message.set_name('INV', 'INV_QTY_EQ_INTEGER');
3166: fnd_msg_pub.add;
3167: RAISE fnd_api.g_exc_error;
3168: END IF;
3169: --
3170:
3171: -- if the item is not defined as dual control

Line 3181: RAISE fnd_api.g_exc_error;

3177: -- ===================
3178: IF p_secondary_uom IS NOT NULL THEN
3179: fnd_message.set_name('INV', 'INV_SECONDARY_UOM_NOT_REQUIRED'); -- INVCONV New Message
3180: fnd_msg_pub.add;
3181: RAISE fnd_api.g_exc_error;
3182: ELSIF p_secondary_quantity IS NOT NULL THEN
3183: fnd_message.set_name('INV', 'INV_SECONDARY_QTY_NOT_REQUIRED');-- INVCONV New Message
3184: fnd_msg_pub.add;
3185: RAISE fnd_api.g_exc_error;

Line 3185: RAISE fnd_api.g_exc_error;

3181: RAISE fnd_api.g_exc_error;
3182: ELSIF p_secondary_quantity IS NOT NULL THEN
3183: fnd_message.set_name('INV', 'INV_SECONDARY_QTY_NOT_REQUIRED');-- INVCONV New Message
3184: fnd_msg_pub.add;
3185: RAISE fnd_api.g_exc_error;
3186: END IF;
3187: ELSIF inv_reservation_global.g_item_record_cache
3188: (p_item_cache_index).tracking_quantity_ind = 'PS' THEN
3189: -- DUAL UOM TRACKING

Line 3194: RAISE fnd_api.g_exc_error;

3190: -- =================
3191: IF p_secondary_uom IS NULL THEN
3192: fnd_message.set_name('INV', 'INV_SECONDARY_UOM_REQUIRED'); -- INVCONV New Message
3193: fnd_msg_pub.add;
3194: RAISE fnd_api.g_exc_error;
3195: ELSIF p_secondary_uom <> inv_reservation_global.g_item_record_cache(p_item_cache_index).secondary_uom_code THEN
3196: fnd_message.set_name('INV', 'INV_INCORRECT_SECONDARY_UOM'); -- INVCONV New Message
3197: fnd_msg_pub.add;
3198: RAISE fnd_api.g_exc_error;

Line 3198: RAISE fnd_api.g_exc_error;

3194: RAISE fnd_api.g_exc_error;
3195: ELSIF p_secondary_uom <> inv_reservation_global.g_item_record_cache(p_item_cache_index).secondary_uom_code THEN
3196: fnd_message.set_name('INV', 'INV_INCORRECT_SECONDARY_UOM'); -- INVCONV New Message
3197: fnd_msg_pub.add;
3198: RAISE fnd_api.g_exc_error;
3199: ELSIF p_secondary_quantity IS NULL THEN
3200: fnd_message.set_name('INV', 'INV_SECONDARY_QTY_REQUIRED'); -- INVCONV New Message
3201: fnd_msg_pub.add;
3202: RAISE fnd_api.g_exc_error;

Line 3202: RAISE fnd_api.g_exc_error;

3198: RAISE fnd_api.g_exc_error;
3199: ELSIF p_secondary_quantity IS NULL THEN
3200: fnd_message.set_name('INV', 'INV_SECONDARY_QTY_REQUIRED'); -- INVCONV New Message
3201: fnd_msg_pub.add;
3202: RAISE fnd_api.g_exc_error;
3203: END IF;
3204: -- Ensure that primary/secondary quantities honor the UOM conversion and deviations in place
3205:
3206: /* IF the Reservation UOM and Secondary UOM are the same AND the Reservation qty and the Secondary Reservation

Line 3229: RAISE fnd_api.g_exc_error;

3225:
3226: IF (l_qtys_within_dev <> 1) THEN
3227: --fnd_message.set_name('INV', l_error_message);
3228: --fnd_msg_pub.add;
3229: RAISE fnd_api.g_exc_error;
3230: END IF;
3231: END IF; /* IF for Fixed item */
3232: END IF;
3233: -- INVCONV END

Line 3239: WHEN fnd_api.g_exc_error THEN

3235:
3236: x_return_status := l_return_status;
3237: --
3238: EXCEPTION
3239: WHEN fnd_api.g_exc_error THEN
3240: x_return_status := fnd_api.g_ret_sts_error;
3241: --
3242: WHEN OTHERS THEN
3243: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 3240: x_return_status := fnd_api.g_ret_sts_error;

3236: x_return_status := l_return_status;
3237: --
3238: EXCEPTION
3239: WHEN fnd_api.g_exc_error THEN
3240: x_return_status := fnd_api.g_ret_sts_error;
3241: --
3242: WHEN OTHERS THEN
3243: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3244: --

Line 3243: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3239: WHEN fnd_api.g_exc_error THEN
3240: x_return_status := fnd_api.g_ret_sts_error;
3241: --
3242: WHEN OTHERS THEN
3243: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3244: --
3245: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
3246: THEN
3247: fnd_msg_pub.add_exc_msg

Line 3290: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

3286: , p_supply_type_id IN NUMBER /*** {{ R12 Enhanced reservations code changes }}***/
3287: , p_substitute_flag IN BOOLEAN DEFAULT FALSE /* Bug 6044651 */
3288: ) IS
3289:
3290: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
3291:
3292: l_org_id NUMBER;
3293:
3294: l_line_rec_inventory_item_id oe_order_lines_all.inventory_item_id%TYPE;

Line 3311: x_return_status := fnd_api.g_ret_sts_success;

3307: l_booked_flag VARCHAR2(1) := 'N'; /*** {{ R12 Enhanced reservations code changes ***/
3308: l_debug NUMBER := g_debug;
3309: BEGIN
3310: -- Initialize return status
3311: x_return_status := fnd_api.g_ret_sts_success;
3312:
3313: IF p_demand_type_id in (inv_reservation_global.g_source_type_oe,
3314: inv_reservation_global.g_source_type_internal_ord,
3315: inv_reservation_global.g_source_type_rma) THEN

Line 3358: RAISE fnd_api.g_exc_error;

3354: (Nvl(p_orig_demand_line_id,-99) <> Nvl(p_demand_line_id,-99))) THEN
3355: IF nvl(l_line_rec_open_flag, 'N') <> 'Y' AND Nvl(l_source_type_code, 'INTERNAL') <> 'EXTERNAL' THEN
3356: FND_MESSAGE.SET_NAME('INV', 'INV_RESERVATION_CLOSED_SO');
3357: FND_MSG_PUB.add;
3358: RAISE fnd_api.g_exc_error;
3359: END IF;
3360: END IF;
3361:
3362: /* Bug 3118495 -- Should not allow user to create a reservation against a shipped sales order line */

Line 3367: RAISE fnd_api.g_exc_error;

3363: -- Validate 2 -- the sales order line should not be in 'SHIPPED' status
3364: IF l_flow_status_code = 'SHIPPED' THEN
3365: FND_MESSAGE.SET_NAME('INV', 'INV_RESERVATION_SHIPPED_SO');
3366: FND_MSG_PUB.add;
3367: RAISE fnd_api.g_exc_error;
3368: END IF;
3369: -- Validate 3 -- Item : The item on the reservation has to
3370: -- be the same as the item on the sales order line
3371: /* Bug 6044651 Do not perform this validation if substitue item is being used in a sales order */

Line 3378: RAISE fnd_api.g_exc_error;

3374: OR p_reservation_item_id <> l_line_rec_inventory_item_id THEN
3375:
3376: FND_MESSAGE.SET_NAME('INV', 'INV_RESERVATION_INVALID_ITEM');
3377: FND_MSG_PUB.add;
3378: RAISE fnd_api.g_exc_error;
3379: END IF;
3380: END IF;
3381: /* End of Bug 6044651 */
3382:

Line 3389: RAISE fnd_api.g_exc_error;

3385: -- order has to be booked.
3386: IF (nvl(l_booked_flag, 'N') <> 'Y' AND p_supply_type_id <> inv_reservation_global.g_source_type_inv) THEN
3387: FND_MESSAGE.SET_NAME('INV', 'INV_RSV_SO_NOT_BOOKED');
3388: FND_MSG_PUB.ADD;
3389: RAISE fnd_api.g_exc_error;
3390: END IF;
3391:
3392: -- bugfix 16104833 --added the check for Drop Ship
3393: --

Line 3414: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

3410: IF l_debug = 1 THEN
3411: debug_print ('Inside validate sales order after calling validate so' || l_return_status);
3412: END IF;
3413:
3414: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3415: RAISE fnd_api.g_exc_error;
3416: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3417: RAISE fnd_api.g_exc_unexpected_error;
3418: END IF;

Line 3415: RAISE fnd_api.g_exc_error;

3411: debug_print ('Inside validate sales order after calling validate so' || l_return_status);
3412: END IF;
3413:
3414: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3415: RAISE fnd_api.g_exc_error;
3416: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3417: RAISE fnd_api.g_exc_unexpected_error;
3418: END IF;
3419:

Line 3416: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

3412: END IF;
3413:
3414: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3415: RAISE fnd_api.g_exc_error;
3416: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3417: RAISE fnd_api.g_exc_unexpected_error;
3418: END IF;
3419:
3420: END IF;

Line 3417: RAISE fnd_api.g_exc_unexpected_error;

3413:
3414: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3415: RAISE fnd_api.g_exc_error;
3416: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3417: RAISE fnd_api.g_exc_unexpected_error;
3418: END IF;
3419:
3420: END IF;
3421: /*** End R12 }} ***/

Line 3479: * RAISE fnd_api.g_exc_error;

3475: *IF (l_ordered_quantity_rsv_uom - l_reserved_quantity) <
3476: * p_reservation_quantity THEN
3477: * FND_MESSAGE.SET_NAME('INV','INV_RSV_ORDER_QTY_VALID');
3478: * FND_MSG_PUB.ADD;
3479: * RAISE fnd_api.g_exc_error;
3480: *END IF;
3481: */
3482:
3483: IF (l_debug = 1) THEN

Line 3490: WHEN fnd_api.g_exc_error THEN

3486:
3487: END IF;
3488:
3489: EXCEPTION
3490: WHEN fnd_api.g_exc_error THEN
3491: x_return_status := fnd_api.g_ret_sts_error;
3492: --
3493: WHEN OTHERS THEN
3494: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 3491: x_return_status := fnd_api.g_ret_sts_error;

3487: END IF;
3488:
3489: EXCEPTION
3490: WHEN fnd_api.g_exc_error THEN
3491: x_return_status := fnd_api.g_ret_sts_error;
3492: --
3493: WHEN OTHERS THEN
3494: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3495: --

Line 3494: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3490: WHEN fnd_api.g_exc_error THEN
3491: x_return_status := fnd_api.g_ret_sts_error;
3492: --
3493: WHEN OTHERS THEN
3494: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3495: --
3496: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
3497: THEN
3498: fnd_msg_pub.add_exc_msg

Line 3545: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

3541: , p_supply_receipt_date IN DATE
3542: , x_demand_cache_index OUT NOCOPY INTEGER
3543: , p_substitute_flag IN BOOLEAN DEFAULT FALSE /* Bug 6044651 */
3544: ) IS
3545: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
3546: l_structure_num NUMBER := NULL;
3547: l_index NUMBER := NULL;
3548: l_is_valid NUMBER := NULL;
3549: l_rec inv_reservation_global.demand_record;

Line 3610: RAISE fnd_api.g_exc_error;

3606: inv_reservation_global.g_source_type_rma, inv_reservation_global.g_source_type_wip)
3607: AND NOT(p_demand_source_type_id >= 100)) THEN --Bug# 10194255
3608: fnd_message.set_name('INV','INV_INVALID_DEMAND_SOURCE');
3609: fnd_msg_pub.add;
3610: RAISE fnd_api.g_exc_error;
3611: END IF;
3612: /*** End R12 }} ***/
3613:
3614: -- if the demand source type is inventory, or type id > 100

Line 3621: RAISE fnd_api.g_exc_error;

3617: OR p_demand_source_type_id >= 100 THEN --Bug# 10194255
3618: if p_demand_source_name IS NULL THEN
3619: fnd_message.set_name('INV','INV_INVALID_DEMAND_SOURCE');
3620: fnd_msg_pub.add;
3621: RAISE fnd_api.g_exc_error;
3622: END IF;
3623: END IF;
3624: --
3625: -- search for the demand source in the cache first

Line 3636: IF l_return_status = fnd_api.g_ret_sts_error THEN

3632: , p_demand_source_name => p_demand_source_name
3633: , x_index => l_index
3634: );
3635: --
3636: IF l_return_status = fnd_api.g_ret_sts_error THEN
3637: RAISE fnd_api.g_exc_error;
3638: END IF ;
3639: --
3640: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 3637: RAISE fnd_api.g_exc_error;

3633: , x_index => l_index
3634: );
3635: --
3636: IF l_return_status = fnd_api.g_ret_sts_error THEN
3637: RAISE fnd_api.g_exc_error;
3638: END IF ;
3639: --
3640: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3641: RAISE fnd_api.g_exc_unexpected_error;

Line 3640: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

3636: IF l_return_status = fnd_api.g_ret_sts_error THEN
3637: RAISE fnd_api.g_exc_error;
3638: END IF ;
3639: --
3640: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3641: RAISE fnd_api.g_exc_unexpected_error;
3642: END IF;
3643: --
3644: -- I would just put valid demand source in the cache for

Line 3641: RAISE fnd_api.g_exc_unexpected_error;

3637: RAISE fnd_api.g_exc_error;
3638: END IF ;
3639: --
3640: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3641: RAISE fnd_api.g_exc_unexpected_error;
3642: END IF;
3643: --
3644: -- I would just put valid demand source in the cache for
3645: -- now. so I do not need to check is_valid

Line 3672: -- call fnd api to validate the account id

3668: ood.organization_id = p_organization_id
3669: AND ffs.id_flex_code = 'GL#'
3670: AND ood.chart_of_accounts_id = ffs.id_flex_num;
3671:
3672: -- call fnd api to validate the account id
3673: IF NOT fnd_flex_keyval.validate_ccid
3674: (
3675: 'SQLGL'
3676: , 'GL#'

Line 3682: RAISE fnd_api.g_exc_error;

3678: , p_demand_source_header_id
3679: ) THEN
3680: fnd_message.set_name('INV', 'INVALID_ACCOUNT_NUMBER');
3681: fnd_msg_pub.add;
3682: RAISE fnd_api.g_exc_error;
3683: END IF;
3684: EXCEPTION
3685: WHEN no_data_found THEN
3686: fnd_message.set_name('INV', 'INVALID_ACCOUNT_NUMBER');

Line 3688: RAISE fnd_api.g_exc_error;

3684: EXCEPTION
3685: WHEN no_data_found THEN
3686: fnd_message.set_name('INV', 'INVALID_ACCOUNT_NUMBER');
3687: fnd_msg_pub.add;
3688: RAISE fnd_api.g_exc_error;
3689: END;
3690: --
3691: ELSE
3692: fnd_message.set_name('INV', 'INVALID_ACCOUNT_NUMBER');

Line 3694: RAISE fnd_api.g_exc_error;

3690: --
3691: ELSE
3692: fnd_message.set_name('INV', 'INVALID_ACCOUNT_NUMBER');
3693: fnd_msg_pub.add;
3694: RAISE fnd_api.g_exc_error;
3695: END IF;
3696: END IF;
3697: --
3698: IF p_demand_source_type_id

Line 3712: RAISE fnd_api.g_exc_error;

3708: , data_set => p_organization_id
3709: ) THEN
3710: fnd_message.set_name('INV', 'INVALID_ACCOUNT_ALIAS');
3711: fnd_msg_pub.add;
3712: RAISE fnd_api.g_exc_error;
3713: END IF;
3714: END IF;
3715: END IF;
3716:

Line 3726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

3722: x_return_status => l_return_status
3723: , p_wip_entity_id => p_demand_source_header_id
3724: );
3725:
3726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3727: RAISE fnd_api.g_exc_error;
3728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3729: RAISE fnd_api.g_exc_unexpected_error;
3730: ELSE

Line 3727: RAISE fnd_api.g_exc_error;

3723: , p_wip_entity_id => p_demand_source_header_id
3724: );
3725:
3726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3727: RAISE fnd_api.g_exc_error;
3728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3729: RAISE fnd_api.g_exc_unexpected_error;
3730: ELSE
3731: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_demand_source_header_id).wip_entity_type;

Line 3728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

3724: );
3725:
3726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3727: RAISE fnd_api.g_exc_error;
3728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3729: RAISE fnd_api.g_exc_unexpected_error;
3730: ELSE
3731: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_demand_source_header_id).wip_entity_type;
3732: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_demand_source_header_id).wip_entity_job;

Line 3729: RAISE fnd_api.g_exc_unexpected_error;

3725:
3726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3727: RAISE fnd_api.g_exc_error;
3728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3729: RAISE fnd_api.g_exc_unexpected_error;
3730: ELSE
3731: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_demand_source_header_id).wip_entity_type;
3732: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_demand_source_header_id).wip_entity_job;
3733: END IF;

Line 3749: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

3745: , p_demand_source_line_detail => p_demand_source_line_detail
3746: , p_wip_entity_type => l_wip_entity_type
3747: );
3748:
3749: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3750: RAISE fnd_api.g_exc_error;
3751: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3752: RAISE fnd_api.g_exc_unexpected_error;
3753: END IF;

Line 3750: RAISE fnd_api.g_exc_error;

3746: , p_wip_entity_type => l_wip_entity_type
3747: );
3748:
3749: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3750: RAISE fnd_api.g_exc_error;
3751: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3752: RAISE fnd_api.g_exc_unexpected_error;
3753: END IF;
3754: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_fpo) THEN

Line 3751: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

3747: );
3748:
3749: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3750: RAISE fnd_api.g_exc_error;
3751: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3752: RAISE fnd_api.g_exc_unexpected_error;
3753: END IF;
3754: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_fpo) THEN
3755: validate_demand_source_fpo(

Line 3752: RAISE fnd_api.g_exc_unexpected_error;

3748:
3749: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3750: RAISE fnd_api.g_exc_error;
3751: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3752: RAISE fnd_api.g_exc_unexpected_error;
3753: END IF;
3754: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_fpo) THEN
3755: validate_demand_source_fpo(
3756: x_return_status => l_return_status

Line 3768: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

3764: , p_demand_source_line_detail => null
3765: , p_wip_entity_type => l_wip_entity_type
3766: );
3767:
3768: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3769: RAISE fnd_api.g_exc_error;
3770: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3771: RAISE fnd_api.g_exc_unexpected_error;
3772: END IF;

Line 3769: RAISE fnd_api.g_exc_error;

3765: , p_wip_entity_type => l_wip_entity_type
3766: );
3767:
3768: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3769: RAISE fnd_api.g_exc_error;
3770: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3771: RAISE fnd_api.g_exc_unexpected_error;
3772: END IF;
3773: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_batch) THEN

Line 3770: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

3766: );
3767:
3768: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3769: RAISE fnd_api.g_exc_error;
3770: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3771: RAISE fnd_api.g_exc_unexpected_error;
3772: END IF;
3773: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_batch) THEN
3774: validate_demand_source_batch(

Line 3771: RAISE fnd_api.g_exc_unexpected_error;

3767:
3768: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3769: RAISE fnd_api.g_exc_error;
3770: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3771: RAISE fnd_api.g_exc_unexpected_error;
3772: END IF;
3773: ELSIF (l_wip_entity_type = inv_reservation_global.g_wip_source_type_batch) THEN
3774: validate_demand_source_batch(
3775: x_return_status => l_return_status

Line 3787: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

3783: , p_demand_source_line_detail => null
3784: , p_wip_entity_type => l_wip_entity_type
3785: );
3786:
3787: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3788: RAISE fnd_api.g_exc_error;
3789: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3790: RAISE fnd_api.g_exc_unexpected_error;
3791: END IF;

Line 3788: RAISE fnd_api.g_exc_error;

3784: , p_wip_entity_type => l_wip_entity_type
3785: );
3786:
3787: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3788: RAISE fnd_api.g_exc_error;
3789: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3790: RAISE fnd_api.g_exc_unexpected_error;
3791: END IF;
3792: END IF;

Line 3789: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

3785: );
3786:
3787: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3788: RAISE fnd_api.g_exc_error;
3789: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3790: RAISE fnd_api.g_exc_unexpected_error;
3791: END IF;
3792: END IF;
3793: END IF;

Line 3790: RAISE fnd_api.g_exc_unexpected_error;

3786:
3787: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3788: RAISE fnd_api.g_exc_error;
3789: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3790: RAISE fnd_api.g_exc_unexpected_error;
3791: END IF;
3792: END IF;
3793: END IF;
3794:

Line 3830: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

3826: , p_supply_type_id => p_supply_type_id
3827: , p_substitute_flag => p_substitute_flag); /* Bug 6044651 */
3828:
3829:
3830: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3831: RAISE fnd_api.g_exc_error;
3832: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3833: RAISE fnd_api.g_exc_unexpected_error;
3834: END IF;

Line 3831: RAISE fnd_api.g_exc_error;

3827: , p_substitute_flag => p_substitute_flag); /* Bug 6044651 */
3828:
3829:
3830: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3831: RAISE fnd_api.g_exc_error;
3832: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3833: RAISE fnd_api.g_exc_unexpected_error;
3834: END IF;
3835: END IF; --END IF check p_rsv_action

Line 3832: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

3828:
3829:
3830: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3831: RAISE fnd_api.g_exc_error;
3832: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3833: RAISE fnd_api.g_exc_unexpected_error;
3834: END IF;
3835: END IF; --END IF check p_rsv_action
3836: END IF; --END IF demand source in SO, Internal Order, RMA

Line 3833: RAISE fnd_api.g_exc_unexpected_error;

3829:
3830: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3831: RAISE fnd_api.g_exc_error;
3832: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3833: RAISE fnd_api.g_exc_unexpected_error;
3834: END IF;
3835: END IF; --END IF check p_rsv_action
3836: END IF; --END IF demand source in SO, Internal Order, RMA
3837:

Line 3868: IF l_return_status = fnd_api.g_ret_sts_error THEN

3864: , p_demand_record => l_rec
3865: , x_index => l_index
3866: );
3867: --
3868: IF l_return_status = fnd_api.g_ret_sts_error THEN
3869: RAISE fnd_api.g_exc_error;
3870: END IF ;
3871: --
3872: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 3869: RAISE fnd_api.g_exc_error;

3865: , x_index => l_index
3866: );
3867: --
3868: IF l_return_status = fnd_api.g_ret_sts_error THEN
3869: RAISE fnd_api.g_exc_error;
3870: END IF ;
3871: --
3872: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3873: RAISE fnd_api.g_exc_unexpected_error;

Line 3872: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

3868: IF l_return_status = fnd_api.g_ret_sts_error THEN
3869: RAISE fnd_api.g_exc_error;
3870: END IF ;
3871: --
3872: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3873: RAISE fnd_api.g_exc_unexpected_error;
3874: END IF;
3875: --
3876: x_demand_cache_index := l_index;

Line 3873: RAISE fnd_api.g_exc_unexpected_error;

3869: RAISE fnd_api.g_exc_error;
3870: END IF ;
3871: --
3872: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
3873: RAISE fnd_api.g_exc_unexpected_error;
3874: END IF;
3875: --
3876: x_demand_cache_index := l_index;
3877: x_return_status := l_return_status;

Line 3880: WHEN fnd_api.g_exc_error THEN

3876: x_demand_cache_index := l_index;
3877: x_return_status := l_return_status;
3878: --
3879: EXCEPTION
3880: WHEN fnd_api.g_exc_error THEN
3881: x_return_status := fnd_api.g_ret_sts_error;
3882: --
3883: WHEN fnd_api.g_exc_unexpected_error THEN
3884: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 3881: x_return_status := fnd_api.g_ret_sts_error;

3877: x_return_status := l_return_status;
3878: --
3879: EXCEPTION
3880: WHEN fnd_api.g_exc_error THEN
3881: x_return_status := fnd_api.g_ret_sts_error;
3882: --
3883: WHEN fnd_api.g_exc_unexpected_error THEN
3884: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3885: --

Line 3883: WHEN fnd_api.g_exc_unexpected_error THEN

3879: EXCEPTION
3880: WHEN fnd_api.g_exc_error THEN
3881: x_return_status := fnd_api.g_ret_sts_error;
3882: --
3883: WHEN fnd_api.g_exc_unexpected_error THEN
3884: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3885: --
3886: WHEN OTHERS THEN
3887: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 3884: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3880: WHEN fnd_api.g_exc_error THEN
3881: x_return_status := fnd_api.g_ret_sts_error;
3882: --
3883: WHEN fnd_api.g_exc_unexpected_error THEN
3884: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3885: --
3886: WHEN OTHERS THEN
3887: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3888: --

Line 3887: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3883: WHEN fnd_api.g_exc_unexpected_error THEN
3884: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3885: --
3886: WHEN OTHERS THEN
3887: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3888: --
3889: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
3890: THEN
3891: fnd_msg_pub.add_exc_msg

Line 3915: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

3911: , x_msg_count OUT NOCOPY NUMBER
3912: , x_msg_data OUT NOCOPY VARCHAR2
3913: , p_rsv_rec IN inv_reservation_global.mtl_reservation_rec_type
3914: ) IS
3915: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
3916: l_msg_count NUMBER;
3917: l_msg_data VARCHAR2(1000);
3918: l_debug NUMBER;
3919:

Line 3934: (p_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN

3930: debug_print('crossdock_criteria_id = ' || p_rsv_rec.crossdock_criteria_id);
3931: END IF;
3932:
3933: IF ((p_rsv_rec.crossdock_criteria_id is not null) and
3934: (p_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN
3935: wms_xdock_utils_pvt.create_crossdock_reservation(
3936: x_return_status => l_return_status
3937: , p_rsv_rec => p_rsv_rec
3938: );

Line 3940: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

3936: x_return_status => l_return_status
3937: , p_rsv_rec => p_rsv_rec
3938: );
3939:
3940: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3941: IF (l_debug = 1) THEN
3942: debug_print('create_crossdock_reservation returns error');
3943: END IF;
3944: raise fnd_api.g_exc_error;

Line 3944: raise fnd_api.g_exc_error;

3940: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
3941: IF (l_debug = 1) THEN
3942: debug_print('create_crossdock_reservation returns error');
3943: END IF;
3944: raise fnd_api.g_exc_error;
3945: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3946: IF (l_debug = 1) THEN
3947: debug_print('create_crossdock_reservation returns unexpected error');
3948: END IF;

Line 3945: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

3941: IF (l_debug = 1) THEN
3942: debug_print('create_crossdock_reservation returns error');
3943: END IF;
3944: raise fnd_api.g_exc_error;
3945: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3946: IF (l_debug = 1) THEN
3947: debug_print('create_crossdock_reservation returns unexpected error');
3948: END IF;
3949: raise fnd_api.g_exc_unexpected_error;

Line 3949: raise fnd_api.g_exc_unexpected_error;

3945: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
3946: IF (l_debug = 1) THEN
3947: debug_print('create_crossdock_reservation returns unexpected error');
3948: END IF;
3949: raise fnd_api.g_exc_unexpected_error;
3950: END IF;
3951: END IF;
3952:
3953: x_return_status := l_return_status;

Line 3956: WHEN fnd_api.g_exc_error THEN

3952:
3953: x_return_status := l_return_status;
3954:
3955: EXCEPTION
3956: WHEN fnd_api.g_exc_error THEN
3957: x_return_status := fnd_api.g_ret_sts_error;
3958: --
3959: WHEN fnd_api.g_exc_unexpected_error THEN
3960: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 3957: x_return_status := fnd_api.g_ret_sts_error;

3953: x_return_status := l_return_status;
3954:
3955: EXCEPTION
3956: WHEN fnd_api.g_exc_error THEN
3957: x_return_status := fnd_api.g_ret_sts_error;
3958: --
3959: WHEN fnd_api.g_exc_unexpected_error THEN
3960: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3961: --

Line 3959: WHEN fnd_api.g_exc_unexpected_error THEN

3955: EXCEPTION
3956: WHEN fnd_api.g_exc_error THEN
3957: x_return_status := fnd_api.g_ret_sts_error;
3958: --
3959: WHEN fnd_api.g_exc_unexpected_error THEN
3960: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3961: --
3962: WHEN OTHERS THEN
3963: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 3960: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3956: WHEN fnd_api.g_exc_error THEN
3957: x_return_status := fnd_api.g_ret_sts_error;
3958: --
3959: WHEN fnd_api.g_exc_unexpected_error THEN
3960: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3961: --
3962: WHEN OTHERS THEN
3963: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3964: --

Line 3963: x_return_status := fnd_api.g_ret_sts_unexp_error ;

3959: WHEN fnd_api.g_exc_unexpected_error THEN
3960: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3961: --
3962: WHEN OTHERS THEN
3963: x_return_status := fnd_api.g_ret_sts_unexp_error ;
3964: --
3965: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
3966: THEN
3967: fnd_msg_pub.add_exc_msg

Line 3994: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

3990: , x_msg_data OUT NOCOPY VARCHAR2
3991: , p_orig_rsv_rec IN inv_reservation_global.mtl_reservation_rec_type
3992: , p_to_rsv_rec IN inv_reservation_global.mtl_reservation_rec_type
3993: ) IS
3994: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
3995: l_msg_count NUMBER;
3996: l_msg_data VARCHAR2(1000);
3997: l_debug NUMBER;
3998:

Line 4013: (p_to_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN

4009: debug_print('crossdock_criteria_id = ' || p_to_rsv_rec.crossdock_criteria_id);
4010: END IF;
4011:
4012: IF ((p_to_rsv_rec.crossdock_criteria_id is not null) and
4013: (p_to_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN
4014: wms_xdock_utils_pvt.update_crossdock_reservation(
4015: x_return_status => l_return_status
4016: , p_orig_rsv_rec => p_orig_rsv_rec
4017: , p_new_rsv_rec => p_to_rsv_rec

Line 4020: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

4016: , p_orig_rsv_rec => p_orig_rsv_rec
4017: , p_new_rsv_rec => p_to_rsv_rec
4018: );
4019:
4020: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4021: IF (l_debug = 1) THEN
4022: debug_print('update_crossdock_reservation returns error');
4023: END IF;
4024: raise fnd_api.g_exc_error;

Line 4024: raise fnd_api.g_exc_error;

4020: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4021: IF (l_debug = 1) THEN
4022: debug_print('update_crossdock_reservation returns error');
4023: END IF;
4024: raise fnd_api.g_exc_error;
4025: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4026: IF (l_debug = 1) THEN
4027: debug_print('update_crossdock_reservation returns unexpected error');
4028: END IF;

Line 4025: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

4021: IF (l_debug = 1) THEN
4022: debug_print('update_crossdock_reservation returns error');
4023: END IF;
4024: raise fnd_api.g_exc_error;
4025: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4026: IF (l_debug = 1) THEN
4027: debug_print('update_crossdock_reservation returns unexpected error');
4028: END IF;
4029: raise fnd_api.g_exc_unexpected_error;

Line 4029: raise fnd_api.g_exc_unexpected_error;

4025: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4026: IF (l_debug = 1) THEN
4027: debug_print('update_crossdock_reservation returns unexpected error');
4028: END IF;
4029: raise fnd_api.g_exc_unexpected_error;
4030: END IF;
4031: END IF;
4032:
4033: x_return_status := l_return_status;

Line 4036: WHEN fnd_api.g_exc_error THEN

4032:
4033: x_return_status := l_return_status;
4034:
4035: EXCEPTION
4036: WHEN fnd_api.g_exc_error THEN
4037: x_return_status := fnd_api.g_ret_sts_error;
4038: --
4039: WHEN fnd_api.g_exc_unexpected_error THEN
4040: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4037: x_return_status := fnd_api.g_ret_sts_error;

4033: x_return_status := l_return_status;
4034:
4035: EXCEPTION
4036: WHEN fnd_api.g_exc_error THEN
4037: x_return_status := fnd_api.g_ret_sts_error;
4038: --
4039: WHEN fnd_api.g_exc_unexpected_error THEN
4040: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4041: --

Line 4039: WHEN fnd_api.g_exc_unexpected_error THEN

4035: EXCEPTION
4036: WHEN fnd_api.g_exc_error THEN
4037: x_return_status := fnd_api.g_ret_sts_error;
4038: --
4039: WHEN fnd_api.g_exc_unexpected_error THEN
4040: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4041: --
4042: WHEN OTHERS THEN
4043: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4040: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4036: WHEN fnd_api.g_exc_error THEN
4037: x_return_status := fnd_api.g_ret_sts_error;
4038: --
4039: WHEN fnd_api.g_exc_unexpected_error THEN
4040: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4041: --
4042: WHEN OTHERS THEN
4043: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4044: --

Line 4043: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4039: WHEN fnd_api.g_exc_unexpected_error THEN
4040: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4041: --
4042: WHEN OTHERS THEN
4043: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4044: --
4045: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
4046: THEN
4047: fnd_msg_pub.add_exc_msg

Line 4073: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

4069: , x_msg_data OUT NOCOPY VARCHAR2
4070: , p_orig_rsv_rec IN inv_reservation_global.mtl_reservation_rec_type
4071: , p_to_rsv_rec IN inv_reservation_global.mtl_reservation_rec_type
4072: ) IS
4073: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
4074: l_msg_count NUMBER;
4075: l_msg_data VARCHAR2(1000);
4076: l_debug NUMBER;
4077:

Line 4092: (p_to_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN

4088: debug_print('crossdock_criteria_id = ' || p_to_rsv_rec.crossdock_criteria_id);
4089: END IF;
4090:
4091: IF ((p_to_rsv_rec.crossdock_criteria_id is not null) and
4092: (p_to_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN
4093: wms_xdock_utils_pvt.transfer_crossdock_reservation(
4094: x_return_status => l_return_status
4095: , p_orig_rsv_rec => p_orig_rsv_rec
4096: , p_new_rsv_rec => p_to_rsv_rec

Line 4098: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

4094: x_return_status => l_return_status
4095: , p_orig_rsv_rec => p_orig_rsv_rec
4096: , p_new_rsv_rec => p_to_rsv_rec
4097: );
4098: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4099: IF (l_debug = 1) THEN
4100: debug_print('transfer_crossdock_reservation returns error');
4101: END IF;
4102: raise fnd_api.g_exc_error;

Line 4102: raise fnd_api.g_exc_error;

4098: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4099: IF (l_debug = 1) THEN
4100: debug_print('transfer_crossdock_reservation returns error');
4101: END IF;
4102: raise fnd_api.g_exc_error;
4103: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4104: IF (l_debug = 1) THEN
4105: debug_print('transfer_crossdock_reservation returns unexpected error');
4106: END IF;

Line 4103: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

4099: IF (l_debug = 1) THEN
4100: debug_print('transfer_crossdock_reservation returns error');
4101: END IF;
4102: raise fnd_api.g_exc_error;
4103: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4104: IF (l_debug = 1) THEN
4105: debug_print('transfer_crossdock_reservation returns unexpected error');
4106: END IF;
4107: raise fnd_api.g_exc_unexpected_error;

Line 4107: raise fnd_api.g_exc_unexpected_error;

4103: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4104: IF (l_debug = 1) THEN
4105: debug_print('transfer_crossdock_reservation returns unexpected error');
4106: END IF;
4107: raise fnd_api.g_exc_unexpected_error;
4108: END IF;
4109: END IF;
4110:
4111: x_return_status := l_return_status;

Line 4114: WHEN fnd_api.g_exc_error THEN

4110:
4111: x_return_status := l_return_status;
4112:
4113: EXCEPTION
4114: WHEN fnd_api.g_exc_error THEN
4115: x_return_status := fnd_api.g_ret_sts_error;
4116: --
4117: WHEN fnd_api.g_exc_unexpected_error THEN
4118: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4115: x_return_status := fnd_api.g_ret_sts_error;

4111: x_return_status := l_return_status;
4112:
4113: EXCEPTION
4114: WHEN fnd_api.g_exc_error THEN
4115: x_return_status := fnd_api.g_ret_sts_error;
4116: --
4117: WHEN fnd_api.g_exc_unexpected_error THEN
4118: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4119: --

Line 4117: WHEN fnd_api.g_exc_unexpected_error THEN

4113: EXCEPTION
4114: WHEN fnd_api.g_exc_error THEN
4115: x_return_status := fnd_api.g_ret_sts_error;
4116: --
4117: WHEN fnd_api.g_exc_unexpected_error THEN
4118: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4119: --
4120: WHEN OTHERS THEN
4121: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4118: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4114: WHEN fnd_api.g_exc_error THEN
4115: x_return_status := fnd_api.g_ret_sts_error;
4116: --
4117: WHEN fnd_api.g_exc_unexpected_error THEN
4118: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4119: --
4120: WHEN OTHERS THEN
4121: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4122: --

Line 4121: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4117: WHEN fnd_api.g_exc_unexpected_error THEN
4118: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4119: --
4120: WHEN OTHERS THEN
4121: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4122: --
4123: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
4124: THEN
4125: fnd_msg_pub.add_exc_msg

Line 4150: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

4146: , x_msg_count OUT NOCOPY NUMBER
4147: , x_msg_data OUT NOCOPY VARCHAR2
4148: , p_rsv_rec IN inv_reservation_global.mtl_reservation_rec_type
4149: ) IS
4150: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
4151: l_msg_count NUMBER;
4152: l_msg_data VARCHAR2(1000);
4153: l_debug NUMBER;
4154:

Line 4169: (p_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN

4165: debug_print('crossdock_criteria_id = ' || p_rsv_rec.crossdock_criteria_id);
4166: END IF;
4167:
4168: IF ((p_rsv_rec.crossdock_criteria_id is not null) and
4169: (p_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN
4170: wms_xdock_utils_pvt.relieve_crossdock_reservation(
4171: x_return_status => l_return_status
4172: , p_rsv_rec => p_rsv_rec
4173: );

Line 4175: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

4171: x_return_status => l_return_status
4172: , p_rsv_rec => p_rsv_rec
4173: );
4174:
4175: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4176: IF (l_debug = 1) THEN
4177: debug_print('relieve_crossdock_reservation returns error');
4178: END IF;
4179: raise fnd_api.g_exc_error;

Line 4179: raise fnd_api.g_exc_error;

4175: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4176: IF (l_debug = 1) THEN
4177: debug_print('relieve_crossdock_reservation returns error');
4178: END IF;
4179: raise fnd_api.g_exc_error;
4180: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4181: IF (l_debug = 1) THEN
4182: debug_print('relieve_crossdock_reservation returns unexpected error');
4183: END IF;

Line 4180: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

4176: IF (l_debug = 1) THEN
4177: debug_print('relieve_crossdock_reservation returns error');
4178: END IF;
4179: raise fnd_api.g_exc_error;
4180: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4181: IF (l_debug = 1) THEN
4182: debug_print('relieve_crossdock_reservation returns unexpected error');
4183: END IF;
4184: raise fnd_api.g_exc_unexpected_error;

Line 4184: raise fnd_api.g_exc_unexpected_error;

4180: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4181: IF (l_debug = 1) THEN
4182: debug_print('relieve_crossdock_reservation returns unexpected error');
4183: END IF;
4184: raise fnd_api.g_exc_unexpected_error;
4185: END IF;
4186: END IF;
4187:
4188: x_return_status := l_return_status;

Line 4191: WHEN fnd_api.g_exc_error THEN

4187:
4188: x_return_status := l_return_status;
4189:
4190: EXCEPTION
4191: WHEN fnd_api.g_exc_error THEN
4192: x_return_status := fnd_api.g_ret_sts_error;
4193: --
4194: WHEN fnd_api.g_exc_unexpected_error THEN
4195: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4192: x_return_status := fnd_api.g_ret_sts_error;

4188: x_return_status := l_return_status;
4189:
4190: EXCEPTION
4191: WHEN fnd_api.g_exc_error THEN
4192: x_return_status := fnd_api.g_ret_sts_error;
4193: --
4194: WHEN fnd_api.g_exc_unexpected_error THEN
4195: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4196: --

Line 4194: WHEN fnd_api.g_exc_unexpected_error THEN

4190: EXCEPTION
4191: WHEN fnd_api.g_exc_error THEN
4192: x_return_status := fnd_api.g_ret_sts_error;
4193: --
4194: WHEN fnd_api.g_exc_unexpected_error THEN
4195: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4196: --
4197: WHEN OTHERS THEN
4198: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4195: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4191: WHEN fnd_api.g_exc_error THEN
4192: x_return_status := fnd_api.g_ret_sts_error;
4193: --
4194: WHEN fnd_api.g_exc_unexpected_error THEN
4195: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4196: --
4197: WHEN OTHERS THEN
4198: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4199: --

Line 4198: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4194: WHEN fnd_api.g_exc_unexpected_error THEN
4195: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4196: --
4197: WHEN OTHERS THEN
4198: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4199: --
4200: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
4201: THEN
4202: fnd_msg_pub.add_exc_msg

Line 4226: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

4222: , x_msg_count OUT NOCOPY NUMBER
4223: , x_msg_data OUT NOCOPY VARCHAR2
4224: , p_rsv_rec IN inv_reservation_global.mtl_reservation_rec_type
4225: ) IS
4226: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
4227: l_msg_count NUMBER;
4228: l_msg_data VARCHAR2(1000);
4229: l_debug NUMBER;
4230:

Line 4245: (p_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN

4241: debug_print('crossdock_criteria_id = ' || p_rsv_rec.crossdock_criteria_id);
4242: END IF;
4243:
4244: IF ((p_rsv_rec.crossdock_criteria_id is not null) and
4245: (p_rsv_rec.crossdock_criteria_id <> fnd_api.g_miss_num)) THEN
4246: wms_xdock_utils_pvt.delete_crossdock_reservation(
4247: x_return_status => l_return_status
4248: , p_rsv_rec => p_rsv_rec
4249: );

Line 4251: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

4247: x_return_status => l_return_status
4248: , p_rsv_rec => p_rsv_rec
4249: );
4250:
4251: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4252: IF (l_debug = 1) THEN
4253: debug_print('delete_crossdock_reservation returns error');
4254: END IF;
4255: raise fnd_api.g_exc_error;

Line 4255: raise fnd_api.g_exc_error;

4251: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4252: IF (l_debug = 1) THEN
4253: debug_print('delete_crossdock_reservation returns error');
4254: END IF;
4255: raise fnd_api.g_exc_error;
4256: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4257: IF (l_debug = 1) THEN
4258: debug_print('delete_crossdock_reservation returns unexpected error');
4259: END IF;

Line 4256: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

4252: IF (l_debug = 1) THEN
4253: debug_print('delete_crossdock_reservation returns error');
4254: END IF;
4255: raise fnd_api.g_exc_error;
4256: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4257: IF (l_debug = 1) THEN
4258: debug_print('delete_crossdock_reservation returns unexpected error');
4259: END IF;
4260: raise fnd_api.g_exc_unexpected_error;

Line 4260: raise fnd_api.g_exc_unexpected_error;

4256: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4257: IF (l_debug = 1) THEN
4258: debug_print('delete_crossdock_reservation returns unexpected error');
4259: END IF;
4260: raise fnd_api.g_exc_unexpected_error;
4261: END IF;
4262: END IF;
4263:
4264: x_return_status := l_return_status;

Line 4267: WHEN fnd_api.g_exc_error THEN

4263:
4264: x_return_status := l_return_status;
4265:
4266: EXCEPTION
4267: WHEN fnd_api.g_exc_error THEN
4268: x_return_status := fnd_api.g_ret_sts_error;
4269: --
4270: WHEN fnd_api.g_exc_unexpected_error THEN
4271: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4268: x_return_status := fnd_api.g_ret_sts_error;

4264: x_return_status := l_return_status;
4265:
4266: EXCEPTION
4267: WHEN fnd_api.g_exc_error THEN
4268: x_return_status := fnd_api.g_ret_sts_error;
4269: --
4270: WHEN fnd_api.g_exc_unexpected_error THEN
4271: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4272: --

Line 4270: WHEN fnd_api.g_exc_unexpected_error THEN

4266: EXCEPTION
4267: WHEN fnd_api.g_exc_error THEN
4268: x_return_status := fnd_api.g_ret_sts_error;
4269: --
4270: WHEN fnd_api.g_exc_unexpected_error THEN
4271: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4272: --
4273: WHEN OTHERS THEN
4274: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4271: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4267: WHEN fnd_api.g_exc_error THEN
4268: x_return_status := fnd_api.g_ret_sts_error;
4269: --
4270: WHEN fnd_api.g_exc_unexpected_error THEN
4271: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4272: --
4273: WHEN OTHERS THEN
4274: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4275: --

Line 4274: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4270: WHEN fnd_api.g_exc_unexpected_error THEN
4271: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4272: --
4273: WHEN OTHERS THEN
4274: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4275: --
4276: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
4277: THEN
4278: fnd_msg_pub.add_exc_msg

Line 4305: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

4301: , p_supply_source_line_detail IN NUMBER
4302: , p_project_id IN NUMBER
4303: , p_task_id IN NUMBER
4304: ) IS
4305: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
4306: l_msg_count NUMBER;
4307: l_msg_data VARCHAR2(1000);
4308: l_wms_enabled VARCHAR2(1) := 'N';
4309: l_pjm_enabled NUMBER := 1;

Line 4347: RAISE fnd_api.g_exc_error;

4343:
4344: fnd_message.set_name('INV', 'INV_RSV_PJM_WMS_INTRAN');
4345: fnd_msg_pub.ADD;
4346:
4347: RAISE fnd_api.g_exc_error;
4348: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_po OR
4349: p_supply_source_type_id = inv_reservation_global.g_source_type_asn) THEN
4350:
4351: SELECT count(min(po_distribution_id))

Line 4376: p_init_msg_lst => fnd_api.g_false,

4372: p_mtl_maintain_rsv_rec.supply_source_line_id := p_supply_source_line_id;
4373:
4374: inv_maintain_reservation_pub.reduce_reservation
4375: (p_api_version_number => 1.0,
4376: p_init_msg_lst => fnd_api.g_false,
4377: x_return_status => l_return_status,
4378: x_msg_count => l_msg_count,
4379: x_msg_data => l_msg_data,
4380: p_mtl_maintain_rsv_rec => p_mtl_maintain_rsv_rec,

Line 4390: IF l_return_status = fnd_api.g_ret_sts_error THEN

4386: IF l_debug=1 THEN
4387: debug_print ('Return Status after calling reduce reservations: '|| l_return_status);
4388: END IF;
4389:
4390: IF l_return_status = fnd_api.g_ret_sts_error THEN
4391:
4392: IF l_debug=1 THEN
4393: debug_print('Raising expected error'||l_return_status);
4394: END IF;

Line 4395: RAISE fnd_api.g_exc_error;

4391:
4392: IF l_debug=1 THEN
4393: debug_print('Raising expected error'||l_return_status);
4394: END IF;
4395: RAISE fnd_api.g_exc_error;
4396:
4397: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4398:
4399: IF l_debug=1 THEN

Line 4397: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

4393: debug_print('Raising expected error'||l_return_status);
4394: END IF;
4395: RAISE fnd_api.g_exc_error;
4396:
4397: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4398:
4399: IF l_debug=1 THEN
4400: debug_print('Rasing Unexpected error'||l_return_status);
4401: END IF;

Line 4402: RAISE fnd_api.g_exc_unexpected_error;

4398:
4399: IF l_debug=1 THEN
4400: debug_print('Rasing Unexpected error'||l_return_status);
4401: END IF;
4402: RAISE fnd_api.g_exc_unexpected_error;
4403:
4404: END IF;
4405: END IF; -- project count > 1
4406:

Line 4436: p_init_msg_lst => fnd_api.g_false,

4432: p_mtl_maintain_rsv_rec.supply_source_line_id := p_supply_source_line_id;
4433:
4434: inv_maintain_reservation_pub.reduce_reservation
4435: (p_api_version_number => 1.0,
4436: p_init_msg_lst => fnd_api.g_false,
4437: x_return_status => l_return_status,
4438: x_msg_count => l_msg_count,
4439: x_msg_data => l_msg_data,
4440: p_mtl_maintain_rsv_rec => p_mtl_maintain_rsv_rec,

Line 4450: IF l_return_status = fnd_api.g_ret_sts_error THEN

4446: IF l_debug=1 THEN
4447: debug_print ('Return Status after calling reduce reservations: '|| l_return_status);
4448: END IF;
4449:
4450: IF l_return_status = fnd_api.g_ret_sts_error THEN
4451:
4452: IF l_debug=1 THEN
4453: debug_print('Raising expected error'||l_return_status);
4454: END IF;

Line 4455: RAISE fnd_api.g_exc_error;

4451:
4452: IF l_debug=1 THEN
4453: debug_print('Raising expected error'||l_return_status);
4454: END IF;
4455: RAISE fnd_api.g_exc_error;
4456:
4457: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4458:
4459: IF l_debug=1 THEN

Line 4457: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

4453: debug_print('Raising expected error'||l_return_status);
4454: END IF;
4455: RAISE fnd_api.g_exc_error;
4456:
4457: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4458:
4459: IF l_debug=1 THEN
4460: debug_print('Rasing Unexpected error'||l_return_status);
4461: END IF;

Line 4462: RAISE fnd_api.g_exc_unexpected_error;

4458:
4459: IF l_debug=1 THEN
4460: debug_print('Rasing Unexpected error'||l_return_status);
4461: END IF;
4462: RAISE fnd_api.g_exc_unexpected_error;
4463:
4464: END IF;
4465: END IF;
4466: END IF;

Line 4485: RAISE fnd_api.g_exc_error;

4481: END IF;
4482:
4483: fnd_message.set_name('INV', 'INV_RSV_SUP_MUL_PROJ');
4484: fnd_msg_pub.ADD;
4485: RAISE fnd_api.g_exc_error;
4486: END IF;
4487:
4488: IF((p_project_id is not null) AND (l_project_count = 1)) THEN
4489: SELECT MIN(prd.project_id), MIN(prd.task_id)

Line 4503: RAISE fnd_api.g_exc_error;

4499: END IF;
4500:
4501: fnd_message.set_name('INV', 'INV_RSV_SUP_DIFF_PROJ');
4502: fnd_msg_pub.ADD;
4503: RAISE fnd_api.g_exc_error;
4504: END IF;
4505: END IF;
4506: ELSIF (p_supply_source_type_id = inv_reservation_global.g_source_type_wip) THEN
4507:

Line 4515: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

4511: x_return_status => l_return_status
4512: , p_wip_entity_id => p_supply_source_header_id
4513: );
4514:
4515: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4516: RAISE fnd_api.g_exc_error;
4517: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4518: RAISE fnd_api.g_exc_unexpected_error;
4519: ELSE

Line 4516: RAISE fnd_api.g_exc_error;

4512: , p_wip_entity_id => p_supply_source_header_id
4513: );
4514:
4515: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4516: RAISE fnd_api.g_exc_error;
4517: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4518: RAISE fnd_api.g_exc_unexpected_error;
4519: ELSE
4520: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_type;

Line 4517: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

4513: );
4514:
4515: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4516: RAISE fnd_api.g_exc_error;
4517: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4518: RAISE fnd_api.g_exc_unexpected_error;
4519: ELSE
4520: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_type;
4521: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_job;

Line 4518: RAISE fnd_api.g_exc_unexpected_error;

4514:
4515: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4516: RAISE fnd_api.g_exc_error;
4517: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4518: RAISE fnd_api.g_exc_unexpected_error;
4519: ELSE
4520: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_type;
4521: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_supply_source_header_id).wip_entity_job;
4522: END IF;

Line 4545: RAISE fnd_api.g_exc_error;

4541: END IF;
4542:
4543: fnd_message.set_name('INV', 'INV_RSV_SUP_MUL_PROJ');
4544: fnd_msg_pub.ADD;
4545: RAISE fnd_api.g_exc_error;
4546: END IF;
4547:
4548: IF (p_project_id is not null) THEN
4549: SELECT project_id, task_id

Line 4561: RAISE fnd_api.g_exc_error;

4557: END IF;
4558:
4559: fnd_message.set_name('INV', 'INV_RSV_SUP_DIFF_PROJ');
4560: fnd_msg_pub.ADD;
4561: RAISE fnd_api.g_exc_error;
4562: END IF;
4563: END IF;
4564: END IF;
4565: --commention code for pjm validations for certain supplies

Line 4573: WHEN fnd_api.g_exc_error THEN

4569:
4570: x_return_status := l_return_status;
4571:
4572: EXCEPTION
4573: WHEN fnd_api.g_exc_error THEN
4574: x_return_status := fnd_api.g_ret_sts_error;
4575: --
4576: WHEN fnd_api.g_exc_unexpected_error THEN
4577: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4574: x_return_status := fnd_api.g_ret_sts_error;

4570: x_return_status := l_return_status;
4571:
4572: EXCEPTION
4573: WHEN fnd_api.g_exc_error THEN
4574: x_return_status := fnd_api.g_ret_sts_error;
4575: --
4576: WHEN fnd_api.g_exc_unexpected_error THEN
4577: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4578: --

Line 4576: WHEN fnd_api.g_exc_unexpected_error THEN

4572: EXCEPTION
4573: WHEN fnd_api.g_exc_error THEN
4574: x_return_status := fnd_api.g_ret_sts_error;
4575: --
4576: WHEN fnd_api.g_exc_unexpected_error THEN
4577: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4578: --
4579: WHEN OTHERS THEN
4580: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 4577: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4573: WHEN fnd_api.g_exc_error THEN
4574: x_return_status := fnd_api.g_ret_sts_error;
4575: --
4576: WHEN fnd_api.g_exc_unexpected_error THEN
4577: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4578: --
4579: WHEN OTHERS THEN
4580: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4581: --

Line 4580: x_return_status := fnd_api.g_ret_sts_unexp_error ;

4576: WHEN fnd_api.g_exc_unexpected_error THEN
4577: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4578: --
4579: WHEN OTHERS THEN
4580: x_return_status := fnd_api.g_ret_sts_unexp_error ;
4581: --
4582: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
4583: THEN
4584: fnd_msg_pub.add_exc_msg

Line 4615: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

4611: , p_orig_serial_array IN inv_reservation_global.serial_number_tbl_type
4612: , p_to_serial_array IN inv_reservation_global.serial_number_tbl_type
4613: , p_rsv_action_name IN VARCHAR2
4614: ) IS
4615: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
4616: l_msg_count NUMBER;
4617: l_msg_data VARCHAR2(1000);
4618: l_wip_entity_type NUMBER;
4619: l_wip_job_type VARCHAR2(15);

Line 4668: IF (p_orig_rsv_rec.organization_id is null OR p_orig_rsv_rec.organization_id = fnd_api.g_miss_num) THEN

4664: IF (l_debug = 1) THEN
4665: debug_print('Inside from count > 0');
4666: END IF;
4667: -- return error if the p_orig_rsv_rec is null
4668: IF (p_orig_rsv_rec.organization_id is null OR p_orig_rsv_rec.organization_id = fnd_api.g_miss_num) THEN
4669: IF (l_debug = 1) THEN
4670: debug_print('The reservation record is null');
4671: END IF;
4672:

Line 4675: RAISE fnd_api.g_exc_error;

4671: END IF;
4672:
4673: fnd_message.set_name('INV', 'INV_RSV_NULL_REC');
4674: fnd_msg_pub.ADD;
4675: RAISE fnd_api.g_exc_error;
4676: END IF;
4677:
4678: inv_reservation_util_pvt.search_organization_cache
4679: (

Line 4685: IF l_return_status = fnd_api.g_ret_sts_error THEN

4681: , p_organization_id => p_orig_rsv_rec.organization_id
4682: , x_index => l_org_cache_index
4683: );
4684: --
4685: IF l_return_status = fnd_api.g_ret_sts_error THEN
4686: RAISE fnd_api.g_exc_error;
4687: End IF ;
4688: --
4689: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 4686: RAISE fnd_api.g_exc_error;

4682: , x_index => l_org_cache_index
4683: );
4684: --
4685: IF l_return_status = fnd_api.g_ret_sts_error THEN
4686: RAISE fnd_api.g_exc_error;
4687: End IF ;
4688: --
4689: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4690: RAISE fnd_api.g_exc_unexpected_error;

Line 4689: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

4685: IF l_return_status = fnd_api.g_ret_sts_error THEN
4686: RAISE fnd_api.g_exc_error;
4687: End IF ;
4688: --
4689: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4690: RAISE fnd_api.g_exc_unexpected_error;
4691: End IF;
4692: --
4693: IF l_org_cache_index IS NULL THEN

Line 4690: RAISE fnd_api.g_exc_unexpected_error;

4686: RAISE fnd_api.g_exc_error;
4687: End IF ;
4688: --
4689: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4690: RAISE fnd_api.g_exc_unexpected_error;
4691: End IF;
4692: --
4693: IF l_org_cache_index IS NULL THEN
4694: l_org_rec.organization_id:= p_orig_rsv_rec.organization_id;

Line 4700: RAISE fnd_api.g_exc_error;

4696: p_org => l_org_rec
4697: )=INV_Validate.F THEN
4698: fnd_message.set_name('INV', 'INVALID ORGANIZATION');
4699: fnd_msg_pub.add;
4700: RAISE fnd_api.g_exc_error;
4701: END IF;
4702:
4703: --
4704: inv_reservation_util_pvt.add_organization_cache

Line 4711: IF l_return_status = fnd_api.g_ret_sts_error THEN

4707: , p_organization_record => l_org_rec
4708: , x_index => l_org_cache_index
4709: );
4710: --
4711: IF l_return_status = fnd_api.g_ret_sts_error THEN
4712: RAISE fnd_api.g_exc_error;
4713: End IF ;
4714:
4715: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 4712: RAISE fnd_api.g_exc_error;

4708: , x_index => l_org_cache_index
4709: );
4710: --
4711: IF l_return_status = fnd_api.g_ret_sts_error THEN
4712: RAISE fnd_api.g_exc_error;
4713: End IF ;
4714:
4715: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4716: RAISE fnd_api.g_exc_unexpected_error;

Line 4715: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

4711: IF l_return_status = fnd_api.g_ret_sts_error THEN
4712: RAISE fnd_api.g_exc_error;
4713: End IF ;
4714:
4715: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4716: RAISE fnd_api.g_exc_unexpected_error;
4717: End IF;
4718:
4719: END IF;

Line 4716: RAISE fnd_api.g_exc_unexpected_error;

4712: RAISE fnd_api.g_exc_error;
4713: End IF ;
4714:
4715: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4716: RAISE fnd_api.g_exc_unexpected_error;
4717: End IF;
4718:
4719: END IF;
4720:

Line 4729: RAISE fnd_api.g_exc_error;

4725: END IF;
4726:
4727: fnd_message.set_name('INV', 'INV_RSV_SR_SUP_ERR');
4728: fnd_msg_pub.ADD;
4729: RAISE fnd_api.g_exc_error;
4730: END IF;
4731:
4732: IF (l_debug = 1) THEN
4733: debug_print('Before calling WIP cache');

Line 4744: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

4740: x_return_status => l_return_status
4741: , p_wip_entity_id => p_orig_rsv_rec.demand_source_header_id
4742: );
4743:
4744: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4745: RAISE fnd_api.g_exc_error;
4746: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4747: RAISE fnd_api.g_exc_unexpected_error;
4748: ELSE

Line 4745: RAISE fnd_api.g_exc_error;

4741: , p_wip_entity_id => p_orig_rsv_rec.demand_source_header_id
4742: );
4743:
4744: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4745: RAISE fnd_api.g_exc_error;
4746: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4747: RAISE fnd_api.g_exc_unexpected_error;
4748: ELSE
4749: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.demand_source_header_id).wip_entity_type;

Line 4746: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

4742: );
4743:
4744: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4745: RAISE fnd_api.g_exc_error;
4746: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4747: RAISE fnd_api.g_exc_unexpected_error;
4748: ELSE
4749: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.demand_source_header_id).wip_entity_type;
4750: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.demand_source_header_id).wip_entity_job;

Line 4747: RAISE fnd_api.g_exc_unexpected_error;

4743:
4744: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
4745: RAISE fnd_api.g_exc_error;
4746: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
4747: RAISE fnd_api.g_exc_unexpected_error;
4748: ELSE
4749: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.demand_source_header_id).wip_entity_type;
4750: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.demand_source_header_id).wip_entity_job;
4751: END IF;

Line 4770: RAISE fnd_api.g_exc_error;

4766: END IF;
4767:
4768: fnd_message.set_name('INV', 'INV_RSV_SR_DEM_ERR');
4769: fnd_msg_pub.ADD;
4770: RAISE fnd_api.g_exc_error;
4771: END IF;
4772:
4773: IF (l_debug = 1) THEN
4774: debug_print('Before calling convert missing to null');

Line 4796: If l_return_status = fnd_api.g_ret_sts_error Then

4792: ,p_organization_id => l_orig_rsv_rec.organization_id
4793: ,x_index => l_item_cache_index
4794: );
4795: --
4796: If l_return_status = fnd_api.g_ret_sts_error Then
4797: RAISE fnd_api.g_exc_error;
4798: End If;
4799: --
4800: If l_return_status = fnd_api.g_ret_sts_unexp_error Then

Line 4797: RAISE fnd_api.g_exc_error;

4793: ,x_index => l_item_cache_index
4794: );
4795: --
4796: If l_return_status = fnd_api.g_ret_sts_error Then
4797: RAISE fnd_api.g_exc_error;
4798: End If;
4799: --
4800: If l_return_status = fnd_api.g_ret_sts_unexp_error Then
4801: RAISE fnd_api.g_exc_unexpected_error;

Line 4800: If l_return_status = fnd_api.g_ret_sts_unexp_error Then

4796: If l_return_status = fnd_api.g_ret_sts_error Then
4797: RAISE fnd_api.g_exc_error;
4798: End If;
4799: --
4800: If l_return_status = fnd_api.g_ret_sts_unexp_error Then
4801: RAISE fnd_api.g_exc_unexpected_error;
4802: End If;
4803: --
4804: --if item isn't in cache, need to add it

Line 4801: RAISE fnd_api.g_exc_unexpected_error;

4797: RAISE fnd_api.g_exc_error;
4798: End If;
4799: --
4800: If l_return_status = fnd_api.g_ret_sts_unexp_error Then
4801: RAISE fnd_api.g_exc_unexpected_error;
4802: End If;
4803: --
4804: --if item isn't in cache, need to add it
4805: If l_item_cache_index IS NULL Then

Line 4817: if l_return_status = fnd_api.g_ret_sts_error then

4813: ,p_item_record => l_item_rec
4814: ,x_index => l_item_cache_index
4815: );
4816: --
4817: if l_return_status = fnd_api.g_ret_sts_error then
4818: RAISE fnd_api.g_exc_error;
4819: end if;
4820: --
4821: if l_return_status = fnd_api.g_ret_sts_unexp_error then

Line 4818: RAISE fnd_api.g_exc_error;

4814: ,x_index => l_item_cache_index
4815: );
4816: --
4817: if l_return_status = fnd_api.g_ret_sts_error then
4818: RAISE fnd_api.g_exc_error;
4819: end if;
4820: --
4821: if l_return_status = fnd_api.g_ret_sts_unexp_error then
4822: RAISE fnd_api.g_exc_unexpected_error;

Line 4821: if l_return_status = fnd_api.g_ret_sts_unexp_error then

4817: if l_return_status = fnd_api.g_ret_sts_error then
4818: RAISE fnd_api.g_exc_error;
4819: end if;
4820: --
4821: if l_return_status = fnd_api.g_ret_sts_unexp_error then
4822: RAISE fnd_api.g_exc_unexpected_error;
4823: end if;
4824: End If;
4825:

Line 4822: RAISE fnd_api.g_exc_unexpected_error;

4818: RAISE fnd_api.g_exc_error;
4819: end if;
4820: --
4821: if l_return_status = fnd_api.g_ret_sts_unexp_error then
4822: RAISE fnd_api.g_exc_unexpected_error;
4823: end if;
4824: End If;
4825:
4826: -- if revision controlled and revision in reservation record is null, return errors

Line 4895: RAISE fnd_api.g_exc_error;

4891: p_org => l_org_rec
4892: )=INV_Validate.F THEN
4893: fnd_message.set_name('INV','INVALID_SUB');
4894: fnd_msg_pub.add;
4895: RAISE fnd_api.g_exc_error;
4896: END IF;
4897:
4898: --
4899: inv_reservation_util_pvt.add_sub_cache

Line 4906: IF l_return_status = fnd_api.g_ret_sts_error THEN

4902: , p_sub_record => l_sub_rec
4903: , x_index => l_sub_cache_index
4904: );
4905: --
4906: IF l_return_status = fnd_api.g_ret_sts_error THEN
4907: RAISE fnd_api.g_exc_error;
4908: END IF ;
4909: --
4910: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 4907: RAISE fnd_api.g_exc_error;

4903: , x_index => l_sub_cache_index
4904: );
4905: --
4906: IF l_return_status = fnd_api.g_ret_sts_error THEN
4907: RAISE fnd_api.g_exc_error;
4908: END IF ;
4909: --
4910: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4911: RAISE fnd_api.g_exc_unexpected_error;

Line 4910: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

4906: IF l_return_status = fnd_api.g_ret_sts_error THEN
4907: RAISE fnd_api.g_exc_error;
4908: END IF ;
4909: --
4910: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4911: RAISE fnd_api.g_exc_unexpected_error;
4912: END IF;
4913: END IF;
4914:

Line 4911: RAISE fnd_api.g_exc_unexpected_error;

4907: RAISE fnd_api.g_exc_error;
4908: END IF ;
4909: --
4910: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
4911: RAISE fnd_api.g_exc_unexpected_error;
4912: END IF;
4913: END IF;
4914:
4915:

Line 5005: RAISE fnd_api.g_exc_error;

5001: information' || SQLERRM);
5002: END IF;
5003: fnd_message.set_name('INV', 'INV_INVALID_SERIAL');
5004: fnd_msg_pub.ADD;
5005: RAISE fnd_api.g_exc_error;
5006: END;
5007: IF (l_debug = 1) THEN
5008: debug_print('current_status = ' || l_current_status);
5009: debug_print('reservation_id = ' || l_reservation_id);

Line 5047: RAISE fnd_api.g_exc_error;

5043:
5044: fnd_message.set_name('INV', 'INV_RSV_SR_STS_ERR');
5045: fnd_msg_pub.ADD;
5046:
5047: RAISE fnd_api.g_exc_error;
5048: END IF;
5049:
5050: -- for the form record, validate the serial controls with the (org, item, rev, lot, sub, loc)
5051: -- controls on the reservation record if we create/delete/relieve reservation

Line 5083: RAISE fnd_api.g_exc_error;

5079:
5080: fnd_message.set_name('INV', 'INV_RSV_SR_NOT_MATCH');
5081: fnd_msg_pub.ADD;
5082:
5083: RAISE fnd_api.g_exc_error;
5084: END IF;
5085: ELSE
5086: IF (l_reservation_id <> nvl(l_orig_rsv_rec.reservation_id, l_reservation_id)) THEN
5087:

Line 5095: RAISE fnd_api.g_exc_error;

5091:
5092: fnd_message.set_name('INV', 'INV_RSV_SR_NOT_MATCH');
5093: fnd_msg_pub.ADD;
5094:
5095: RAISE fnd_api.g_exc_error;
5096: END IF;
5097: END IF;
5098: END LOOP;
5099:

Line 5107: IF (p_to_rsv_rec.organization_id is null OR p_to_rsv_rec.organization_id = fnd_api.g_miss_num) THEN

5103: IF (l_debug = 1) THEN
5104: debug_print('Inside to count > 0');
5105: END IF;
5106: -- return error if the p_to_rsv_rec is null
5107: IF (p_to_rsv_rec.organization_id is null OR p_to_rsv_rec.organization_id = fnd_api.g_miss_num) THEN
5108: IF (l_debug = 1) THEN
5109: debug_print('The reservation record is null');
5110: END IF;
5111:

Line 5114: RAISE fnd_api.g_exc_error;

5110: END IF;
5111:
5112: fnd_message.set_name('INV', 'INV_RSV_NULL_REC');
5113: fnd_msg_pub.ADD;
5114: RAISE fnd_api.g_exc_error;
5115: END IF;
5116:
5117: inv_reservation_util_pvt.search_organization_cache
5118: (

Line 5124: IF l_return_status = fnd_api.g_ret_sts_error THEN

5120: , p_organization_id => p_to_rsv_rec.organization_id
5121: , x_index => l_org_cache_index
5122: );
5123: --
5124: IF l_return_status = fnd_api.g_ret_sts_error THEN
5125: RAISE fnd_api.g_exc_error;
5126: End IF ;
5127: --
5128: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5125: RAISE fnd_api.g_exc_error;

5121: , x_index => l_org_cache_index
5122: );
5123: --
5124: IF l_return_status = fnd_api.g_ret_sts_error THEN
5125: RAISE fnd_api.g_exc_error;
5126: End IF ;
5127: --
5128: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5129: RAISE fnd_api.g_exc_unexpected_error;

Line 5128: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5124: IF l_return_status = fnd_api.g_ret_sts_error THEN
5125: RAISE fnd_api.g_exc_error;
5126: End IF ;
5127: --
5128: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5129: RAISE fnd_api.g_exc_unexpected_error;
5130: End IF;
5131: --
5132: IF l_org_cache_index IS NULL THEN

Line 5129: RAISE fnd_api.g_exc_unexpected_error;

5125: RAISE fnd_api.g_exc_error;
5126: End IF ;
5127: --
5128: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5129: RAISE fnd_api.g_exc_unexpected_error;
5130: End IF;
5131: --
5132: IF l_org_cache_index IS NULL THEN
5133: l_org_rec.organization_id:= p_to_rsv_rec.organization_id;

Line 5139: RAISE fnd_api.g_exc_error;

5135: p_org => l_org_rec
5136: )=INV_Validate.F THEN
5137: fnd_message.set_name('INV', 'INVALID ORGANIZATION');
5138: fnd_msg_pub.add;
5139: RAISE fnd_api.g_exc_error;
5140: END IF;
5141:
5142: --
5143: inv_reservation_util_pvt.add_organization_cache

Line 5150: IF l_return_status = fnd_api.g_ret_sts_error THEN

5146: , p_organization_record => l_org_rec
5147: , x_index => l_org_cache_index
5148: );
5149: --
5150: IF l_return_status = fnd_api.g_ret_sts_error THEN
5151: RAISE fnd_api.g_exc_error;
5152: End IF ;
5153:
5154: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5151: RAISE fnd_api.g_exc_error;

5147: , x_index => l_org_cache_index
5148: );
5149: --
5150: IF l_return_status = fnd_api.g_ret_sts_error THEN
5151: RAISE fnd_api.g_exc_error;
5152: End IF ;
5153:
5154: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5155: RAISE fnd_api.g_exc_unexpected_error;

Line 5154: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5150: IF l_return_status = fnd_api.g_ret_sts_error THEN
5151: RAISE fnd_api.g_exc_error;
5152: End IF ;
5153:
5154: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5155: RAISE fnd_api.g_exc_unexpected_error;
5156: End IF;
5157:
5158: END IF;

Line 5155: RAISE fnd_api.g_exc_unexpected_error;

5151: RAISE fnd_api.g_exc_error;
5152: End IF ;
5153:
5154: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5155: RAISE fnd_api.g_exc_unexpected_error;
5156: End IF;
5157:
5158: END IF;
5159:

Line 5172: RAISE fnd_api.g_exc_error;

5168: END IF;
5169:
5170: fnd_message.set_name('INV', 'INV_RSV_SR_SUP_ERR');
5171: fnd_msg_pub.ADD;
5172: RAISE fnd_api.g_exc_error;
5173: END IF;
5174:
5175: -- validate the demand source for serial reservation of to reservation record
5176: IF (p_to_rsv_rec.demand_source_type_id = inv_reservation_global.g_source_type_wip) THEN

Line 5184: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

5180: x_return_status => l_return_status
5181: , p_wip_entity_id => p_to_rsv_rec.demand_source_header_id
5182: );
5183:
5184: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5185: RAISE fnd_api.g_exc_error;
5186: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5187: RAISE fnd_api.g_exc_unexpected_error;
5188: ELSE

Line 5185: RAISE fnd_api.g_exc_error;

5181: , p_wip_entity_id => p_to_rsv_rec.demand_source_header_id
5182: );
5183:
5184: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5185: RAISE fnd_api.g_exc_error;
5186: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5187: RAISE fnd_api.g_exc_unexpected_error;
5188: ELSE
5189: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.demand_source_header_id).wip_entity_type;

Line 5186: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

5182: );
5183:
5184: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5185: RAISE fnd_api.g_exc_error;
5186: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5187: RAISE fnd_api.g_exc_unexpected_error;
5188: ELSE
5189: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.demand_source_header_id).wip_entity_type;
5190: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.demand_source_header_id).wip_entity_job;

Line 5187: RAISE fnd_api.g_exc_unexpected_error;

5183:
5184: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5185: RAISE fnd_api.g_exc_error;
5186: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5187: RAISE fnd_api.g_exc_unexpected_error;
5188: ELSE
5189: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.demand_source_header_id).wip_entity_type;
5190: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.demand_source_header_id).wip_entity_job;
5191: END IF;

Line 5209: RAISE fnd_api.g_exc_error;

5205: END IF;
5206:
5207: fnd_message.set_name('INV', 'INV_RSV_SR_DEM_ERR');
5208: fnd_msg_pub.ADD;
5209: RAISE fnd_api.g_exc_error;
5210: END IF;
5211:
5212: IF (l_debug = 1) THEN
5213: debug_print('After demand check: to record:');

Line 5236: If l_return_status = fnd_api.g_ret_sts_error Then

5232: ,p_organization_id => l_to_rsv_rec.organization_id
5233: ,x_index => l_item_cache_index
5234: );
5235: --
5236: If l_return_status = fnd_api.g_ret_sts_error Then
5237: RAISE fnd_api.g_exc_error;
5238: End If;
5239: --
5240: If l_return_status = fnd_api.g_ret_sts_unexp_error Then

Line 5237: RAISE fnd_api.g_exc_error;

5233: ,x_index => l_item_cache_index
5234: );
5235: --
5236: If l_return_status = fnd_api.g_ret_sts_error Then
5237: RAISE fnd_api.g_exc_error;
5238: End If;
5239: --
5240: If l_return_status = fnd_api.g_ret_sts_unexp_error Then
5241: RAISE fnd_api.g_exc_unexpected_error;

Line 5240: If l_return_status = fnd_api.g_ret_sts_unexp_error Then

5236: If l_return_status = fnd_api.g_ret_sts_error Then
5237: RAISE fnd_api.g_exc_error;
5238: End If;
5239: --
5240: If l_return_status = fnd_api.g_ret_sts_unexp_error Then
5241: RAISE fnd_api.g_exc_unexpected_error;
5242: End If;
5243: --
5244: --if item isn't in cache, need to add it

Line 5241: RAISE fnd_api.g_exc_unexpected_error;

5237: RAISE fnd_api.g_exc_error;
5238: End If;
5239: --
5240: If l_return_status = fnd_api.g_ret_sts_unexp_error Then
5241: RAISE fnd_api.g_exc_unexpected_error;
5242: End If;
5243: --
5244: --if item isn't in cache, need to add it
5245: If l_item_cache_index IS NULL Then

Line 5257: if l_return_status = fnd_api.g_ret_sts_error then

5253: ,p_item_record => l_item_rec
5254: ,x_index => l_item_cache_index
5255: );
5256: --
5257: if l_return_status = fnd_api.g_ret_sts_error then
5258: RAISE fnd_api.g_exc_error;
5259: end if;
5260: --
5261: if l_return_status = fnd_api.g_ret_sts_unexp_error then

Line 5258: RAISE fnd_api.g_exc_error;

5254: ,x_index => l_item_cache_index
5255: );
5256: --
5257: if l_return_status = fnd_api.g_ret_sts_error then
5258: RAISE fnd_api.g_exc_error;
5259: end if;
5260: --
5261: if l_return_status = fnd_api.g_ret_sts_unexp_error then
5262: RAISE fnd_api.g_exc_unexpected_error;

Line 5261: if l_return_status = fnd_api.g_ret_sts_unexp_error then

5257: if l_return_status = fnd_api.g_ret_sts_error then
5258: RAISE fnd_api.g_exc_error;
5259: end if;
5260: --
5261: if l_return_status = fnd_api.g_ret_sts_unexp_error then
5262: RAISE fnd_api.g_exc_unexpected_error;
5263: end if;
5264: End If;
5265:

Line 5262: RAISE fnd_api.g_exc_unexpected_error;

5258: RAISE fnd_api.g_exc_error;
5259: end if;
5260: --
5261: if l_return_status = fnd_api.g_ret_sts_unexp_error then
5262: RAISE fnd_api.g_exc_unexpected_error;
5263: end if;
5264: End If;
5265:
5266: -- if revision controlled and revision in reservation record is null, return errors

Line 5329: RAISE fnd_api.g_exc_error;

5325: p_org => l_org_rec
5326: )=INV_Validate.F THEN
5327: fnd_message.set_name('INV','INVALID_SUB');
5328: fnd_msg_pub.add;
5329: RAISE fnd_api.g_exc_error;
5330: END IF;
5331:
5332: --
5333: inv_reservation_util_pvt.add_sub_cache

Line 5340: IF l_return_status = fnd_api.g_ret_sts_error THEN

5336: , p_sub_record => l_sub_rec
5337: , x_index => l_sub_cache_index
5338: );
5339: --
5340: IF l_return_status = fnd_api.g_ret_sts_error THEN
5341: RAISE fnd_api.g_exc_error;
5342: END IF ;
5343: --
5344: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5341: RAISE fnd_api.g_exc_error;

5337: , x_index => l_sub_cache_index
5338: );
5339: --
5340: IF l_return_status = fnd_api.g_ret_sts_error THEN
5341: RAISE fnd_api.g_exc_error;
5342: END IF ;
5343: --
5344: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5345: RAISE fnd_api.g_exc_unexpected_error;

Line 5344: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5340: IF l_return_status = fnd_api.g_ret_sts_error THEN
5341: RAISE fnd_api.g_exc_error;
5342: END IF ;
5343: --
5344: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5345: RAISE fnd_api.g_exc_unexpected_error;
5346: END IF;
5347: END IF;
5348:

Line 5345: RAISE fnd_api.g_exc_unexpected_error;

5341: RAISE fnd_api.g_exc_error;
5342: END IF ;
5343: --
5344: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5345: RAISE fnd_api.g_exc_unexpected_error;
5346: END IF;
5347: END IF;
5348:
5349: IF (l_debug = 1) THEN

Line 5444: RAISE fnd_api.g_exc_error;

5440:
5441: fnd_message.set_name('INV', 'INV_RSV_SR_STS_ERR');
5442: fnd_msg_pub.ADD;
5443:
5444: RAISE fnd_api.g_exc_error;
5445: END IF;
5446:
5447: -- validate the serial controls with the (org, item, rev, lot, sub, loc) controls
5448: -- on the reservation record, return errors if they don't match

Line 5449: IF ((l_to_rsv_rec.reservation_id IS NOT NULL AND p_orig_rsv_rec.reservation_id <> fnd_api.g_miss_num AND

5445: END IF;
5446:
5447: -- validate the serial controls with the (org, item, rev, lot, sub, loc) controls
5448: -- on the reservation record, return errors if they don't match
5449: IF ((l_to_rsv_rec.reservation_id IS NOT NULL AND p_orig_rsv_rec.reservation_id <> fnd_api.g_miss_num AND
5450: l_reservation_id NOT IN (nvl(l_to_rsv_rec.reservation_id, l_reservation_id),
5451: nvl(p_orig_rsv_rec.reservation_id, l_reservation_id))) OR l_organization_id <> nvl(l_to_rsv_rec.organization_id, l_organization_id) OR
5452: p_to_serial_array(i).inventory_item_id <>
5453: nvl(l_to_rsv_rec.inventory_item_id, p_to_serial_array(i).inventory_item_id) OR

Line 5476: RAISE fnd_api.g_exc_error;

5472:
5473: fnd_message.set_name('INV', 'INV_RSV_SR_NOT_MATCH');
5474: fnd_msg_pub.ADD;
5475:
5476: RAISE fnd_api.g_exc_error;
5477: END IF;
5478: END LOOP;
5479:
5480: END IF; -- end if p_to_serial_array is not null

Line 5485: WHEN fnd_api.g_exc_error THEN

5481: END IF;
5482:
5483: x_return_status := l_return_status;
5484: EXCEPTION
5485: WHEN fnd_api.g_exc_error THEN
5486: x_return_status := fnd_api.g_ret_sts_error;
5487: --
5488: WHEN fnd_api.g_exc_unexpected_error THEN
5489: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 5486: x_return_status := fnd_api.g_ret_sts_error;

5482:
5483: x_return_status := l_return_status;
5484: EXCEPTION
5485: WHEN fnd_api.g_exc_error THEN
5486: x_return_status := fnd_api.g_ret_sts_error;
5487: --
5488: WHEN fnd_api.g_exc_unexpected_error THEN
5489: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5490: --

Line 5488: WHEN fnd_api.g_exc_unexpected_error THEN

5484: EXCEPTION
5485: WHEN fnd_api.g_exc_error THEN
5486: x_return_status := fnd_api.g_ret_sts_error;
5487: --
5488: WHEN fnd_api.g_exc_unexpected_error THEN
5489: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5490: --
5491: WHEN OTHERS THEN
5492: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 5489: x_return_status := fnd_api.g_ret_sts_unexp_error ;

5485: WHEN fnd_api.g_exc_error THEN
5486: x_return_status := fnd_api.g_ret_sts_error;
5487: --
5488: WHEN fnd_api.g_exc_unexpected_error THEN
5489: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5490: --
5491: WHEN OTHERS THEN
5492: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5493: --

Line 5492: x_return_status := fnd_api.g_ret_sts_unexp_error ;

5488: WHEN fnd_api.g_exc_unexpected_error THEN
5489: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5490: --
5491: WHEN OTHERS THEN
5492: x_return_status := fnd_api.g_ret_sts_unexp_error ;
5493: --
5494: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
5495: THEN
5496: fnd_msg_pub.add_exc_msg

Line 5543: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;

5539: , x_to_supply_cache_index OUT NOCOPY INTEGER
5540: , x_to_sub_cache_index OUT NOCOPY INTEGER
5541: , p_substitute_flag IN BOOLEAN DEFAULT FALSE /* Bug 6044651 */
5542: ) IS
5543: l_return_status VARCHAR2(1) := fnd_api.g_ret_sts_success;
5544: l_has_serial_number VARCHAR2(1);
5545: l_orig_item_cache_index INTEGER := NULL;
5546: l_orig_org_cache_index INTEGER := NULL;
5547: l_orig_demand_cache_index INTEGER := NULL;

Line 5592: IF l_return_status = fnd_api.g_ret_sts_error THEN

5588: , p_organization_id => p_orig_rsv_rec.organization_id
5589: , x_org_cache_index => l_orig_org_cache_index
5590: );
5591: --
5592: IF l_return_status = fnd_api.g_ret_sts_error THEN
5593: RAISE fnd_api.g_exc_error;
5594: END IF ;
5595: --
5596: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5593: RAISE fnd_api.g_exc_error;

5589: , x_org_cache_index => l_orig_org_cache_index
5590: );
5591: --
5592: IF l_return_status = fnd_api.g_ret_sts_error THEN
5593: RAISE fnd_api.g_exc_error;
5594: END IF ;
5595: --
5596: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5597: RAISE fnd_api.g_exc_unexpected_error;

Line 5596: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5592: IF l_return_status = fnd_api.g_ret_sts_error THEN
5593: RAISE fnd_api.g_exc_error;
5594: END IF ;
5595: --
5596: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5597: RAISE fnd_api.g_exc_unexpected_error;
5598: END IF;
5599: --
5600: validate_item

Line 5597: RAISE fnd_api.g_exc_unexpected_error;

5593: RAISE fnd_api.g_exc_error;
5594: END IF ;
5595: --
5596: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5597: RAISE fnd_api.g_exc_unexpected_error;
5598: END IF;
5599: --
5600: validate_item
5601: (

Line 5608: IF l_return_status = fnd_api.g_ret_sts_error THEN

5604: , p_organization_id => p_orig_rsv_rec.organization_id
5605: , x_item_cache_index => l_orig_item_cache_index
5606: );
5607: --
5608: IF l_return_status = fnd_api.g_ret_sts_error THEN
5609: RAISE fnd_api.g_exc_error;
5610: END IF ;
5611: --
5612: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5609: RAISE fnd_api.g_exc_error;

5605: , x_item_cache_index => l_orig_item_cache_index
5606: );
5607: --
5608: IF l_return_status = fnd_api.g_ret_sts_error THEN
5609: RAISE fnd_api.g_exc_error;
5610: END IF ;
5611: --
5612: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5613: RAISE fnd_api.g_exc_unexpected_error;

Line 5612: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5608: IF l_return_status = fnd_api.g_ret_sts_error THEN
5609: RAISE fnd_api.g_exc_error;
5610: END IF ;
5611: --
5612: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5613: RAISE fnd_api.g_exc_unexpected_error;
5614: END IF;
5615: --
5616: validate_demand_source

Line 5613: RAISE fnd_api.g_exc_unexpected_error;

5609: RAISE fnd_api.g_exc_error;
5610: END IF ;
5611: --
5612: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5613: RAISE fnd_api.g_exc_unexpected_error;
5614: END IF;
5615: --
5616: validate_demand_source
5617: (

Line 5640: IF l_return_status = fnd_api.g_ret_sts_error THEN

5636: , p_supply_receipt_date => p_orig_rsv_rec.supply_receipt_date /*** End R12 }} ***/
5637: , x_demand_cache_index => l_orig_demand_cache_index
5638: , p_substitute_flag => p_substitute_flag /* Bug 6044651 */
5639: );
5640: IF l_return_status = fnd_api.g_ret_sts_error THEN
5641: RAISE fnd_api.g_exc_error;
5642: END IF ;
5643: --
5644: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5641: RAISE fnd_api.g_exc_error;

5637: , x_demand_cache_index => l_orig_demand_cache_index
5638: , p_substitute_flag => p_substitute_flag /* Bug 6044651 */
5639: );
5640: IF l_return_status = fnd_api.g_ret_sts_error THEN
5641: RAISE fnd_api.g_exc_error;
5642: END IF ;
5643: --
5644: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5645: RAISE fnd_api.g_exc_unexpected_error;

Line 5644: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5640: IF l_return_status = fnd_api.g_ret_sts_error THEN
5641: RAISE fnd_api.g_exc_error;
5642: END IF ;
5643: --
5644: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5645: RAISE fnd_api.g_exc_unexpected_error;
5646: END IF;
5647: --
5648:

Line 5645: RAISE fnd_api.g_exc_unexpected_error;

5641: RAISE fnd_api.g_exc_error;
5642: END IF ;
5643: --
5644: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5645: RAISE fnd_api.g_exc_unexpected_error;
5646: END IF;
5647: --
5648:
5649: -- Bug: 4661026: Passing the requirement date if the demand ship date

Line 5680: IF l_return_status = fnd_api.g_ret_sts_error THEN

5676: , p_org_cache_index => l_orig_org_cache_index
5677: , x_supply_cache_index => l_orig_supply_cache_index
5678: , x_sub_cache_index => l_orig_sub_cache_index
5679: );
5680: IF l_return_status = fnd_api.g_ret_sts_error THEN
5681: RAISE fnd_api.g_exc_error;
5682: END IF ;
5683: --
5684: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5681: RAISE fnd_api.g_exc_error;

5677: , x_supply_cache_index => l_orig_supply_cache_index
5678: , x_sub_cache_index => l_orig_sub_cache_index
5679: );
5680: IF l_return_status = fnd_api.g_ret_sts_error THEN
5681: RAISE fnd_api.g_exc_error;
5682: END IF ;
5683: --
5684: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5685: RAISE fnd_api.g_exc_unexpected_error;

Line 5684: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5680: IF l_return_status = fnd_api.g_ret_sts_error THEN
5681: RAISE fnd_api.g_exc_error;
5682: END IF ;
5683: --
5684: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5685: RAISE fnd_api.g_exc_unexpected_error;
5686: END IF;
5687: --
5688: IF p_orig_serial_array.COUNT > 0 THEN

Line 5685: RAISE fnd_api.g_exc_unexpected_error;

5681: RAISE fnd_api.g_exc_error;
5682: END IF ;
5683: --
5684: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5685: RAISE fnd_api.g_exc_unexpected_error;
5686: END IF;
5687: --
5688: IF p_orig_serial_array.COUNT > 0 THEN
5689: l_has_serial_number := fnd_api.g_true;

Line 5689: l_has_serial_number := fnd_api.g_true;

5685: RAISE fnd_api.g_exc_unexpected_error;
5686: END IF;
5687: --
5688: IF p_orig_serial_array.COUNT > 0 THEN
5689: l_has_serial_number := fnd_api.g_true;
5690: ELSE
5691: l_has_serial_number := fnd_api.g_false;
5692: END IF;
5693: --

Line 5691: l_has_serial_number := fnd_api.g_false;

5687: --
5688: IF p_orig_serial_array.COUNT > 0 THEN
5689: l_has_serial_number := fnd_api.g_true;
5690: ELSE
5691: l_has_serial_number := fnd_api.g_false;
5692: END IF;
5693: --
5694: -- INVCONV BEGIN
5695: -- Extend validations to cover secondary quantity

Line 5712: IF l_return_status = fnd_api.g_ret_sts_error THEN

5708: , p_has_serial_number => l_has_serial_number
5709: , p_item_cache_index => l_orig_item_cache_index -- INVCONV
5710: );
5711: -- INVCONV END
5712: IF l_return_status = fnd_api.g_ret_sts_error THEN
5713: RAISE fnd_api.g_exc_error;
5714: END IF ;
5715: --
5716:

Line 5713: RAISE fnd_api.g_exc_error;

5709: , p_item_cache_index => l_orig_item_cache_index -- INVCONV
5710: );
5711: -- INVCONV END
5712: IF l_return_status = fnd_api.g_ret_sts_error THEN
5713: RAISE fnd_api.g_exc_error;
5714: END IF ;
5715: --
5716:
5717: /*** {{ R12 Enhanced reservations code changes ***/

Line 5726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

5722: , x_msg_data => l_msg_data
5723: , p_rsv_rec => p_orig_rsv_rec
5724: );
5725:
5726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5727: RAISE fnd_api.g_exc_error;
5728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5729: RAISE fnd_api.g_exc_unexpected_error;
5730: END IF;

Line 5727: RAISE fnd_api.g_exc_error;

5723: , p_rsv_rec => p_orig_rsv_rec
5724: );
5725:
5726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5727: RAISE fnd_api.g_exc_error;
5728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5729: RAISE fnd_api.g_exc_unexpected_error;
5730: END IF;
5731:

Line 5728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

5724: );
5725:
5726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5727: RAISE fnd_api.g_exc_error;
5728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5729: RAISE fnd_api.g_exc_unexpected_error;
5730: END IF;
5731:
5732: validate_pjm_reservations

Line 5729: RAISE fnd_api.g_exc_unexpected_error;

5725:
5726: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5727: RAISE fnd_api.g_exc_error;
5728: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5729: RAISE fnd_api.g_exc_unexpected_error;
5730: END IF;
5731:
5732: validate_pjm_reservations
5733: (

Line 5745: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

5741: , p_project_id => p_orig_rsv_rec.project_id
5742: , p_task_id => p_orig_rsv_rec.task_id
5743: );
5744:
5745: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5746: RAISE fnd_api.g_exc_error;
5747: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5748: RAISE fnd_api.g_exc_unexpected_error;
5749: END IF;

Line 5746: RAISE fnd_api.g_exc_error;

5742: , p_task_id => p_orig_rsv_rec.task_id
5743: );
5744:
5745: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5746: RAISE fnd_api.g_exc_error;
5747: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5748: RAISE fnd_api.g_exc_unexpected_error;
5749: END IF;
5750:

Line 5747: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

5743: );
5744:
5745: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5746: RAISE fnd_api.g_exc_error;
5747: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5748: RAISE fnd_api.g_exc_unexpected_error;
5749: END IF;
5750:
5751: validate_serials

Line 5748: RAISE fnd_api.g_exc_unexpected_error;

5744:
5745: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5746: RAISE fnd_api.g_exc_error;
5747: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5748: RAISE fnd_api.g_exc_unexpected_error;
5749: END IF;
5750:
5751: validate_serials
5752: (

Line 5761: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

5757: , p_to_serial_array => p_to_serial_array
5758: , p_rsv_action_name => p_rsv_action_name
5759: );
5760:
5761: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5762: RAISE fnd_api.g_exc_error;
5763: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5764: RAISE fnd_api.g_exc_unexpected_error;
5765: END IF;

Line 5762: RAISE fnd_api.g_exc_error;

5758: , p_rsv_action_name => p_rsv_action_name
5759: );
5760:
5761: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5762: RAISE fnd_api.g_exc_error;
5763: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5764: RAISE fnd_api.g_exc_unexpected_error;
5765: END IF;
5766: /*** End R12 }} ***/

Line 5763: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

5759: );
5760:
5761: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5762: RAISE fnd_api.g_exc_error;
5763: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5764: RAISE fnd_api.g_exc_unexpected_error;
5765: END IF;
5766: /*** End R12 }} ***/
5767:

Line 5764: RAISE fnd_api.g_exc_unexpected_error;

5760:
5761: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5762: RAISE fnd_api.g_exc_error;
5763: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5764: RAISE fnd_api.g_exc_unexpected_error;
5765: END IF;
5766: /*** End R12 }} ***/
5767:
5768: /*** {{ R12 Enhanced reservations code changes

Line 5782: IF l_return_status = fnd_api.g_ret_sts_error THEN

5778: , p_reservation_uom_code => p_orig_rsv_rec.reservation_uom_code
5779: , p_reservation_item_id => p_orig_rsv_rec.inventory_item_id
5780: , p_reservation_org_id => p_orig_rsv_rec.organization_id
5781: );
5782: IF l_return_status = fnd_api.g_ret_sts_error THEN
5783: RAISE fnd_api.g_exc_error;
5784: END IF;
5785: --
5786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5783: RAISE fnd_api.g_exc_error;

5779: , p_reservation_item_id => p_orig_rsv_rec.inventory_item_id
5780: , p_reservation_org_id => p_orig_rsv_rec.organization_id
5781: );
5782: IF l_return_status = fnd_api.g_ret_sts_error THEN
5783: RAISE fnd_api.g_exc_error;
5784: END IF;
5785: --
5786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5787: RAISE fnd_api.g_exc_unexpected_error;

Line 5786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5782: IF l_return_status = fnd_api.g_ret_sts_error THEN
5783: RAISE fnd_api.g_exc_error;
5784: END IF;
5785: --
5786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5787: RAISE fnd_api.g_exc_unexpected_error;
5788: END IF;
5789: *** End R12 }} ***/
5790:

Line 5787: RAISE fnd_api.g_exc_unexpected_error;

5783: RAISE fnd_api.g_exc_error;
5784: END IF;
5785: --
5786: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5787: RAISE fnd_api.g_exc_unexpected_error;
5788: END IF;
5789: *** End R12 }} ***/
5790:
5791: -- check to see if there are existing crossdock reservations against this

Line 5811: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

5807: x_return_status => l_return_status
5808: , p_wip_entity_id => p_orig_rsv_rec.supply_source_header_id
5809: );
5810:
5811: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5812: RAISE fnd_api.g_exc_error;
5813: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5814: RAISE fnd_api.g_exc_unexpected_error;
5815: ELSE

Line 5812: RAISE fnd_api.g_exc_error;

5808: , p_wip_entity_id => p_orig_rsv_rec.supply_source_header_id
5809: );
5810:
5811: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5812: RAISE fnd_api.g_exc_error;
5813: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5814: RAISE fnd_api.g_exc_unexpected_error;
5815: ELSE
5816: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.supply_source_header_id).wip_entity_type;

Line 5813: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

5809: );
5810:
5811: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5812: RAISE fnd_api.g_exc_error;
5813: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5814: RAISE fnd_api.g_exc_unexpected_error;
5815: ELSE
5816: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.supply_source_header_id).wip_entity_type;
5817: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.supply_source_header_id).wip_entity_job;

Line 5814: RAISE fnd_api.g_exc_unexpected_error;

5810:
5811: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
5812: RAISE fnd_api.g_exc_error;
5813: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
5814: RAISE fnd_api.g_exc_unexpected_error;
5815: ELSE
5816: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.supply_source_header_id).wip_entity_type;
5817: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_orig_rsv_rec.supply_source_header_id).wip_entity_job;
5818: END IF;

Line 5857: RAISE fnd_api.g_exc_error;

5853: IF (l_debug = 1) THEN
5854: debug_print('Job already has a crossdocked reservation for a different demand');
5855: fnd_message.set_name('INV', 'INV_INVALID_DEMAND_SOURCE');
5856: fnd_msg_pub.add;
5857: RAISE fnd_api.g_exc_error;
5858: END IF;
5859: END IF;
5860: END IF; */
5861: END IF;

Line 5873: If l_return_status = fnd_api.g_ret_sts_error Then

5869: ,p_organization_id => p_orig_rsv_rec.organization_id
5870: ,x_index => l_orig_item_cache_index
5871: );
5872: --
5873: If l_return_status = fnd_api.g_ret_sts_error Then
5874: RAISE fnd_api.g_exc_error;
5875: End If;
5876: --
5877: If l_return_status = fnd_api.g_ret_sts_unexp_error Then

Line 5874: RAISE fnd_api.g_exc_error;

5870: ,x_index => l_orig_item_cache_index
5871: );
5872: --
5873: If l_return_status = fnd_api.g_ret_sts_error Then
5874: RAISE fnd_api.g_exc_error;
5875: End If;
5876: --
5877: If l_return_status = fnd_api.g_ret_sts_unexp_error Then
5878: RAISE fnd_api.g_exc_unexpected_error;

Line 5877: If l_return_status = fnd_api.g_ret_sts_unexp_error Then

5873: If l_return_status = fnd_api.g_ret_sts_error Then
5874: RAISE fnd_api.g_exc_error;
5875: End If;
5876: --
5877: If l_return_status = fnd_api.g_ret_sts_unexp_error Then
5878: RAISE fnd_api.g_exc_unexpected_error;
5879: End If;
5880: --
5881: --if item isn't in cache, need to add it

Line 5878: RAISE fnd_api.g_exc_unexpected_error;

5874: RAISE fnd_api.g_exc_error;
5875: End If;
5876: --
5877: If l_return_status = fnd_api.g_ret_sts_unexp_error Then
5878: RAISE fnd_api.g_exc_unexpected_error;
5879: End If;
5880: --
5881: --if item isn't in cache, need to add it
5882: If l_orig_item_cache_index IS NULL Then

Line 5894: if l_return_status = fnd_api.g_ret_sts_error then

5890: ,p_item_record => l_item_rec
5891: ,x_index => l_orig_item_cache_index
5892: );
5893: --
5894: if l_return_status = fnd_api.g_ret_sts_error then
5895: RAISE fnd_api.g_exc_error;
5896: end if;
5897: --
5898: if l_return_status = fnd_api.g_ret_sts_unexp_error then

Line 5895: RAISE fnd_api.g_exc_error;

5891: ,x_index => l_orig_item_cache_index
5892: );
5893: --
5894: if l_return_status = fnd_api.g_ret_sts_error then
5895: RAISE fnd_api.g_exc_error;
5896: end if;
5897: --
5898: if l_return_status = fnd_api.g_ret_sts_unexp_error then
5899: RAISE fnd_api.g_exc_unexpected_error;

Line 5898: if l_return_status = fnd_api.g_ret_sts_unexp_error then

5894: if l_return_status = fnd_api.g_ret_sts_error then
5895: RAISE fnd_api.g_exc_error;
5896: end if;
5897: --
5898: if l_return_status = fnd_api.g_ret_sts_unexp_error then
5899: RAISE fnd_api.g_exc_unexpected_error;
5900: end if;
5901: End If;
5902: END IF;

Line 5899: RAISE fnd_api.g_exc_unexpected_error;

5895: RAISE fnd_api.g_exc_error;
5896: end if;
5897: --
5898: if l_return_status = fnd_api.g_ret_sts_unexp_error then
5899: RAISE fnd_api.g_exc_unexpected_error;
5900: end if;
5901: End If;
5902: END IF;
5903: --

Line 5913: IF l_return_status = fnd_api.g_ret_sts_error THEN

5909: , p_organization_id => p_to_rsv_rec.organization_id
5910: , x_org_cache_index => l_to_org_cache_index
5911: );
5912: --
5913: IF l_return_status = fnd_api.g_ret_sts_error THEN
5914: RAISE fnd_api.g_exc_error;
5915: END IF ;
5916: --
5917: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5914: RAISE fnd_api.g_exc_error;

5910: , x_org_cache_index => l_to_org_cache_index
5911: );
5912: --
5913: IF l_return_status = fnd_api.g_ret_sts_error THEN
5914: RAISE fnd_api.g_exc_error;
5915: END IF ;
5916: --
5917: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5918: RAISE fnd_api.g_exc_unexpected_error;

Line 5917: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5913: IF l_return_status = fnd_api.g_ret_sts_error THEN
5914: RAISE fnd_api.g_exc_error;
5915: END IF ;
5916: --
5917: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5918: RAISE fnd_api.g_exc_unexpected_error;
5919: END IF;
5920: --
5921: validate_item

Line 5918: RAISE fnd_api.g_exc_unexpected_error;

5914: RAISE fnd_api.g_exc_error;
5915: END IF ;
5916: --
5917: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5918: RAISE fnd_api.g_exc_unexpected_error;
5919: END IF;
5920: --
5921: validate_item
5922: (

Line 5929: IF l_return_status = fnd_api.g_ret_sts_error THEN

5925: , p_organization_id => p_to_rsv_rec.organization_id
5926: , x_item_cache_index => l_to_item_cache_index
5927: );
5928: --
5929: IF l_return_status = fnd_api.g_ret_sts_error THEN
5930: RAISE fnd_api.g_exc_error;
5931: END IF ;
5932: --
5933: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5930: RAISE fnd_api.g_exc_error;

5926: , x_item_cache_index => l_to_item_cache_index
5927: );
5928: --
5929: IF l_return_status = fnd_api.g_ret_sts_error THEN
5930: RAISE fnd_api.g_exc_error;
5931: END IF ;
5932: --
5933: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5934: RAISE fnd_api.g_exc_unexpected_error;

Line 5933: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5929: IF l_return_status = fnd_api.g_ret_sts_error THEN
5930: RAISE fnd_api.g_exc_error;
5931: END IF ;
5932: --
5933: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5934: RAISE fnd_api.g_exc_unexpected_error;
5935: END IF;
5936: --
5937: validate_demand_source

Line 5934: RAISE fnd_api.g_exc_unexpected_error;

5930: RAISE fnd_api.g_exc_error;
5931: END IF ;
5932: --
5933: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5934: RAISE fnd_api.g_exc_unexpected_error;
5935: END IF;
5936: --
5937: validate_demand_source
5938: (

Line 5961: IF l_return_status = fnd_api.g_ret_sts_error THEN

5957: , p_demand_ship_date => p_orig_rsv_rec.demand_ship_date
5958: , p_supply_receipt_date => p_orig_rsv_rec.supply_receipt_date /*** End R12 }} ***/
5959: , x_demand_cache_index => l_to_demand_cache_index
5960: );
5961: IF l_return_status = fnd_api.g_ret_sts_error THEN
5962: RAISE fnd_api.g_exc_error;
5963: END IF ;
5964: --
5965: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 5962: RAISE fnd_api.g_exc_error;

5958: , p_supply_receipt_date => p_orig_rsv_rec.supply_receipt_date /*** End R12 }} ***/
5959: , x_demand_cache_index => l_to_demand_cache_index
5960: );
5961: IF l_return_status = fnd_api.g_ret_sts_error THEN
5962: RAISE fnd_api.g_exc_error;
5963: END IF ;
5964: --
5965: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5966: RAISE fnd_api.g_exc_unexpected_error;

Line 5965: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

5961: IF l_return_status = fnd_api.g_ret_sts_error THEN
5962: RAISE fnd_api.g_exc_error;
5963: END IF ;
5964: --
5965: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5966: RAISE fnd_api.g_exc_unexpected_error;
5967: END IF;
5968: --
5969:

Line 5966: RAISE fnd_api.g_exc_unexpected_error;

5962: RAISE fnd_api.g_exc_error;
5963: END IF ;
5964: --
5965: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
5966: RAISE fnd_api.g_exc_unexpected_error;
5967: END IF;
5968: --
5969:
5970: -- Bug: 4661026: Passing the requirement date if the demand ship date

Line 6006: IF l_return_status = fnd_api.g_ret_sts_error THEN

6002: IF (l_debug = 1) THEN
6003: debug_print(' After calling validate supply source ' || l_return_status);
6004: END IF;
6005:
6006: IF l_return_status = fnd_api.g_ret_sts_error THEN
6007: RAISE fnd_api.g_exc_error;
6008: END IF ;
6009: --
6010: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 6007: RAISE fnd_api.g_exc_error;

6003: debug_print(' After calling validate supply source ' || l_return_status);
6004: END IF;
6005:
6006: IF l_return_status = fnd_api.g_ret_sts_error THEN
6007: RAISE fnd_api.g_exc_error;
6008: END IF ;
6009: --
6010: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6011: RAISE fnd_api.g_exc_unexpected_error;

Line 6010: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6006: IF l_return_status = fnd_api.g_ret_sts_error THEN
6007: RAISE fnd_api.g_exc_error;
6008: END IF ;
6009: --
6010: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6011: RAISE fnd_api.g_exc_unexpected_error;
6012: END IF;
6013: --
6014: IF p_to_serial_array.COUNT > 0 THEN

Line 6011: RAISE fnd_api.g_exc_unexpected_error;

6007: RAISE fnd_api.g_exc_error;
6008: END IF ;
6009: --
6010: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6011: RAISE fnd_api.g_exc_unexpected_error;
6012: END IF;
6013: --
6014: IF p_to_serial_array.COUNT > 0 THEN
6015: l_has_serial_number := fnd_api.g_true;

Line 6015: l_has_serial_number := fnd_api.g_true;

6011: RAISE fnd_api.g_exc_unexpected_error;
6012: END IF;
6013: --
6014: IF p_to_serial_array.COUNT > 0 THEN
6015: l_has_serial_number := fnd_api.g_true;
6016: ELSE
6017: l_has_serial_number := fnd_api.g_false;
6018: END IF;
6019: --

Line 6017: l_has_serial_number := fnd_api.g_false;

6013: --
6014: IF p_to_serial_array.COUNT > 0 THEN
6015: l_has_serial_number := fnd_api.g_true;
6016: ELSE
6017: l_has_serial_number := fnd_api.g_false;
6018: END IF;
6019: --
6020: -- INVCONV BEGIN
6021: -- Extend validations to cover secondary quantity

Line 6041: IF l_return_status = fnd_api.g_ret_sts_error THEN

6037: IF (l_debug = 1) THEN
6038: debug_print(' After calling validate quantity ' || l_return_status);
6039: END IF;
6040:
6041: IF l_return_status = fnd_api.g_ret_sts_error THEN
6042: RAISE fnd_api.g_exc_error;
6043: END IF ;
6044: --
6045: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 6042: RAISE fnd_api.g_exc_error;

6038: debug_print(' After calling validate quantity ' || l_return_status);
6039: END IF;
6040:
6041: IF l_return_status = fnd_api.g_ret_sts_error THEN
6042: RAISE fnd_api.g_exc_error;
6043: END IF ;
6044: --
6045: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6046: RAISE fnd_api.g_exc_unexpected_error;

Line 6045: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6041: IF l_return_status = fnd_api.g_ret_sts_error THEN
6042: RAISE fnd_api.g_exc_error;
6043: END IF ;
6044: --
6045: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6046: RAISE fnd_api.g_exc_unexpected_error;
6047: END IF;
6048:
6049: IF p_orig_rsv_rec.inventory_item_id

Line 6046: RAISE fnd_api.g_exc_unexpected_error;

6042: RAISE fnd_api.g_exc_error;
6043: END IF ;
6044: --
6045: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6046: RAISE fnd_api.g_exc_unexpected_error;
6047: END IF;
6048:
6049: IF p_orig_rsv_rec.inventory_item_id
6050: <> p_to_rsv_rec.inventory_item_id THEN

Line 6053: RAISE fnd_api.g_exc_error;

6049: IF p_orig_rsv_rec.inventory_item_id
6050: <> p_to_rsv_rec.inventory_item_id THEN
6051: fnd_message.set_name('INV', 'INVENTORY_ITEM_ID_NOT_THE_SAME');
6052: fnd_msg_pub.add;
6053: RAISE fnd_api.g_exc_error;
6054: END IF;
6055:
6056: /*** {{ R12 Enhanced reservations code changes ***/
6057: IF (p_rsv_action_name = 'UPDATE') THEN

Line 6067: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

6063: , p_orig_rsv_rec => p_orig_rsv_rec
6064: , p_to_rsv_rec => p_to_rsv_rec
6065: );
6066:
6067: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6068: RAISE fnd_api.g_exc_error;
6069: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6070: RAISE fnd_api.g_exc_unexpected_error;
6071: END IF;

Line 6068: RAISE fnd_api.g_exc_error;

6064: , p_to_rsv_rec => p_to_rsv_rec
6065: );
6066:
6067: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6068: RAISE fnd_api.g_exc_error;
6069: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6070: RAISE fnd_api.g_exc_unexpected_error;
6071: END IF;
6072:

Line 6069: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

6065: );
6066:
6067: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6068: RAISE fnd_api.g_exc_error;
6069: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6070: RAISE fnd_api.g_exc_unexpected_error;
6071: END IF;
6072:
6073: ELSIF (p_rsv_action_name = 'TRANSFER') THEN

Line 6070: RAISE fnd_api.g_exc_unexpected_error;

6066:
6067: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6068: RAISE fnd_api.g_exc_error;
6069: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6070: RAISE fnd_api.g_exc_unexpected_error;
6071: END IF;
6072:
6073: ELSIF (p_rsv_action_name = 'TRANSFER') THEN
6074: transfer_crossdock_reservation

Line 6087: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

6083: IF (l_debug = 1) THEN
6084: debug_print(' After calling validate cossdock xfer ' ||
6085: l_return_status);
6086: END IF;
6087: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6088: RAISE fnd_api.g_exc_error;
6089: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6090: RAISE fnd_api.g_exc_unexpected_error;
6091: END IF;

Line 6088: RAISE fnd_api.g_exc_error;

6084: debug_print(' After calling validate cossdock xfer ' ||
6085: l_return_status);
6086: END IF;
6087: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6088: RAISE fnd_api.g_exc_error;
6089: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6090: RAISE fnd_api.g_exc_unexpected_error;
6091: END IF;
6092: END IF;

Line 6089: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

6085: l_return_status);
6086: END IF;
6087: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6088: RAISE fnd_api.g_exc_error;
6089: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6090: RAISE fnd_api.g_exc_unexpected_error;
6091: END IF;
6092: END IF;
6093:

Line 6090: RAISE fnd_api.g_exc_unexpected_error;

6086: END IF;
6087: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6088: RAISE fnd_api.g_exc_error;
6089: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6090: RAISE fnd_api.g_exc_unexpected_error;
6091: END IF;
6092: END IF;
6093:
6094: validate_pjm_reservations

Line 6111: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

6107: IF (l_debug = 1) THEN
6108: debug_print(' After calling validate pjm ' || l_return_status);
6109: END IF;
6110:
6111: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6112: RAISE fnd_api.g_exc_error;
6113: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6114: RAISE fnd_api.g_exc_unexpected_error;
6115: END IF;

Line 6112: RAISE fnd_api.g_exc_error;

6108: debug_print(' After calling validate pjm ' || l_return_status);
6109: END IF;
6110:
6111: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6112: RAISE fnd_api.g_exc_error;
6113: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6114: RAISE fnd_api.g_exc_unexpected_error;
6115: END IF;
6116:

Line 6113: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

6109: END IF;
6110:
6111: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6112: RAISE fnd_api.g_exc_error;
6113: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6114: RAISE fnd_api.g_exc_unexpected_error;
6115: END IF;
6116:
6117: validate_serials

Line 6114: RAISE fnd_api.g_exc_unexpected_error;

6110:
6111: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6112: RAISE fnd_api.g_exc_error;
6113: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6114: RAISE fnd_api.g_exc_unexpected_error;
6115: END IF;
6116:
6117: validate_serials
6118: (

Line 6127: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

6123: , p_to_serial_array => p_to_serial_array
6124: , p_rsv_action_name => p_rsv_action_name
6125: );
6126:
6127: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6128: RAISE fnd_api.g_exc_error;
6129: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6130: RAISE fnd_api.g_exc_unexpected_error;
6131: END IF;

Line 6128: RAISE fnd_api.g_exc_error;

6124: , p_rsv_action_name => p_rsv_action_name
6125: );
6126:
6127: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6128: RAISE fnd_api.g_exc_error;
6129: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6130: RAISE fnd_api.g_exc_unexpected_error;
6131: END IF;
6132: /*** End R12 }} ***/

Line 6129: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

6125: );
6126:
6127: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6128: RAISE fnd_api.g_exc_error;
6129: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6130: RAISE fnd_api.g_exc_unexpected_error;
6131: END IF;
6132: /*** End R12 }} ***/
6133:

Line 6130: RAISE fnd_api.g_exc_unexpected_error;

6126:
6127: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6128: RAISE fnd_api.g_exc_error;
6129: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6130: RAISE fnd_api.g_exc_unexpected_error;
6131: END IF;
6132: /*** End R12 }} ***/
6133:
6134: --

Line 6168: IF l_return_status = fnd_api.g_ret_sts_error THEN

6164: , p_reservation_uom_code => p_to_rsv_rec.reservation_uom_code
6165: , p_reservation_item_id => p_to_rsv_rec.inventory_item_id
6166: , p_reservation_org_id => p_to_rsv_rec.organization_id
6167: );
6168: IF l_return_status = fnd_api.g_ret_sts_error THEN
6169: RAISE fnd_api.g_exc_error;
6170: END IF;
6171: --
6172: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 6169: RAISE fnd_api.g_exc_error;

6165: , p_reservation_item_id => p_to_rsv_rec.inventory_item_id
6166: , p_reservation_org_id => p_to_rsv_rec.organization_id
6167: );
6168: IF l_return_status = fnd_api.g_ret_sts_error THEN
6169: RAISE fnd_api.g_exc_error;
6170: END IF;
6171: --
6172: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6173: RAISE fnd_api.g_exc_unexpected_error;

Line 6172: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6168: IF l_return_status = fnd_api.g_ret_sts_error THEN
6169: RAISE fnd_api.g_exc_error;
6170: END IF;
6171: --
6172: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6173: RAISE fnd_api.g_exc_unexpected_error;
6174: END IF;
6175: --
6176: END IF;

Line 6173: RAISE fnd_api.g_exc_unexpected_error;

6169: RAISE fnd_api.g_exc_error;
6170: END IF;
6171: --
6172: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6173: RAISE fnd_api.g_exc_unexpected_error;
6174: END IF;
6175: --
6176: END IF;
6177: *** End R12 }} ***/

Line 6195: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

6191: x_return_status => l_return_status
6192: , p_wip_entity_id => p_to_rsv_rec.supply_source_header_id
6193: );
6194:
6195: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6196: RAISE fnd_api.g_exc_error;
6197: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6198: RAISE fnd_api.g_exc_unexpected_error;
6199: ELSE

Line 6196: RAISE fnd_api.g_exc_error;

6192: , p_wip_entity_id => p_to_rsv_rec.supply_source_header_id
6193: );
6194:
6195: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6196: RAISE fnd_api.g_exc_error;
6197: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6198: RAISE fnd_api.g_exc_unexpected_error;
6199: ELSE
6200: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.supply_source_header_id).wip_entity_type;

Line 6197: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

6193: );
6194:
6195: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6196: RAISE fnd_api.g_exc_error;
6197: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6198: RAISE fnd_api.g_exc_unexpected_error;
6199: ELSE
6200: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.supply_source_header_id).wip_entity_type;
6201: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.supply_source_header_id).wip_entity_job;

Line 6198: RAISE fnd_api.g_exc_unexpected_error;

6194:
6195: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6196: RAISE fnd_api.g_exc_error;
6197: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6198: RAISE fnd_api.g_exc_unexpected_error;
6199: ELSE
6200: l_wip_entity_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.supply_source_header_id).wip_entity_type;
6201: l_wip_job_type := inv_reservation_global.g_wip_record_cache(p_to_rsv_rec.supply_source_header_id).wip_entity_job;
6202: END IF;

Line 6242: RAISE fnd_api.g_exc_error;

6238: debug_print(' Reservations exist for sales order line'
6239: || l_demand_source_line_id);
6240: fnd_message.set_name('INV', 'INV_INVALID_DEMAND_SOURCE');
6241: fnd_msg_pub.add;
6242: RAISE fnd_api.g_exc_error;
6243: END IF;
6244: END IF;
6245: END IF;*/
6246: END IF;

Line 6266: IF l_return_status = fnd_api.g_ret_sts_error THEN

6262: , p_organization_id => p_orig_rsv_rec.organization_id
6263: , x_org_cache_index => l_orig_org_cache_index
6264: );
6265: --
6266: IF l_return_status = fnd_api.g_ret_sts_error THEN
6267: RAISE fnd_api.g_exc_error;
6268: END IF ;
6269: --
6270: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 6267: RAISE fnd_api.g_exc_error;

6263: , x_org_cache_index => l_orig_org_cache_index
6264: );
6265: --
6266: IF l_return_status = fnd_api.g_ret_sts_error THEN
6267: RAISE fnd_api.g_exc_error;
6268: END IF ;
6269: --
6270: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6271: RAISE fnd_api.g_exc_unexpected_error;

Line 6270: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6266: IF l_return_status = fnd_api.g_ret_sts_error THEN
6267: RAISE fnd_api.g_exc_error;
6268: END IF ;
6269: --
6270: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6271: RAISE fnd_api.g_exc_unexpected_error;
6272: END IF;
6273:
6274: validate_serials

Line 6271: RAISE fnd_api.g_exc_unexpected_error;

6267: RAISE fnd_api.g_exc_error;
6268: END IF ;
6269: --
6270: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6271: RAISE fnd_api.g_exc_unexpected_error;
6272: END IF;
6273:
6274: validate_serials
6275: (

Line 6284: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

6280: , p_to_serial_array => p_to_serial_array
6281: , p_rsv_action_name => p_rsv_action_name
6282: );
6283:
6284: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6285: RAISE fnd_api.g_exc_error;
6286: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6287: RAISE fnd_api.g_exc_unexpected_error;
6288: END IF;

Line 6285: RAISE fnd_api.g_exc_error;

6281: , p_rsv_action_name => p_rsv_action_name
6282: );
6283:
6284: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6285: RAISE fnd_api.g_exc_error;
6286: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6287: RAISE fnd_api.g_exc_unexpected_error;
6288: END IF;
6289:

Line 6286: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

6282: );
6283:
6284: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6285: RAISE fnd_api.g_exc_error;
6286: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6287: RAISE fnd_api.g_exc_unexpected_error;
6288: END IF;
6289:
6290: /*** for relieve crossdock reservation, call

Line 6287: RAISE fnd_api.g_exc_unexpected_error;

6283:
6284: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6285: RAISE fnd_api.g_exc_error;
6286: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6287: RAISE fnd_api.g_exc_unexpected_error;
6288: END IF;
6289:
6290: /*** for relieve crossdock reservation, call
6291: --- update_crossdock_reservation instead of relieve

Line 6311: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

6307: , p_orig_rsv_rec => p_orig_rsv_rec
6308: , p_to_rsv_rec => p_to_rsv_rec
6309: );
6310:
6311: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6312: RAISE fnd_api.g_exc_error;
6313: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6314: RAISE fnd_api.g_exc_unexpected_error;
6315: END IF;

Line 6312: RAISE fnd_api.g_exc_error;

6308: , p_to_rsv_rec => p_to_rsv_rec
6309: );
6310:
6311: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6312: RAISE fnd_api.g_exc_error;
6313: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6314: RAISE fnd_api.g_exc_unexpected_error;
6315: END IF;
6316: END IF;

Line 6313: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

6309: );
6310:
6311: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6312: RAISE fnd_api.g_exc_error;
6313: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6314: RAISE fnd_api.g_exc_unexpected_error;
6315: END IF;
6316: END IF;
6317: /*** End R12 }} ***/

Line 6314: RAISE fnd_api.g_exc_unexpected_error;

6310:
6311: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6312: RAISE fnd_api.g_exc_error;
6313: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6314: RAISE fnd_api.g_exc_unexpected_error;
6315: END IF;
6316: END IF;
6317: /*** End R12 }} ***/
6318:

Line 6329: IF l_return_status = fnd_api.g_ret_sts_error THEN

6325: , p_organization_id => p_orig_rsv_rec.organization_id
6326: , x_org_cache_index => l_orig_org_cache_index
6327: );
6328: --
6329: IF l_return_status = fnd_api.g_ret_sts_error THEN
6330: RAISE fnd_api.g_exc_error;
6331: END IF ;
6332: --
6333: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 6330: RAISE fnd_api.g_exc_error;

6326: , x_org_cache_index => l_orig_org_cache_index
6327: );
6328: --
6329: IF l_return_status = fnd_api.g_ret_sts_error THEN
6330: RAISE fnd_api.g_exc_error;
6331: END IF ;
6332: --
6333: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6334: RAISE fnd_api.g_exc_unexpected_error;

Line 6333: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

6329: IF l_return_status = fnd_api.g_ret_sts_error THEN
6330: RAISE fnd_api.g_exc_error;
6331: END IF ;
6332: --
6333: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6334: RAISE fnd_api.g_exc_unexpected_error;
6335: END IF;
6336:
6337: validate_serials

Line 6334: RAISE fnd_api.g_exc_unexpected_error;

6330: RAISE fnd_api.g_exc_error;
6331: END IF ;
6332: --
6333: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
6334: RAISE fnd_api.g_exc_unexpected_error;
6335: END IF;
6336:
6337: validate_serials
6338: (

Line 6347: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

6343: , p_to_serial_array => p_to_serial_array
6344: , p_rsv_action_name => p_rsv_action_name
6345: );
6346:
6347: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6348: RAISE fnd_api.g_exc_error;
6349: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6350: RAISE fnd_api.g_exc_unexpected_error;
6351: END IF;

Line 6348: RAISE fnd_api.g_exc_error;

6344: , p_rsv_action_name => p_rsv_action_name
6345: );
6346:
6347: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6348: RAISE fnd_api.g_exc_error;
6349: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6350: RAISE fnd_api.g_exc_unexpected_error;
6351: END IF;
6352:

Line 6349: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

6345: );
6346:
6347: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6348: RAISE fnd_api.g_exc_error;
6349: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6350: RAISE fnd_api.g_exc_unexpected_error;
6351: END IF;
6352:
6353: delete_crossdock_reservation

Line 6350: RAISE fnd_api.g_exc_unexpected_error;

6346:
6347: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6348: RAISE fnd_api.g_exc_error;
6349: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6350: RAISE fnd_api.g_exc_unexpected_error;
6351: END IF;
6352:
6353: delete_crossdock_reservation
6354: (

Line 6361: IF (l_return_status = fnd_api.g_ret_sts_error) THEN

6357: , x_msg_data => l_msg_data
6358: , p_rsv_rec => p_orig_rsv_rec
6359: );
6360:
6361: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6362: RAISE fnd_api.g_exc_error;
6363: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6364: RAISE fnd_api.g_exc_unexpected_error;
6365: END IF;

Line 6362: RAISE fnd_api.g_exc_error;

6358: , p_rsv_rec => p_orig_rsv_rec
6359: );
6360:
6361: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6362: RAISE fnd_api.g_exc_error;
6363: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6364: RAISE fnd_api.g_exc_unexpected_error;
6365: END IF;
6366: END IF;

Line 6363: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN

6359: );
6360:
6361: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6362: RAISE fnd_api.g_exc_error;
6363: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6364: RAISE fnd_api.g_exc_unexpected_error;
6365: END IF;
6366: END IF;
6367: /*** End R12 }} ***/

Line 6364: RAISE fnd_api.g_exc_unexpected_error;

6360:
6361: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
6362: RAISE fnd_api.g_exc_error;
6363: ELSIF (l_return_status = fnd_api.g_ret_sts_unexp_error) THEN
6364: RAISE fnd_api.g_exc_unexpected_error;
6365: END IF;
6366: END IF;
6367: /*** End R12 }} ***/
6368: IF (l_debug = 1) THEN

Line 6385: WHEN fnd_api.g_exc_error THEN

6381: --
6382: x_return_status := l_return_status;
6383: --
6384: EXCEPTION
6385: WHEN fnd_api.g_exc_error THEN
6386: x_return_status := fnd_api.g_ret_sts_error;
6387: --
6388: WHEN fnd_api.g_exc_unexpected_error THEN
6389: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 6386: x_return_status := fnd_api.g_ret_sts_error;

6382: x_return_status := l_return_status;
6383: --
6384: EXCEPTION
6385: WHEN fnd_api.g_exc_error THEN
6386: x_return_status := fnd_api.g_ret_sts_error;
6387: --
6388: WHEN fnd_api.g_exc_unexpected_error THEN
6389: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6390: --

Line 6388: WHEN fnd_api.g_exc_unexpected_error THEN

6384: EXCEPTION
6385: WHEN fnd_api.g_exc_error THEN
6386: x_return_status := fnd_api.g_ret_sts_error;
6387: --
6388: WHEN fnd_api.g_exc_unexpected_error THEN
6389: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6390: --
6391: WHEN OTHERS THEN
6392: x_return_status := fnd_api.g_ret_sts_unexp_error ;

Line 6389: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6385: WHEN fnd_api.g_exc_error THEN
6386: x_return_status := fnd_api.g_ret_sts_error;
6387: --
6388: WHEN fnd_api.g_exc_unexpected_error THEN
6389: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6390: --
6391: WHEN OTHERS THEN
6392: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6393: --

Line 6392: x_return_status := fnd_api.g_ret_sts_unexp_error ;

6388: WHEN fnd_api.g_exc_unexpected_error THEN
6389: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6390: --
6391: WHEN OTHERS THEN
6392: x_return_status := fnd_api.g_ret_sts_unexp_error ;
6393: --
6394: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error)
6395: THEN
6396: fnd_msg_pub.add_exc_msg