DBA Data[Home] [Help]

APPS.GME_MAKE_TO_ORDER_PVT dependencies on FND_API

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

46: (
47: -- errbuf OUT NOCOPY VARCHAR2
48: -- retcode OUT NOCOPY VARCHAR2
49: p_api_version IN NUMBER := 1.0
50: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
51: ,p_commit IN VARCHAR2 := fnd_api.g_false
52: ,p_so_line_id IN NUMBER
53: ) IS
54:

Line 51: ,p_commit IN VARCHAR2 := fnd_api.g_false

47: -- errbuf OUT NOCOPY VARCHAR2
48: -- retcode OUT NOCOPY VARCHAR2
49: p_api_version IN NUMBER := 1.0
50: ,p_init_msg_list IN VARCHAR2 := fnd_api.g_false
51: ,p_commit IN VARCHAR2 := fnd_api.g_false
52: ,p_so_line_id IN NUMBER
53: ) IS
54:
55: -- Standard constants to be used to check for call compatibility.

Line 193: x_return_status := FND_API.G_RET_STS_SUCCESS;

189: BEGIN
190: l_so_line_id := p_so_line_id;
191: /*Int variables
192: =========================================*/
193: x_return_status := FND_API.G_RET_STS_SUCCESS;
194:
195: IF (g_debug <= gme_debug.g_log_statement) THEN
196: gme_debug.log_initialize ('OPM_MaketoOrder');
197: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' ENTER API ');

Line 208: IF NOT FND_API.compatible_api_call (

204: SAVEPOINT create_batch_for_so_line_SP;
205:
206: /*Standard call to check for call compatibility.
207: ==============================================*/
208: IF NOT FND_API.compatible_api_call (
209: l_api_version,
210: p_api_version,
211: l_api_name,
212: g_pkg_name)

Line 217: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;

213: THEN
214: IF (g_debug <= gme_debug.g_log_statement) THEN
215: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' compatability call failure ');
216: END IF;
217: RAISE FND_API.G_EXC_UNEXPECTED_ERROR;
218: END IF;
219:
220: FND_FILE.Put_Line(FND_FILE.LOG, ' compatible OK ');
221: /* Check p_init_msg_list

Line 223: IF FND_API.to_boolean(p_init_msg_list)

219:
220: FND_FILE.Put_Line(FND_FILE.LOG, ' compatible OK ');
221: /* Check p_init_msg_list
222: =========================================*/
223: IF FND_API.to_boolean(p_init_msg_list)
224: THEN
225: FND_MSG_PUB.initialize;
226: END IF;
227:

Line 240: RAISE FND_API.G_EXC_ERROR;

236: END IF;
237: FND_MESSAGE.Set_Name('GMI','Missing');
238: FND_MESSAGE.Set_Token('MISSING', 'so_line_id');
239: FND_MSG_PUB.Add;
240: RAISE FND_API.G_EXC_ERROR;
241: END IF;
242:
243: /* Bug 13359707 - Moved code up */
244: /* Get the Order and Line Information */

Line 291: RAISE FND_API.G_EXC_ERROR;

287: CLOSE get_so_line_rec;
288: IF (g_debug <= gme_debug.g_log_statement) THEN
289: gme_debug.put_line(g_pkg_name||'.'||l_api_name||'RETURNING - sales order not found for for line_id '||p_so_line_id);
290: END IF;
291: RAISE FND_API.G_EXC_ERROR;
292: END IF;
293: CLOSE get_so_line_rec;
294:
295: /* ============== Establish Item Characteristics ====================*/

Line 308: RAISE FND_API.G_EXC_ERROR;

304: FND_FILE.Put_Line(FND_FILE.LOG,'Failure to retrieve inventory item'); -- Bug 13359707
305: IF (g_debug <= gme_debug.g_log_statement) THEN
306: gme_debug.put_line(g_pkg_name||'.'||l_api_name||'Failure to retrieve inventory item ');
307: END IF;
308: RAISE FND_API.G_EXC_ERROR;
309: END IF;
310: CLOSE cur_item;
311:
312: /* ============== Determine whether Make to Order Rule exists ===============*/

Line 337: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) THEN

333: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Rule ID to work with is '||l_mto_assignments_rec.rule_id);
334: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Rule being honored is '||l_mto_rules_rec.rule_name);
335: END IF;
336:
337: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) THEN
338: FND_FILE.Put_Line(FND_FILE.LOG,' Failure to Get_Rule so terminate processing for order '||l_order_no); -- Bug 13359707
339: FND_FILE.Put_Line(FND_FILE.LOG,' Failure to Get_Rule so terminate processing for line '||l_so_line_no); -- Bug 13359707
340: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Failure to Get_Rule so terminate processing for line '||p_so_line_id);
341: FND_MESSAGE.Set_Name('GMI','Missing');

Line 344: RAISE FND_API.G_EXC_ERROR;

340: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Failure to Get_Rule so terminate processing for line '||p_so_line_id);
341: FND_MESSAGE.Set_Name('GMI','Missing');
342: FND_MESSAGE.Set_Token('MISSING', 'rule_id');
343: FND_MSG_PUB.Add;
344: RAISE FND_API.G_EXC_ERROR;
345: END IF;
346:
347: IF (NVL(l_mto_rules_rec.rule_id,0) = 0) THEN
348: FND_FILE.Put_Line(FND_FILE.LOG,' No MAKE to ORDER rule exists to cover order '||l_order_no); -- Bug 13359707

Line 408: IF x_return_status <> fnd_api.g_ret_sts_success THEN

404: || ' Return status from relieve_reservation is '
405: || x_return_status);
406: END IF;
407:
408: IF x_return_status <> fnd_api.g_ret_sts_success THEN
409: RAISE FND_API.G_EXC_ERROR;
410: END IF;
411: l_count := l_count + 1;
412: END LOOP;

Line 409: RAISE FND_API.G_EXC_ERROR;

405: || x_return_status);
406: END IF;
407:
408: IF x_return_status <> fnd_api.g_ret_sts_success THEN
409: RAISE FND_API.G_EXC_ERROR;
410: END IF;
411: l_count := l_count + 1;
412: END LOOP;
413: END IF;

Line 485: , p_init_msg_lst => fnd_api.g_true

481:
482: inv_quantity_tree_pvt.create_tree
483: (
484: p_api_version_number => 1.0
485: , p_init_msg_lst => fnd_api.g_true
486: , x_return_status => l_return_status
487: , x_msg_count => x_msg_count
488: , x_msg_data => x_msg_data
489: , p_organization_id => l_so_line_rec.ship_from_org_id

Line 510: IF l_return_status = fnd_api.g_ret_sts_error THEN

506: IF (g_debug <= gme_debug.g_log_statement) THEN
507: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' After create tree status returned is '||l_return_status);
508: END IF;
509:
510: IF l_return_status = fnd_api.g_ret_sts_error THEN
511: RAISE fnd_api.g_exc_error;
512: END IF;
513:
514: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 511: RAISE fnd_api.g_exc_error;

507: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' After create tree status returned is '||l_return_status);
508: END IF;
509:
510: IF l_return_status = fnd_api.g_ret_sts_error THEN
511: RAISE fnd_api.g_exc_error;
512: END IF;
513:
514: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
515: RAISE fnd_api.g_exc_unexpected_error;

Line 514: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

510: IF l_return_status = fnd_api.g_ret_sts_error THEN
511: RAISE fnd_api.g_exc_error;
512: END IF;
513:
514: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
515: RAISE fnd_api.g_exc_unexpected_error;
516: END IF;
517:
518: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 515: RAISE fnd_api.g_exc_unexpected_error;

511: RAISE fnd_api.g_exc_error;
512: END IF;
513:
514: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
515: RAISE fnd_api.g_exc_unexpected_error;
516: END IF;
517:
518: IF (g_debug <= gme_debug.g_log_statement) THEN
519: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Query tree for ATR next ');

Line 523: , p_init_msg_lst => fnd_api.g_true

519: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Query tree for ATR next ');
520: END IF;
521: inv_quantity_tree_pvt.query_tree(
522: p_api_version_number => 1.0
523: , p_init_msg_lst => fnd_api.g_true
524: , x_return_status => l_return_status
525: , x_msg_count => l_msg_count
526: , x_msg_data => l_msg_data
527: , p_tree_id => l_tree_id

Line 550: IF l_return_status = fnd_api.g_ret_sts_error THEN

546:
547: IF (g_debug <= gme_debug.g_log_statement) THEN
548: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' After Query tree return status is '||l_return_status);
549: END IF;
550: IF l_return_status = fnd_api.g_ret_sts_error THEN
551: RAISE fnd_api.g_exc_error;
552: END IF;
553:
554: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

Line 551: RAISE fnd_api.g_exc_error;

547: IF (g_debug <= gme_debug.g_log_statement) THEN
548: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' After Query tree return status is '||l_return_status);
549: END IF;
550: IF l_return_status = fnd_api.g_ret_sts_error THEN
551: RAISE fnd_api.g_exc_error;
552: END IF;
553:
554: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
555: RAISE fnd_api.g_exc_unexpected_error;

Line 554: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

550: IF l_return_status = fnd_api.g_ret_sts_error THEN
551: RAISE fnd_api.g_exc_error;
552: END IF;
553:
554: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
555: RAISE fnd_api.g_exc_unexpected_error;
556: END IF;
557:
558: IF (g_debug <= gme_debug.g_log_statement) THEN

Line 555: RAISE fnd_api.g_exc_unexpected_error;

551: RAISE fnd_api.g_exc_error;
552: END IF;
553:
554: IF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
555: RAISE fnd_api.g_exc_unexpected_error;
556: END IF;
557:
558: IF (g_debug <= gme_debug.g_log_statement) THEN
559: gme_debug.put_line('l_atr ' || l_atr);

Line 682: p_init_msg_list => fnd_api.g_true,

678: END IF;
679: GME_API_PUB.create_batch(
680: p_api_version => 2.0,
681: p_validation_level => 100,
682: p_init_msg_list => fnd_api.g_true,
683: p_commit => fnd_api.g_false,
684: x_message_count => l_msg_count,
685: x_message_list => l_msg_data,
686: x_return_status => l_return_status,

Line 683: p_commit => fnd_api.g_false,

679: GME_API_PUB.create_batch(
680: p_api_version => 2.0,
681: p_validation_level => 100,
682: p_init_msg_list => fnd_api.g_true,
683: p_commit => fnd_api.g_false,
684: x_message_count => l_msg_count,
685: x_message_list => l_msg_data,
686: x_return_status => l_return_status,
687: p_org_code => NULL,

Line 699: p_ignore_qty_below_cap => fnd_api.g_true,

695: p_recipe_version => NULL,
696: p_product_no => NULL,
697: p_item_revision => NULL,
698: p_product_id => l_so_line_rec.inventory_item_id,
699: p_ignore_qty_below_cap => fnd_api.g_true,
700: p_use_workday_cal => NULL,
701: p_contiguity_override => NULL,
702: p_use_least_cost_validity_rule => fnd_api.g_false,
703: x_exception_material_tbl => l_exception_material_tbl

Line 702: p_use_least_cost_validity_rule => fnd_api.g_false,

698: p_product_id => l_so_line_rec.inventory_item_id,
699: p_ignore_qty_below_cap => fnd_api.g_true,
700: p_use_workday_cal => NULL,
701: p_contiguity_override => NULL,
702: p_use_least_cost_validity_rule => fnd_api.g_false,
703: x_exception_material_tbl => l_exception_material_tbl
704: );
705:
706: FND_FILE.Put_Line(FND_FILE.LOG,' After calling GME_API_PUB.create_batch for order '||l_order_no || 'and line_no ' || l_so_line_no); -- Bug 13359707

Line 720: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS AND l_return_status <> 'V' ) THEN

716: END IF;
717: /*Bug#8367071 Added the inventory shortage condition here so that the
718: * code proceeds thorugh the resevation etc even when there is material shortage
719: * in the batch */
720: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS AND l_return_status <> 'V' ) THEN
721: j := to_number(NVL(l_msg_count,0));
722: FOR i in 1..j
723: LOOP
724:

Line 725: l_message := fnd_msg_pub.get(p_encoded => FND_API.G_FALSE);

721: j := to_number(NVL(l_msg_count,0));
722: FOR i in 1..j
723: LOOP
724:
725: l_message := fnd_msg_pub.get(p_encoded => FND_API.G_FALSE);
726: l_message := replace(l_message, chr(0), ' ');
727: gme_debug.put_line(l_message);
728: END LOOP;
729: RAISE fnd_api.g_exc_error;

Line 729: RAISE fnd_api.g_exc_error;

725: l_message := fnd_msg_pub.get(p_encoded => FND_API.G_FALSE);
726: l_message := replace(l_message, chr(0), ' ');
727: gme_debug.put_line(l_message);
728: END LOOP;
729: RAISE fnd_api.g_exc_error;
730: END IF;
731:
732: /* Now retrieve the batch product line - sales order line must reserve to this supply
733: ===================================================================================*/

Line 745: RAISE fnd_api.g_exc_error;

741: CLOSE get_batch_line;
742: IF (g_debug <= gme_debug.g_log_statement) THEN
743: gme_debug.put_line('get_batch_line%NOTFOUND, returning from create_batch_for_order_line');
744: END IF;
745: RAISE fnd_api.g_exc_error;
746: END IF;
747: CLOSE get_batch_line;
748:
749: /* Copy Attachments if the rule says so

Line 802: ,p_init_msg_list => fnd_api.g_false

798:
799: GME_API_PUB.create_pending_product_lot
800: (p_api_version => 2.0
801: ,p_validation_level => gme_common_pvt.g_max_errors
802: ,p_init_msg_list => fnd_api.g_false
803: ,p_commit => fnd_api.g_false
804: ,x_message_count => l_msg_count
805: ,x_message_list => l_msg_data
806: ,x_return_status => l_return_status

Line 803: ,p_commit => fnd_api.g_false

799: GME_API_PUB.create_pending_product_lot
800: (p_api_version => 2.0
801: ,p_validation_level => gme_common_pvt.g_max_errors
802: ,p_init_msg_list => fnd_api.g_false
803: ,p_commit => fnd_api.g_false
804: ,x_message_count => l_msg_count
805: ,x_message_list => l_msg_data
806: ,x_return_status => l_return_status
807: ,p_batch_header_rec => l_out_batch_header_rec

Line 809: ,p_create_lot => fnd_api.g_true

805: ,x_message_list => l_msg_data
806: ,x_return_status => l_return_status
807: ,p_batch_header_rec => l_out_batch_header_rec
808: ,p_org_code => NULL
809: ,p_create_lot => fnd_api.g_true
810: ,p_generate_lot => fnd_api.g_true
811: ,p_material_detail_rec => l_material_detail_rec
812: ,p_pending_product_lots_rec => l_pending_product_lots_rec
813: ,x_pending_product_lots_rec => l_out_pending_product_lots_rec);

Line 810: ,p_generate_lot => fnd_api.g_true

806: ,x_return_status => l_return_status
807: ,p_batch_header_rec => l_out_batch_header_rec
808: ,p_org_code => NULL
809: ,p_create_lot => fnd_api.g_true
810: ,p_generate_lot => fnd_api.g_true
811: ,p_material_detail_rec => l_material_detail_rec
812: ,p_pending_product_lots_rec => l_pending_product_lots_rec
813: ,x_pending_product_lots_rec => l_out_pending_product_lots_rec);
814:

Line 815: IF (l_return_status <> FND_API.G_RET_STS_SUCCESS) THEN

811: ,p_material_detail_rec => l_material_detail_rec
812: ,p_pending_product_lots_rec => l_pending_product_lots_rec
813: ,x_pending_product_lots_rec => l_out_pending_product_lots_rec);
814:
815: IF (l_return_status <> FND_API.G_RET_STS_SUCCESS) THEN
816:
817: FND_FILE.Put_Line(FND_FILE.LOG,' After calling GME_API_PUB.create_pending_product_lot for '||l_order_no || 'and line_no ' || l_so_line_no); -- Bug 13359707
818: FND_FILE.Put_Line(FND_FILE.LOG,' Return Status from create_pending_product_lot is '||l_return_status); -- Bug 13359707
819: FND_FILE.Put_Line(FND_FILE.LOG,' FAILURE to generate pending lot'); -- Bug 13359707

Line 864: ,p_init_msg_lst => fnd_api.g_false

860: END IF;
861:
862: inv_reservation_pub.create_reservation
863: (p_api_version_number => 1.0
864: ,p_init_msg_lst => fnd_api.g_false
865: ,x_return_status => l_return_status
866: ,x_msg_count => l_msg_count
867: ,x_msg_data => l_msg_data
868: ,p_rsv_rec => l_rsv_rec

Line 871: ,p_partial_reservation_flag => fnd_api.g_true

867: ,x_msg_data => l_msg_data
868: ,p_rsv_rec => l_rsv_rec
869: ,p_serial_number => l_in_serial_num
870: ,x_serial_number => l_out_serial_num
871: ,p_partial_reservation_flag => fnd_api.g_true
872: ,p_validation_flag => fnd_api.g_true
873: ,x_quantity_reserved => l_reserved_qty
874: ,x_reservation_id => l_reservation_id
875: ,p_partial_rsv_exists => TRUE);

Line 872: ,p_validation_flag => fnd_api.g_true

868: ,p_rsv_rec => l_rsv_rec
869: ,p_serial_number => l_in_serial_num
870: ,x_serial_number => l_out_serial_num
871: ,p_partial_reservation_flag => fnd_api.g_true
872: ,p_validation_flag => fnd_api.g_true
873: ,x_quantity_reserved => l_reserved_qty
874: ,x_reservation_id => l_reservation_id
875: ,p_partial_rsv_exists => TRUE);
876:

Line 893: (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) ) THEN

889: || l_reserved_qty );
890: END IF;
891:
892: IF (l_return_status IN
893: (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) ) THEN
894: RAISE FND_API.G_EXC_ERROR;
895: END IF;
896:
897: /* Notify the customer sales representative of the batch creation

Line 894: RAISE FND_API.G_EXC_ERROR;

890: END IF;
891:
892: IF (l_return_status IN
893: (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) ) THEN
894: RAISE FND_API.G_EXC_ERROR;
895: END IF;
896:
897: /* Notify the customer sales representative of the batch creation
898: ===============================================================*/

Line 927: IF l_return_status IN (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) THEN

923: || ' after calling notify_CSR for create reservation status is '
924: || l_return_status );
925: END IF;
926:
927: IF l_return_status IN (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) THEN
928: IF g_debug <= gme_debug.g_log_procedure THEN
929: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Exit after Notifications Failure ');
930: END IF;
931: RAISE FND_API.G_EXC_ERROR;

Line 931: RAISE FND_API.G_EXC_ERROR;

927: IF l_return_status IN (fnd_api.g_ret_sts_error, fnd_api.g_ret_sts_unexp_error) THEN
928: IF g_debug <= gme_debug.g_log_procedure THEN
929: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Exit after Notifications Failure ');
930: END IF;
931: RAISE FND_API.G_EXC_ERROR;
932: END IF;
933:
934: /* Set the user context back to the original user */
935: IF (l_mto_rules_rec.batch_creation_user <> l_user_id) THEN

Line 971: WHEN FND_API.G_EXC_ERROR THEN

967:
968: /* EXCEPTION HANDLING
969: ====================*/
970: EXCEPTION
971: WHEN FND_API.G_EXC_ERROR THEN
972: -- ROLLBACK TO SAVEPOINT create_batch_for_so_line_SP;
973: gme_debug.put_line('sqlcode : ' ||to_char(sqlcode));
974: gme_debug.put_line('sqlerr : '|| SUBSTRB(SQLERRM, 1, 150));
975: x_return_status := FND_API.G_RET_STS_ERROR;

Line 975: x_return_status := FND_API.G_RET_STS_ERROR;

971: WHEN FND_API.G_EXC_ERROR THEN
972: -- ROLLBACK TO SAVEPOINT create_batch_for_so_line_SP;
973: gme_debug.put_line('sqlcode : ' ||to_char(sqlcode));
974: gme_debug.put_line('sqlerr : '|| SUBSTRB(SQLERRM, 1, 150));
975: x_return_status := FND_API.G_RET_STS_ERROR;
976: -- errbuf := SUBSTRB(SQLERRM, 1, 150);
977: -- retcode := x_return_status;
978:
979: FND_MSG_PUB.Add_Exc_Msg ( g_pkg_name

Line 982: FND_MSG_PUB.Count_AND_GET ( p_encoded => FND_API.G_FALSE

978:
979: FND_MSG_PUB.Add_Exc_Msg ( g_pkg_name
980: , l_api_name
981: );
982: FND_MSG_PUB.Count_AND_GET ( p_encoded => FND_API.G_FALSE
983: , p_count => x_msg_count
984: , p_data => x_msg_data
985: );
986:

Line 987: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN

983: , p_count => x_msg_count
984: , p_data => x_msg_data
985: );
986:
987: WHEN FND_API.G_EXC_UNEXPECTED_ERROR THEN
988: -- ROLLBACK TO SAVEPOINT create_batch_for_so_line_SP;
989: gme_debug.put_line('sqlcode : ' ||to_char(sqlcode));
990: gme_debug.put_line('sqlerr : '|| SUBSTRB(SQLERRM, 1, 150));
991:

Line 992: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

988: -- ROLLBACK TO SAVEPOINT create_batch_for_so_line_SP;
989: gme_debug.put_line('sqlcode : ' ||to_char(sqlcode));
990: gme_debug.put_line('sqlerr : '|| SUBSTRB(SQLERRM, 1, 150));
991:
992: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
993: -- errbuf := SUBSTRB(SQLERRM, 1, 150);
994: -- retcode := x_return_status;
995:
996:

Line 1000: FND_MSG_PUB.Count_AND_GET ( p_encoded=> FND_API.G_FALSE

996:
997: FND_MSG_PUB.Add_Exc_Msg ( g_pkg_name
998: , l_api_name
999: );
1000: FND_MSG_PUB.Count_AND_GET ( p_encoded=> FND_API.G_FALSE
1001: , p_count => x_msg_count
1002: , p_data => x_msg_data
1003: );
1004: WHEN OTHERS THEN

Line 1013: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;

1009: FND_MSG_PUB.Add_Exc_Msg ( g_pkg_name
1010: , l_api_name
1011: );
1012:
1013: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR;
1014: -- errbuf := SUBSTRB(SQLERRM, 1, 150);
1015: -- retcode := x_return_status;
1016:
1017: /* Get message count and data */

Line 1118: x_return_status := FND_API.G_RET_STS_SUCCESS;

1114: , X_doc_attribute14 => so_attchments_row.DOC_ATTRIBUTE14
1115: , X_doc_attribute15 => so_attchments_row.DOC_ATTRIBUTE15
1116: , X_create_doc => 'Y' --- Default is 'N'
1117: );
1118: x_return_status := FND_API.G_RET_STS_SUCCESS;
1119: END LOOP;
1120:
1121: gme_debug.put_line('Exiting copy_attachments procedure without any errors');
1122: EXCEPTION

Line 1125: x_return_status := FND_API.G_RET_STS_ERROR;

1121: gme_debug.put_line('Exiting copy_attachments procedure without any errors');
1122: EXCEPTION
1123: WHEN OTHERS THEN
1124: GMI_RESERVATION_UTIL.Println('In others exception in copy_attachments');
1125: x_return_status := FND_API.G_RET_STS_ERROR;
1126: END Copy_attachments;
1127:
1128: FUNCTION line_qualifies_for_MTO (
1129: p_line_id IN NUMBER

Line 1210: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) or (NVL(l_mto_assignments_rec.rule_id,0) = 0) THEN

1206: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Rule ID to work with is '||l_mto_assignments_rec.rule_id);
1207: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' Rule being honored is '||l_mto_rules_rec.rule_name);
1208: END IF;
1209:
1210: IF( l_return_status <> FND_API.G_RET_STS_SUCCESS ) or (NVL(l_mto_assignments_rec.rule_id,0) = 0) THEN
1211: Return FALSE;
1212: ELSE
1213: Return TRUE;
1214: END IF;

Line 1270: x_return_status := FND_API.G_RET_STS_SUCCESS;

1266: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' item_type '||p_mto_assignments_rec.item_type);
1267: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' customer_id '||p_mto_assignments_rec.customer_id);
1268: gme_debug.put_line(g_pkg_name||'.'||l_api_name||' site_use_id '||p_mto_assignments_rec.site_use_id);
1269: END IF;
1270: x_return_status := FND_API.G_RET_STS_SUCCESS;
1271: /* get the most suitable rule first */
1272: GMI_reservation_Util.PrintLn('IN check Rule');
1273: Open get_assignment;
1274: Fetch get_assignment

Line 1296: RAISE FND_API.G_EXC_ERROR;

1292: Fetch get_rule into l_mto_rules_rec;
1293: IF(get_rule%NOTFOUND) THEN
1294: CLOSE get_rule;
1295: gme_debug.put_line('Error encountered on rule retrieval for Rule ID '||l_mto_assignments_rec.rule_id);
1296: RAISE FND_API.G_EXC_ERROR;
1297: END IF;
1298: Close get_rule;
1299:
1300: x_mto_rules_rec := l_mto_rules_rec;