DBA Data[Home] [Help]

APPS.INV_PICK_RELEASE_PVT dependencies on FND_API

Line 180: x_return_status := fnd_api.g_ret_sts_error;

176: OPEN c_mo_type;
177: FETCH c_mo_type
178: INTO l_move_order_type;
179: IF NOT c_mo_type%FOUND THEN
180: x_return_status := fnd_api.g_ret_sts_error;
181: IF is_debug THEN
182: print_debug('Move Order Line not found ' || p_mo_line_id,'INV_PICK_RELEASE_PVT.GET_TOLERANCE');
183: END IF;
184: END IF;

Line 204: x_return_status := fnd_api.g_ret_sts_error;

200: FETCH c_detail_info INTO l_detail_info;
201: --l_found_flag := c_detail_info%FOUND;
202:
203: IF NOT c_detail_info%FOUND THEN
204: x_return_status := fnd_api.g_ret_sts_error;
205: IF is_debug THEN
206: print_debug('Delivery Detail not found ' || p_mo_line_id,'INV_PICK_RELEASE_PVT.GET_TOLERANCE');
207: END IF;
208: ELSE

Line 358: x_api_status := fnd_api.g_ret_sts_success;

354: , p_revision VARCHAR2 DEFAULT NULL
355: ) IS
356: p_pr_mode BOOLEAN := WSH_PICK_LIST.G_PICK_REL_PARALLEL;
357: BEGIN
358: x_api_status := fnd_api.g_ret_sts_success;
359: -- Bug 2666620:
360: -- If the Patchset Level of Shipping is less than 'I' then call
361: -- Shipping's GET_PICK_SLIP_NUMBER.
362: -- Otherwise calls Inventory's GET_PICK_SLIP_NUMBER

Line 464: , p_allow_partial_pick IN VARCHAR2 DEFAULT fnd_api.g_true

460: , p_mo_line_rec IN inv_move_order_pub.trolin_rec_type
461: , p_mso_line_id IN NUMBER
462: , p_demand_source_type IN VARCHAR2
463: , p_demand_source_name IN VARCHAR2
464: , p_allow_partial_pick IN VARCHAR2 DEFAULT fnd_api.g_true
465: , x_demand_rsvs_ordered OUT NOCOPY inv_reservation_global.mtl_reservation_tbl_type
466: , x_rsv_qty_available OUT NOCOPY NUMBER
467: , x_rsv_qty2_available OUT NOCOPY NUMBER
468: ) IS

Line 627: l_qry_rsv_rec.demand_source_header_id := nvl(p_mso_line_id,fnd_api.g_miss_num);

623:
624: l_qry_rsv_rec.organization_id := p_mo_line_rec.organization_id;
625: l_qry_rsv_rec.inventory_item_id := p_mo_line_rec.inventory_item_id;
626: l_qry_rsv_rec.demand_source_type_id := p_demand_source_type;
627: l_qry_rsv_rec.demand_source_header_id := nvl(p_mso_line_id,fnd_api.g_miss_num);
628: l_qry_rsv_rec.demand_source_line_id := p_demand_info.oe_line_id;
629: l_qry_rsv_rec.demand_source_name := nvl(p_demand_source_name,fnd_api.g_miss_char);
630: l_qry_rsv_rec.supply_source_type_id := inv_reservation_global.g_source_type_inv;
631: inv_reservation_pub.query_reservation(

Line 629: l_qry_rsv_rec.demand_source_name := nvl(p_demand_source_name,fnd_api.g_miss_char);

625: l_qry_rsv_rec.inventory_item_id := p_mo_line_rec.inventory_item_id;
626: l_qry_rsv_rec.demand_source_type_id := p_demand_source_type;
627: l_qry_rsv_rec.demand_source_header_id := nvl(p_mso_line_id,fnd_api.g_miss_num);
628: l_qry_rsv_rec.demand_source_line_id := p_demand_info.oe_line_id;
629: l_qry_rsv_rec.demand_source_name := nvl(p_demand_source_name,fnd_api.g_miss_char);
630: l_qry_rsv_rec.supply_source_type_id := inv_reservation_global.g_source_type_inv;
631: inv_reservation_pub.query_reservation(
632: p_api_version_number => 1.0
633: , p_init_msg_lst => fnd_api.g_false

Line 633: , p_init_msg_lst => fnd_api.g_false

629: l_qry_rsv_rec.demand_source_name := nvl(p_demand_source_name,fnd_api.g_miss_char);
630: l_qry_rsv_rec.supply_source_type_id := inv_reservation_global.g_source_type_inv;
631: inv_reservation_pub.query_reservation(
632: p_api_version_number => 1.0
633: , p_init_msg_lst => fnd_api.g_false
634: , x_return_status => l_api_return_status
635: , x_msg_count => x_msg_count
636: , x_msg_data => x_msg_data
637: , p_query_input => l_qry_rsv_rec

Line 645: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

641: , x_error_code => l_api_error_code
642: );
643:
644: -- Return an error if the query reservations call failed
645: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
646: IF (is_debug) THEN
647: print_debug('return error from query reservation: '||l_api_return_status,'INV_Pick_Release_PVT.Process_Reservations');
648: END IF;
649: fnd_message.set_name('INV', 'INV_QRY_RSV_FAILED');

Line 651: RAISE fnd_api.g_exc_unexpected_error;

647: print_debug('return error from query reservation: '||l_api_return_status,'INV_Pick_Release_PVT.Process_Reservations');
648: END IF;
649: fnd_message.set_name('INV', 'INV_QRY_RSV_FAILED');
650: fnd_msg_pub.ADD;
651: RAISE fnd_api.g_exc_unexpected_error;
652: END IF;
653:
654: IF (is_debug) THEN
655: print_debug('Unstaged l_non_inv_reservations_qty '|| l_non_inv_reservations_qty,'Inv_Pick_Release_PVT.Process_Reservations');

Line 668: RAISE fnd_api.g_exc_unexpected_error;

664: If NOT l_return_value Then
665: if is_debug then
666: print_debug('Error setting from sub cache','Inv_Pick_Release_PVT.Process_Reservations');
667: end if;
668: RAISE fnd_api.g_exc_unexpected_error;
669: End If;
670: g_sub_reservable_type := INV_CACHE.fromsub_rec.reservable_type;
671: ELSE
672: g_sub_reservable_type := 1;

Line 756: RAISE fnd_api.g_exc_unexpected_error;

752: if is_debug then
753: print_debug('Error setting from sub cache',
754: 'Inv_Pick_Release_PVT.Process_Reservations');
755: end if;
756: RAISE fnd_api.g_exc_unexpected_error;
757: End If;
758:
759: l_primary_uom:= INV_CACHE.item_rec.primary_uom_code;
760: l_secondary_uom:= INV_CACHE.item_rec.secondary_uom_code;

Line 790: RAISE fnd_api.g_exc_unexpected_error;

786: fnd_message.set_name('INV', 'INV-CANNOT CONVERT');
787: fnd_message.set_token('UOM', l_primary_uom);
788: fnd_message.set_token('ROUTINE', 'Pick Release process');
789: fnd_msg_pub.ADD;
790: RAISE fnd_api.g_exc_unexpected_error;
791: END IF;
792: ELSE
793: l_quantity_to_detail := l_qty_to_detail_unconv;
794: END IF;

Line 839: RAISE fnd_api.g_exc_unexpected_error;

835: IF NOT l_return_value Then
836: IF (is_debug) THEN
837: print_debug('Error setting cache for order line', 'Inv_Pick_Release_PVT.Process_Reservations');
838: END IF;
839: RAISE fnd_api.g_exc_unexpected_error;
840: END IF;
841:
842: l_order_line_qty_unconv := INV_CACHE.oola_rec.ordered_quantity;
843: l_order_line_uom := INV_CACHE.oola_rec.order_quantity_uom;

Line 869: RAISE fnd_api.g_exc_unexpected_error;

865: fnd_message.set_name('INV', 'INV-CANNOT CONVERT');
866: fnd_message.set_token('UOM', l_primary_uom);
867: fnd_message.set_token('ROUTINE', 'Pick Release process');
868: fnd_msg_pub.ADD;
869: RAISE fnd_api.g_exc_unexpected_error;
870: END IF;
871: ELSE
872: l_order_line_qty := l_order_line_qty_unconv;
873: END IF;

Line 920: , p_init_msg_lst => fnd_api.g_false

916: -- shouldn't appear as available
917: -- Added following secondary qty related section for Bug 7377744
918: inv_quantity_tree_pub.query_quantities(
919: p_api_version_number => 1.0
920: , p_init_msg_lst => fnd_api.g_false
921: , x_return_status => l_api_return_status
922: , x_msg_count => x_msg_count
923: , x_msg_data => x_msg_data
924: , p_organization_id => p_mo_line_rec.organization_id

Line 958: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

954: IF (is_debug) THEN
955: print_debug('Reservable qty from qtytree'|| l_qty_available_to_reserve, 'Inv_Pick_Release_PVT.Process_Reservations');
956: END IF;
957:
958: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
959: IF (is_debug) THEN
960: print_debug('Error from query quantity tree', 'Inv_Pick_Release_PVT.Process_Reservations');
961: END IF;
962: fnd_message.set_name('INV', 'INV_QRY_QTY_FAILED');

Line 964: RAISE fnd_api.g_exc_unexpected_error;

960: print_debug('Error from query quantity tree', 'Inv_Pick_Release_PVT.Process_Reservations');
961: END IF;
962: fnd_message.set_name('INV', 'INV_QRY_QTY_FAILED');
963: fnd_msg_pub.ADD;
964: RAISE fnd_api.g_exc_unexpected_error;
965: END IF;
966:
967: l_quantity_to_reserve := l_unreserved_quantity;
968: l_sec_quantity_to_reserve := l_sec_unreserved_quantity;

Line 999: , p_init_msg_lst => fnd_api.g_false

995: print_debug('update reservation', 'Inv_Pick_Release_PVT.Process_Reservations');
996: END IF;
997: inv_reservation_pub.update_reservation(
998: p_api_version_number => 1.0
999: , p_init_msg_lst => fnd_api.g_false
1000: , x_return_status => l_api_return_status
1001: , x_msg_count => x_msg_count
1002: , x_msg_data => x_msg_data
1003: , p_original_rsv_rec => l_qry_rsv_rec

Line 1007: , p_validation_flag => fnd_api.g_true

1003: , p_original_rsv_rec => l_qry_rsv_rec
1004: , p_to_rsv_rec => l_update_rsv_rec
1005: , p_original_serial_number => l_dummy_sn
1006: , p_to_serial_number => l_dummy_sn
1007: , p_validation_flag => fnd_api.g_true
1008: );
1009:
1010: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
1011: IF (is_debug) THEN

Line 1010: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

1006: , p_to_serial_number => l_dummy_sn
1007: , p_validation_flag => fnd_api.g_true
1008: );
1009:
1010: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
1011: IF (is_debug) THEN
1012: print_debug('error in update reservation', 'Inv_Pick_Release_PVT.Process_Reservations');
1013: END IF;
1014: fnd_message.set_name('INV', 'INV_UPD_RSV_FAILED');

Line 1016: RAISE fnd_api.g_exc_unexpected_error;

1012: print_debug('error in update reservation', 'Inv_Pick_Release_PVT.Process_Reservations');
1013: END IF;
1014: fnd_message.set_name('INV', 'INV_UPD_RSV_FAILED');
1015: fnd_msg_pub.ADD;
1016: RAISE fnd_api.g_exc_unexpected_error;
1017: ELSE
1018: --Requery the reservation record and update it in the local table.
1019: IF (is_debug) THEN
1020: print_debug('query that reservation again',

Line 1026: , p_init_msg_lst => fnd_api.g_true

1022: END IF;
1023: l_qry_rsv_rec_by_id.reservation_id := l_update_rsv_rec.reservation_id;
1024: inv_reservation_pub.query_reservation(
1025: p_api_version_number => 1.0
1026: , p_init_msg_lst => fnd_api.g_true
1027: , x_return_status => l_api_return_status
1028: , x_msg_count => x_msg_count
1029: , x_msg_data => x_msg_data
1030: , p_query_input => l_qry_rsv_rec_by_id

Line 1037: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

1033: , x_error_code => l_api_error_code
1034: );
1035:
1036: -- Return an error if the query reservations call failed
1037: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
1038: fnd_message.set_name('INV', 'INV_QRY_RSV_FAILED');
1039: fnd_msg_pub.ADD;
1040: RAISE fnd_api.g_exc_unexpected_error;
1041: END IF;

Line 1040: RAISE fnd_api.g_exc_unexpected_error;

1036: -- Return an error if the query reservations call failed
1037: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
1038: fnd_message.set_name('INV', 'INV_QRY_RSV_FAILED');
1039: fnd_msg_pub.ADD;
1040: RAISE fnd_api.g_exc_unexpected_error;
1041: END IF;
1042:
1043: l_res_tbl_index := l_demand_reservations.FIRST;
1044: l_demand_rsvs_ordered(l_res_ordered_index) := l_demand_reservations(l_res_tbl_index);

Line 1056: , p_init_msg_lst => fnd_api.g_false

1052:
1053: -- Added following secondary qty related section for Bug 7377744
1054: inv_quantity_tree_pub.update_quantities(
1055: p_api_version_number => 1.0
1056: , p_init_msg_lst => fnd_api.g_false
1057: , x_return_status => l_api_return_status
1058: , x_msg_count => x_msg_count
1059: , x_msg_data => x_msg_data
1060: , p_organization_id => p_mo_line_rec.organization_id

Line 1094: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

1090: , x_sqs => l_sec_qty_sug
1091: , x_satt => l_sec_qty_att
1092: , x_satr => l_sec_qty_available_to_reserve
1093: );
1094: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
1095: IF (is_debug) THEN
1096: print_debug('Error from query quantity tree', 'Inv_Pick_Release_PVT.Process_Reservations');
1097: END IF;
1098: fnd_message.set_name('INV', 'INV_QRY_QTY_FAILED');

Line 1100: RAISE fnd_api.g_exc_unexpected_error;

1096: print_debug('Error from query quantity tree', 'Inv_Pick_Release_PVT.Process_Reservations');
1097: END IF;
1098: fnd_message.set_name('INV', 'INV_QRY_QTY_FAILED');
1099: fnd_msg_pub.ADD;
1100: RAISE fnd_api.g_exc_unexpected_error;
1101: END IF;
1102:
1103: --find new reservation quantities
1104: l_index := l_demand_rsvs_ordered.LAST;

Line 1139: RAISE fnd_api.g_exc_unexpected_error;

1135: fnd_message.set_name('INV', 'INV-CANNOT CONVERT');
1136: fnd_message.set_token('UOM', l_primary_uom);
1137: fnd_message.set_token('ROUTINE', 'Pick Release process');
1138: fnd_msg_pub.ADD;
1139: RAISE fnd_api.g_exc_unexpected_error;
1140: END IF;
1141: END IF;
1142: IF (is_debug) THEN
1143: print_debug('New prim rsv qty: ' || l_new_prim_rsv_quantity, 'Inv_Pick_Release_PVT.Process_Reservations');

Line 1160: IF l_api_return_status = fnd_api.g_ret_sts_error THEN

1156: , x_return_status => l_api_return_status
1157: , x_msg_count => x_msg_count
1158: , x_msg_data => x_msg_data);
1159:
1160: IF l_api_return_status = fnd_api.g_ret_sts_error THEN
1161: IF (is_debug) THEN
1162: print_debug('Error from inv_rsv_synch.for_update', 'Inv_Pick_Release_PVT.Process_Reservations');
1163: END IF;
1164: RAISE fnd_api.g_exc_error;

Line 1164: RAISE fnd_api.g_exc_error;

1160: IF l_api_return_status = fnd_api.g_ret_sts_error THEN
1161: IF (is_debug) THEN
1162: print_debug('Error from inv_rsv_synch.for_update', 'Inv_Pick_Release_PVT.Process_Reservations');
1163: END IF;
1164: RAISE fnd_api.g_exc_error;
1165: END IF;
1166: --
1167: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
1168: IF (is_debug) THEN

Line 1167: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN

1163: END IF;
1164: RAISE fnd_api.g_exc_error;
1165: END IF;
1166: --
1167: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
1168: IF (is_debug) THEN
1169: print_debug('Unexp. error from inv_rsv_synch.for_update', 'Inv_Pick_Release_PVT.Process_Reservations');
1170: END IF;
1171: RAISE fnd_api.g_exc_unexpected_error;

Line 1171: RAISE fnd_api.g_exc_unexpected_error;

1167: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
1168: IF (is_debug) THEN
1169: print_debug('Unexp. error from inv_rsv_synch.for_update', 'Inv_Pick_Release_PVT.Process_Reservations');
1170: END IF;
1171: RAISE fnd_api.g_exc_unexpected_error;
1172: END IF;
1173:
1174: l_demand_rsvs_ordered(l_index).primary_reservation_quantity := l_new_prim_rsv_quantity;
1175: l_demand_rsvs_ordered(l_index).secondary_reservation_quantity := l_new_sec_rsv_quantity;

Line 1244: , p_init_msg_lst => fnd_api.g_false

1240: print_debug('create new reservation', 'Inv_Pick_Release_PVT.Process_Reservations');
1241: END IF;
1242: inv_reservation_pub.create_reservation(
1243: p_api_version_number => 1.0
1244: , p_init_msg_lst => fnd_api.g_false
1245: , x_return_status => l_api_return_status
1246: , x_msg_count => x_msg_count
1247: , x_msg_data => x_msg_data
1248: , p_rsv_rec => l_update_rsv_rec

Line 1251: , p_partial_reservation_flag => fnd_api.g_true

1247: , x_msg_data => x_msg_data
1248: , p_rsv_rec => l_update_rsv_rec
1249: , p_serial_number => l_dummy_sn
1250: , x_serial_number => l_dummy_sn
1251: , p_partial_reservation_flag => fnd_api.g_true
1252: , p_force_reservation_flag => fnd_api.g_false
1253: , p_validation_flag => 'Q'
1254: , x_quantity_reserved => l_qty_succ_reserved
1255: , x_reservation_id => l_org_wide_res_id

Line 1252: , p_force_reservation_flag => fnd_api.g_false

1248: , p_rsv_rec => l_update_rsv_rec
1249: , p_serial_number => l_dummy_sn
1250: , x_serial_number => l_dummy_sn
1251: , p_partial_reservation_flag => fnd_api.g_true
1252: , p_force_reservation_flag => fnd_api.g_false
1253: , p_validation_flag => 'Q'
1254: , x_quantity_reserved => l_qty_succ_reserved
1255: , x_reservation_id => l_org_wide_res_id
1256: , p_over_reservation_flag => 2 -- Bug 5365200 Passing p_over_reservation_flag to allow reservation of demand for overpicking case

Line 1260: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

1256: , p_over_reservation_flag => 2 -- Bug 5365200 Passing p_over_reservation_flag to allow reservation of demand for overpicking case
1257: );
1258:
1259: -- Return an error if the create reservation call failed
1260: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
1261: IF (is_debug) THEN
1262: print_debug('error in create reservation', 'Inv_Pick_Release_PVT.Process_Reservations');
1263: END IF;
1264: fnd_message.set_name('INV', 'INV_QRY_RSV_FAILED');

Line 1266: RAISE fnd_api.g_exc_unexpected_error;

1262: print_debug('error in create reservation', 'Inv_Pick_Release_PVT.Process_Reservations');
1263: END IF;
1264: fnd_message.set_name('INV', 'INV_QRY_RSV_FAILED');
1265: fnd_msg_pub.ADD;
1266: RAISE fnd_api.g_exc_unexpected_error;
1267: END IF;
1268:
1269: -- If partial picking is not allowed and the full quantity could no
1270: -- be reserved, return an error.

Line 1271: IF p_allow_partial_pick = fnd_api.g_false

1267: END IF;
1268:
1269: -- If partial picking is not allowed and the full quantity could no
1270: -- be reserved, return an error.
1271: IF p_allow_partial_pick = fnd_api.g_false
1272: AND l_qty_succ_reserved < l_quantity_to_reserve THEN
1273: IF (is_debug) THEN
1274: print_debug('p_allow_partial_pick is false and could not reserve the quantity requested'
1275: , 'Inv-Pick_Release_PVT.Process_Reservations');

Line 1279: RAISE fnd_api.g_exc_unexpected_error;

1275: , 'Inv-Pick_Release_PVT.Process_Reservations');
1276: END IF;
1277: fnd_message.set_name('INV', 'INV_COULD_NOT_PICK_FULL');
1278: fnd_msg_pub.ADD;
1279: RAISE fnd_api.g_exc_unexpected_error;
1280: END IF;
1281:
1282: -- Query up the reservation which was just created and add it to the
1283: -- filtered table.

Line 1287: , p_init_msg_lst => fnd_api.g_true

1283: -- filtered table.
1284: l_qry_rsv_rec_by_id.reservation_id := l_org_wide_res_id;
1285: inv_reservation_pub.query_reservation(
1286: p_api_version_number => 1.0
1287: , p_init_msg_lst => fnd_api.g_true
1288: , x_return_status => l_api_return_status
1289: , x_msg_count => x_msg_count
1290: , x_msg_data => x_msg_data
1291: , p_query_input => l_qry_rsv_rec_by_id

Line 1298: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

1294: , x_error_code => l_api_error_code
1295: );
1296:
1297: -- Return an error if the query reservations call failed
1298: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
1299: fnd_message.set_name('INV', 'INV_QRY_RSV_FAILED');
1300: fnd_msg_pub.ADD;
1301: RAISE fnd_api.g_exc_unexpected_error;
1302: END IF;

Line 1301: RAISE fnd_api.g_exc_unexpected_error;

1297: -- Return an error if the query reservations call failed
1298: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
1299: fnd_message.set_name('INV', 'INV_QRY_RSV_FAILED');
1300: fnd_msg_pub.ADD;
1301: RAISE fnd_api.g_exc_unexpected_error;
1302: END IF;
1303:
1304: -- Add the retrieved reservation to the filtered table
1305: l_res_tbl_index := l_demand_reservations.FIRST;

Line 1411: WHEN fnd_api.g_exc_error THEN

1407: END LOOP;
1408: END IF;
1409: END IF;
1410: EXCEPTION
1411: WHEN fnd_api.g_exc_error THEN
1412: x_return_status := fnd_api.g_ret_sts_error;
1413: -- Get message count and data
1414: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1415: GMI_RESERVATION_UTIL.println('sqlerror'|| SUBSTRB(SQLERRM, 1, 100));

Line 1412: x_return_status := fnd_api.g_ret_sts_error;

1408: END IF;
1409: END IF;
1410: EXCEPTION
1411: WHEN fnd_api.g_exc_error THEN
1412: x_return_status := fnd_api.g_ret_sts_error;
1413: -- Get message count and data
1414: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1415: GMI_RESERVATION_UTIL.println('sqlerror'|| SUBSTRB(SQLERRM, 1, 100));
1416: WHEN fnd_api.g_exc_unexpected_error THEN

Line 1416: WHEN fnd_api.g_exc_unexpected_error THEN

1412: x_return_status := fnd_api.g_ret_sts_error;
1413: -- Get message count and data
1414: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1415: GMI_RESERVATION_UTIL.println('sqlerror'|| SUBSTRB(SQLERRM, 1, 100));
1416: WHEN fnd_api.g_exc_unexpected_error THEN
1417: x_return_status := fnd_api.g_ret_sts_unexp_error;
1418: -- Get message count and data
1419: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1420: GMI_RESERVATION_UTIL.println('sqlerror'|| SUBSTRB(SQLERRM, 1, 100));

Line 1417: x_return_status := fnd_api.g_ret_sts_unexp_error;

1413: -- Get message count and data
1414: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1415: GMI_RESERVATION_UTIL.println('sqlerror'|| SUBSTRB(SQLERRM, 1, 100));
1416: WHEN fnd_api.g_exc_unexpected_error THEN
1417: x_return_status := fnd_api.g_ret_sts_unexp_error;
1418: -- Get message count and data
1419: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1420: GMI_RESERVATION_UTIL.println('sqlerror'|| SUBSTRB(SQLERRM, 1, 100));
1421: WHEN OTHERS THEN

Line 1422: x_return_status := fnd_api.g_ret_sts_unexp_error;

1418: -- Get message count and data
1419: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1420: GMI_RESERVATION_UTIL.println('sqlerror'|| SUBSTRB(SQLERRM, 1, 100));
1421: WHEN OTHERS THEN
1422: x_return_status := fnd_api.g_ret_sts_unexp_error;
1423:
1424: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1425: fnd_msg_pub.add_exc_msg(g_pkg_name, 'INV_PICK_RELEASE_PVT');
1426: END IF;

Line 1453: l_default_subinventory VARCHAR2(10) := fnd_api.g_miss_char;

1449: l_return_status VARCHAR2(1);
1450: l_pick_slip_number NUMBER;
1451: l_ready_to_print VARCHAR2(1);
1452: l_api_error_msg VARCHAR2(2000);
1453: l_default_subinventory VARCHAR2(10) := fnd_api.g_miss_char;
1454: l_default_locator_id NUMBER := fnd_api.g_miss_num;
1455: l_call_mode VARCHAR2(1);
1456: BEGIN
1457: IF (is_debug) THEN

Line 1454: l_default_locator_id NUMBER := fnd_api.g_miss_num;

1450: l_pick_slip_number NUMBER;
1451: l_ready_to_print VARCHAR2(1);
1452: l_api_error_msg VARCHAR2(2000);
1453: l_default_subinventory VARCHAR2(10) := fnd_api.g_miss_char;
1454: l_default_locator_id NUMBER := fnd_api.g_miss_num;
1455: l_call_mode VARCHAR2(1);
1456: BEGIN
1457: IF (is_debug) THEN
1458: print_debug('Inside Process_Unreservable', 'Inv_Pick_Release_PVT.Process_Unreservable_Items');

Line 1460: x_return_status := fnd_api.g_ret_sts_success;

1456: BEGIN
1457: IF (is_debug) THEN
1458: print_debug('Inside Process_Unreservable', 'Inv_Pick_Release_PVT.Process_Unreservable_Items');
1459: END IF;
1460: x_return_status := fnd_api.g_ret_sts_success;
1461:
1462: /* bug 1560334 jxlu */
1463:
1464: IF g_organization_id IS NOT NULL and

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

1537: print_debug('after update shipping attributes',
1538: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1539: END IF;
1540:
1541: IF (l_return_status = fnd_api.g_ret_sts_error) THEN
1542: IF (is_debug) THEN
1543: print_debug('return error from update shipping attributes',
1544: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1545: END IF;

Line 1546: RAISE fnd_api.g_exc_error;

1542: IF (is_debug) THEN
1543: print_debug('return error from update shipping attributes',
1544: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1545: END IF;
1546: RAISE fnd_api.g_exc_error;
1547: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1548: IF (is_debug) THEN
1549: print_debug('return error from update shipping attributes',
1550: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');

Line 1547: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN

1543: print_debug('return error from update shipping attributes',
1544: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1545: END IF;
1546: RAISE fnd_api.g_exc_error;
1547: ELSIF l_return_status = fnd_api.g_ret_sts_unexp_error THEN
1548: IF (is_debug) THEN
1549: print_debug('return error from update shipping attributes',
1550: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1551: END IF;

Line 1552: RAISE fnd_api.g_exc_unexpected_error;

1548: IF (is_debug) THEN
1549: print_debug('return error from update shipping attributes',
1550: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1551: END IF;
1552: RAISE fnd_api.g_exc_unexpected_error;
1553: END IF;
1554:
1555: -- call the get pick slip number
1556:

Line 1591: IF l_return_status <> fnd_api.g_ret_sts_success

1587: print_debug('after calling get_pick_slip_number',
1588: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1589: END IF;
1590:
1591: IF l_return_status <> fnd_api.g_ret_sts_success
1592: OR l_pick_slip_number = -1 THEN
1593: IF (is_debug) THEN
1594: print_debug('return error from get_pick_slip_number',
1595: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');

Line 1599: RAISE fnd_api.g_exc_unexpected_error;

1595: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1596: END IF;
1597: fnd_message.set_name('INV', 'INV_NO_PICK_SLIP_NUMBER');
1598: fnd_msg_pub.ADD;
1599: RAISE fnd_api.g_exc_unexpected_error;
1600: END IF;
1601:
1602: if ( p_pick_slip_mode <> 'I' ) then
1603: WSH_INV_INTEGRATION_GRP.find_printer

Line 1609: IF l_return_status <> fnd_api.g_ret_sts_success THEN

1605: , p_organization_id => p_mo_line_rec.organization_id
1606: , x_error_message => l_api_error_msg
1607: , x_api_Status => l_return_status
1608: );
1609: IF l_return_status <> fnd_api.g_ret_sts_success THEN
1610: IF (is_debug) THEN
1611: print_debug('return error from WSH_INV_INTEGRATION.find_printer',
1612: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1613: END IF;

Line 1614: RAISE fnd_api.g_exc_unexpected_error;

1610: IF (is_debug) THEN
1611: print_debug('return error from WSH_INV_INTEGRATION.find_printer',
1612: 'Inv_Pick_Release_Pvt.Process_Unreservable_Items');
1613: END IF;
1614: RAISE fnd_api.g_exc_unexpected_error;
1615: END IF;
1616: end if ;
1617:
1618: IF (is_debug) THEN

Line 1644: WHEN fnd_api.g_exc_error THEN

1640: print_debug('end of process_unreservable_items ',
1641: 'Inv_pick_release_pvt.process_unreservable_items');
1642: END IF;
1643: EXCEPTION
1644: WHEN fnd_api.g_exc_error THEN
1645: x_return_status := fnd_api.g_ret_sts_error;
1646: -- Get message count and data
1647: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1648: WHEN fnd_api.g_exc_unexpected_error THEN

Line 1645: x_return_status := fnd_api.g_ret_sts_error;

1641: 'Inv_pick_release_pvt.process_unreservable_items');
1642: END IF;
1643: EXCEPTION
1644: WHEN fnd_api.g_exc_error THEN
1645: x_return_status := fnd_api.g_ret_sts_error;
1646: -- Get message count and data
1647: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1648: WHEN fnd_api.g_exc_unexpected_error THEN
1649: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 1648: WHEN fnd_api.g_exc_unexpected_error THEN

1644: WHEN fnd_api.g_exc_error THEN
1645: x_return_status := fnd_api.g_ret_sts_error;
1646: -- Get message count and data
1647: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1648: WHEN fnd_api.g_exc_unexpected_error THEN
1649: x_return_status := fnd_api.g_ret_sts_unexp_error;
1650: -- Get message count and data
1651: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1652: WHEN OTHERS THEN

Line 1649: x_return_status := fnd_api.g_ret_sts_unexp_error;

1645: x_return_status := fnd_api.g_ret_sts_error;
1646: -- Get message count and data
1647: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1648: WHEN fnd_api.g_exc_unexpected_error THEN
1649: x_return_status := fnd_api.g_ret_sts_unexp_error;
1650: -- Get message count and data
1651: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1652: WHEN OTHERS THEN
1653: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 1653: x_return_status := fnd_api.g_ret_sts_unexp_error;

1649: x_return_status := fnd_api.g_ret_sts_unexp_error;
1650: -- Get message count and data
1651: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1652: WHEN OTHERS THEN
1653: x_return_status := fnd_api.g_ret_sts_unexp_error;
1654:
1655: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1656: fnd_msg_pub.add_exc_msg(g_pkg_name, 'INV_PICK_RELEASE_PVT');
1657: END IF;

Line 1704: x_return_status := fnd_api.g_ret_sts_success;

1700: IF (is_debug) THEN
1701: print_debug('inside process_prj_dynamic_locator',
1702: 'Inv_Pick_Release_PVt.Process_Prj_Dynamic_Locator');
1703: END IF;
1704: x_return_status := fnd_api.g_ret_sts_success;
1705:
1706: IF p_to_subinventory IS NULL THEN
1707: l_to_subinventory := p_mo_line_rec.to_subinventory_code;
1708: ELSE

Line 1724: RAISE fnd_api.g_exc_unexpected_error;

1720: IF (is_debug) THEN
1721: print_debug('error setting org cache',
1722: 'Inv_Pick_Release_PVt.Process_Prj_Dynamic_Locator');
1723: END IF;
1724: RAISE fnd_api.g_exc_unexpected_error;
1725: END IF;
1726: l_org_loc_control := INV_CACHE.org_rec.stock_locator_control_code;
1727:
1728: l_return_value := INV_CACHE.set_item_rec(

Line 1736: RAISE fnd_api.g_exc_unexpected_error;

1732: IF (is_debug) THEN
1733: print_debug('error setting item cache',
1734: 'Inv_Pick_Release_PVt.Process_Prj_Dynamic_Locator');
1735: END IF;
1736: RAISE fnd_api.g_exc_unexpected_error;
1737: END IF;
1738: l_item_loc_control := INV_CACHE.item_rec.location_control_code;
1739:
1740: l_return_value := INV_CACHE.set_tosub_rec(

Line 1748: RAISE fnd_api.g_exc_unexpected_error;

1744: IF (is_debug) THEN
1745: print_debug('error setting to sub cache',
1746: 'Inv_Pick_Release_PVt.Process_Prj_Dynamic_Locator');
1747: END IF;
1748: RAISE fnd_api.g_exc_unexpected_error;
1749: END IF;
1750: l_sub_loc_control := INV_CACHE.tosub_rec.locator_type;
1751:
1752: IF (is_debug) THEN

Line 1849: RAISE fnd_api.g_exc_unexpected_error;

1845: end loop;
1846: end if;*/
1847: fnd_message.set_name('INV', 'INV_INT_LOCSEGCODE');
1848: fnd_msg_pub.ADD;
1849: RAISE fnd_api.g_exc_unexpected_error;
1850: END IF; --success
1851: ELSE --no task/project
1852: IF (NVL(TO_NUMBER(l_locator.segment19), -1) <> NVL(p_mo_line_rec.project_id, -1)
1853: AND NVL(TO_NUMBER(l_locator.segment20), -1) <> NVL(p_mo_line_rec.task_id, -1)

Line 1857: RAISE fnd_api.g_exc_error;

1853: AND NVL(TO_NUMBER(l_locator.segment20), -1) <> NVL(p_mo_line_rec.task_id, -1)
1854: ) THEN
1855: fnd_message.set_name('INV', 'INV_INT_LOCCODE');
1856: fnd_msg_pub.ADD;
1857: RAISE fnd_api.g_exc_error;
1858: END IF;
1859: END IF; --task project
1860: END;
1861:

Line 1886: WHEN fnd_api.g_exc_error THEN

1882: END IF;
1883: x_to_locator_id := NVL(l_new_to_locator_id, p_to_locator_id);
1884:
1885: EXCEPTION
1886: WHEN fnd_api.g_exc_error THEN
1887: x_return_status := fnd_api.g_ret_sts_error;
1888: -- Get message count and data
1889: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1890: WHEN fnd_api.g_exc_unexpected_error THEN

Line 1887: x_return_status := fnd_api.g_ret_sts_error;

1883: x_to_locator_id := NVL(l_new_to_locator_id, p_to_locator_id);
1884:
1885: EXCEPTION
1886: WHEN fnd_api.g_exc_error THEN
1887: x_return_status := fnd_api.g_ret_sts_error;
1888: -- Get message count and data
1889: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1890: WHEN fnd_api.g_exc_unexpected_error THEN
1891: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 1890: WHEN fnd_api.g_exc_unexpected_error THEN

1886: WHEN fnd_api.g_exc_error THEN
1887: x_return_status := fnd_api.g_ret_sts_error;
1888: -- Get message count and data
1889: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1890: WHEN fnd_api.g_exc_unexpected_error THEN
1891: x_return_status := fnd_api.g_ret_sts_unexp_error;
1892: -- Get message count and data
1893: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1894: WHEN OTHERS THEN

Line 1891: x_return_status := fnd_api.g_ret_sts_unexp_error;

1887: x_return_status := fnd_api.g_ret_sts_error;
1888: -- Get message count and data
1889: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1890: WHEN fnd_api.g_exc_unexpected_error THEN
1891: x_return_status := fnd_api.g_ret_sts_unexp_error;
1892: -- Get message count and data
1893: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1894: WHEN OTHERS THEN
1895: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 1895: x_return_status := fnd_api.g_ret_sts_unexp_error;

1891: x_return_status := fnd_api.g_ret_sts_unexp_error;
1892: -- Get message count and data
1893: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
1894: WHEN OTHERS THEN
1895: x_return_status := fnd_api.g_ret_sts_unexp_error;
1896:
1897: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
1898: fnd_msg_pub.add_exc_msg(g_pkg_name, 'INV_PICK_RELEASE_PVT');
1899: END IF;

Line 1939: -- fnd_api.g_ret_sts_success;

1935: --
1936: -- Output Parameters
1937: -- x_return_status
1938: -- if the process succeeds, the value is
1939: -- fnd_api.g_ret_sts_success;
1940: -- if there is an expected error, the value is
1941: -- fnd_api.g_ret_sts_error;
1942: -- if there is an unexpected error, the value is
1943: -- fnd_api.g_ret_sts_unexp_error;

Line 1941: -- fnd_api.g_ret_sts_error;

1937: -- x_return_status
1938: -- if the process succeeds, the value is
1939: -- fnd_api.g_ret_sts_success;
1940: -- if there is an expected error, the value is
1941: -- fnd_api.g_ret_sts_error;
1942: -- if there is an unexpected error, the value is
1943: -- fnd_api.g_ret_sts_unexp_error;
1944: -- x_msg_count
1945: -- if there is one or more errors, the number of error messages

Line 1943: -- fnd_api.g_ret_sts_unexp_error;

1939: -- fnd_api.g_ret_sts_success;
1940: -- if there is an expected error, the value is
1941: -- fnd_api.g_ret_sts_error;
1942: -- if there is an unexpected error, the value is
1943: -- fnd_api.g_ret_sts_unexp_error;
1944: -- x_msg_count
1945: -- if there is one or more errors, the number of error messages
1946: -- in the buffer
1947: -- x_msg_data

Line 1949: -- (See fnd_api package for more details about the above output parameters)

1945: -- if there is one or more errors, the number of error messages
1946: -- in the buffer
1947: -- x_msg_data
1948: -- if there is one and only one error, the error message
1949: -- (See fnd_api package for more details about the above output parameters)
1950: --
1951: PROCEDURE process_line(
1952: p_api_version IN NUMBER
1953: , p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false

Line 1953: , p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false

1949: -- (See fnd_api package for more details about the above output parameters)
1950: --
1951: PROCEDURE process_line(
1952: p_api_version IN NUMBER
1953: , p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false
1954: , p_commit IN VARCHAR2 DEFAULT fnd_api.g_false
1955: , x_return_status OUT NOCOPY VARCHAR2
1956: , x_msg_count OUT NOCOPY NUMBER
1957: , x_msg_data OUT NOCOPY VARCHAR2

Line 1954: , p_commit IN VARCHAR2 DEFAULT fnd_api.g_false

1950: --
1951: PROCEDURE process_line(
1952: p_api_version IN NUMBER
1953: , p_init_msg_list IN VARCHAR2 DEFAULT fnd_api.g_false
1954: , p_commit IN VARCHAR2 DEFAULT fnd_api.g_false
1955: , x_return_status OUT NOCOPY VARCHAR2
1956: , x_msg_count OUT NOCOPY NUMBER
1957: , x_msg_data OUT NOCOPY VARCHAR2
1958: , p_mo_line_rec IN OUT NOCOPY inv_move_order_pub.trolin_rec_type

Line 1960: , p_allow_partial_pick IN VARCHAR2 DEFAULT fnd_api.g_true

1956: , x_msg_count OUT NOCOPY NUMBER
1957: , x_msg_data OUT NOCOPY VARCHAR2
1958: , p_mo_line_rec IN OUT NOCOPY inv_move_order_pub.trolin_rec_type
1959: , p_grouping_rule_id IN NUMBER
1960: , p_allow_partial_pick IN VARCHAR2 DEFAULT fnd_api.g_true
1961: , p_print_mode IN VARCHAR2
1962: , x_detail_rec_count OUT NOCOPY NUMBER
1963: , p_plan_tasks IN BOOLEAN DEFAULT FALSE
1964: ) IS

Line 2090: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN

2086: x_detail_rec_count := 0;
2087: l_num_detail_recs := 0;
2088:
2089: -- Standard Call to check for call compatibility
2090: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
2091: RAISE fnd_api.g_exc_unexpected_error;
2092: END IF;
2093:
2094: -- Initialize message list if p_init_msg_list is set to true

Line 2091: RAISE fnd_api.g_exc_unexpected_error;

2087: l_num_detail_recs := 0;
2088:
2089: -- Standard Call to check for call compatibility
2090: IF NOT fnd_api.compatible_api_call(l_api_version, p_api_version, l_api_name, g_pkg_name) THEN
2091: RAISE fnd_api.g_exc_unexpected_error;
2092: END IF;
2093:
2094: -- Initialize message list if p_init_msg_list is set to true
2095: IF fnd_api.to_boolean(p_init_msg_list) THEN

Line 2095: IF fnd_api.to_boolean(p_init_msg_list) THEN

2091: RAISE fnd_api.g_exc_unexpected_error;
2092: END IF;
2093:
2094: -- Initialize message list if p_init_msg_list is set to true
2095: IF fnd_api.to_boolean(p_init_msg_list) THEN
2096: fnd_msg_pub.initialize;
2097: END IF;
2098:
2099: -- Initialize API return status to success

Line 2100: x_return_status := fnd_api.g_ret_sts_success;

2096: fnd_msg_pub.initialize;
2097: END IF;
2098:
2099: -- Initialize API return status to success
2100: x_return_status := fnd_api.g_ret_sts_success;
2101:
2102: -- Return success immediately if the line is already fully detailed
2103: -- check required quantity otherwise use the quantity - CMS change bug 2135900
2104: IF NVL(p_mo_line_rec.quantity_detailed, 0) >= NVL(p_mo_line_rec.required_quantity, NVL(p_mo_line_rec.quantity, 0)) THEN

Line 2109: IF p_allow_partial_pick = fnd_api.g_false THEN

2105: RETURN;
2106: END IF;
2107: -- Override the printing mode to deferred if allow partial pick is false.
2108: -- Otherwise set it based on the parameter passed in.
2109: IF p_allow_partial_pick = fnd_api.g_false THEN
2110: l_pick_slip_mode := 'E';
2111: ELSE
2112: l_pick_slip_mode := p_print_mode;
2113: END IF;

Line 2170: RAISE fnd_api.g_exc_unexpected_error;

2166: END IF;
2167: ROLLBACK TO process_line_pvt;
2168: fnd_message.set_name('INV', 'INV_DELIV_INFO_MISSING');
2169: fnd_msg_pub.ADD;
2170: RAISE fnd_api.g_exc_unexpected_error;
2171: END;
2172: IF (is_debug) THEN
2173: gmi_reservation_util.println('Process_Line after fetch wdd');
2174: END IF;

Line 2180: raise fnd_api.g_exc_unexpected_error;

2176: IF NOT l_return_value THEN
2177: If is_debug THEN
2178: print_debug('Error setting item cache', 'Inv_Pick_Release_PVT.Process_Line');
2179: End If;
2180: raise fnd_api.g_exc_unexpected_error;
2181: End If;
2182: l_reservable_type:= INV_CACHE.item_rec.reservable_type;
2183:
2184: IF p_mo_line_rec.transaction_type_id = 52 THEN

Line 2196: raise fnd_api.g_exc_unexpected_error;

2192: IF NOT l_return_value THEN
2193: If is_debug THEN
2194: print_debug('Error setting item cache','Inv_Pick_Release_PVT.Process_Line');
2195: End If;
2196: raise fnd_api.g_exc_unexpected_error;
2197: End If;
2198: l_demand_source_type := INV_CACHE.mtt_rec.transaction_source_type_id;
2199: g_transaction_type_id := p_mo_line_rec.transaction_type_id;
2200: g_transaction_source_type_id := l_demand_source_type;

Line 2217: RAISE fnd_api.g_exc_unexpected_error;

2213: gmi_reservation_util.println('No Mtl_Sales_Order ID found for oe header');
2214: END IF;
2215: fnd_message.set_name('INV', 'INV_COULD_NOT_GET_MSO_HEADER');
2216: fnd_msg_pub.ADD;
2217: RAISE fnd_api.g_exc_unexpected_error;
2218: END IF;
2219:
2220: l_mso_header_id := INV_CACHE.mso_rec.sales_order_id;
2221:

Line 2253: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

2249: , x_rsv_qty2_available => l_rsv_qty2_available
2250: );
2251:
2252: -- Return an error if the query reservations call failed
2253: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
2254: ROLLBACK TO process_line_pvt;
2255: RAISE fnd_api.g_exc_unexpected_error;
2256: END IF;
2257: ELSIF (l_reservable_type = 2) THEN

Line 2255: RAISE fnd_api.g_exc_unexpected_error;

2251:
2252: -- Return an error if the query reservations call failed
2253: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
2254: ROLLBACK TO process_line_pvt;
2255: RAISE fnd_api.g_exc_unexpected_error;
2256: END IF;
2257: ELSIF (l_reservable_type = 2) THEN
2258: -- bug 1412145 for non reservable item, just update shipping attr with released_status = 'Y'
2259: -- update the qty_Detailed and qty_Delivered in the move order line

Line 2278: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

2274: , p_print_mode => p_print_mode
2275: , x_call_mode => l_call_mode
2276: );
2277:
2278: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
2279: ROLLBACK TO process_line_pvt;
2280: RAISE fnd_api.g_exc_unexpected_error;
2281: END IF;
2282:

Line 2280: RAISE fnd_api.g_exc_unexpected_error;

2276: );
2277:
2278: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
2279: ROLLBACK TO process_line_pvt;
2280: RAISE fnd_api.g_exc_unexpected_error;
2281: END IF;
2282:
2283: IF l_ready_to_print = fnd_api.g_true
2284: AND p_allow_partial_pick = fnd_api.g_true

Line 2283: IF l_ready_to_print = fnd_api.g_true

2279: ROLLBACK TO process_line_pvt;
2280: RAISE fnd_api.g_exc_unexpected_error;
2281: END IF;
2282:
2283: IF l_ready_to_print = fnd_api.g_true
2284: AND p_allow_partial_pick = fnd_api.g_true
2285: AND l_call_mode IS NULL THEN
2286: COMMIT WORK;
2287:

Line 2284: AND p_allow_partial_pick = fnd_api.g_true

2280: RAISE fnd_api.g_exc_unexpected_error;
2281: END IF;
2282:
2283: IF l_ready_to_print = fnd_api.g_true
2284: AND p_allow_partial_pick = fnd_api.g_true
2285: AND l_call_mode IS NULL THEN
2286: COMMIT WORK;
2287:
2288: l_return_value := INV_CACHE.set_mtrh_rec(p_mo_line_rec.header_id);

Line 2293: raise fnd_api.g_exc_unexpected_error;

2289: IF NOT l_return_value THEN
2290: If is_debug THEN
2291: print_debug('Error setting header cache', 'Inv_Pick_Release_PVT.Process_Line');
2292: End If;
2293: raise fnd_api.g_exc_unexpected_error;
2294: END IF;
2295: l_request_number := INV_CACHE.mtrh_rec.request_number;
2296:
2297: IF g_request_number is NOT NULL and

Line 2312: x_return_status := fnd_api.g_ret_sts_error;

2308: WHEN NO_DATA_FOUND THEN
2309: IF is_debug THEN
2310: print_debug('No Data found - document set','Inv_Pick_Release_PVT.Process_Line');
2311: END IF;
2312: x_return_status := fnd_api.g_ret_sts_error;
2313: RAISE fnd_api.g_exc_error;
2314: END;
2315: g_request_number := l_request_number;
2316: g_report_set_id := l_report_set_id;

Line 2313: RAISE fnd_api.g_exc_error;

2309: IF is_debug THEN
2310: print_debug('No Data found - document set','Inv_Pick_Release_PVT.Process_Line');
2311: END IF;
2312: x_return_status := fnd_api.g_ret_sts_error;
2313: RAISE fnd_api.g_exc_error;
2314: END;
2315: g_request_number := l_request_number;
2316: g_report_set_id := l_report_set_id;
2317: END IF;

Line 2327: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

2323: , x_api_status => l_api_return_status
2324: , x_error_message => l_api_error_msg
2325: );
2326:
2327: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
2328: IF (is_debug) THEN
2329: print_debug('Error in Print Pick Slip', 'Inv_Pick_Release_PVT.Process_Line');
2330: END IF;
2331: ROLLBACK TO process_line_pvt;

Line 2335: RAISE fnd_api.g_exc_unexpected_error;

2331: ROLLBACK TO process_line_pvt;
2332: fnd_message.set_name('INV', 'INV_PRINT_PICK_SLIP_FAILED');
2333: fnd_message.set_token('PICK_SLIP_NUM', TO_CHAR(l_pick_slip_number));
2334: fnd_msg_pub.ADD;
2335: RAISE fnd_api.g_exc_unexpected_error;
2336: END IF;
2337: END IF; -- ready to print
2338:
2339: GOTO end_pick;

Line 2395: , p_init_msg_list => fnd_api.g_false

2391: --Bug3237702 ends
2392: -- Bug 5264987 Added p_organization_id to the create_suggestions call
2393: inv_ppengine_pvt.create_suggestions(
2394: p_api_version => 1.0
2395: , p_init_msg_list => fnd_api.g_false
2396: , p_commit => fnd_api.g_false
2397: , x_return_status => l_api_return_status
2398: , x_msg_count => x_msg_count
2399: , x_msg_data => x_msg_data

Line 2396: , p_commit => fnd_api.g_false

2392: -- Bug 5264987 Added p_organization_id to the create_suggestions call
2393: inv_ppengine_pvt.create_suggestions(
2394: p_api_version => 1.0
2395: , p_init_msg_list => fnd_api.g_false
2396: , p_commit => fnd_api.g_false
2397: , x_return_status => l_api_return_status
2398: , x_msg_count => x_msg_count
2399: , x_msg_data => x_msg_data
2400: , p_transaction_temp_id => p_mo_line_rec.line_id

Line 2406: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

2402: , p_suggest_serial => 'T'
2403: , p_plan_tasks => p_plan_tasks
2404: , p_organization_id => p_mo_line_rec.organization_id
2405: );
2406: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
2407: IF (is_debug) THEN
2408: print_debug('l_return_status = '|| l_api_return_status, 'Inv_Pick_Release_PVT.Process_Line');
2409: print_debug('inv detailing failed', 'Inv_Pick_Release_PVT.Process_Line');
2410: END IF;

Line 2444: raise fnd_api.g_exc_unexpected_error;

2440: IF NOT l_return_value THEN
2441: If is_debug THEN
2442: print_debug('Error setting header cache', 'Inv_Pick_Release_PVT.Process_Line');
2443: End If;
2444: raise fnd_api.g_exc_unexpected_error;
2445: END IF;
2446: l_request_number := INV_CACHE.mtrh_rec.request_number;
2447:
2448: fnd_message.set_name('INV', 'INV_DETAILING_FAILED');

Line 2452: RAISE fnd_api.g_exc_unexpected_error;

2448: fnd_message.set_name('INV', 'INV_DETAILING_FAILED');
2449: fnd_message.set_token('LINE_NUM', TO_CHAR(p_mo_line_rec.line_number));
2450: fnd_message.set_token('MO_NUMBER', l_request_number);
2451: fnd_msg_pub.ADD;
2452: RAISE fnd_api.g_exc_unexpected_error;
2453: END IF;
2454:
2455: IF (is_debug) THEN
2456: print_debug('after calling create suggestions with return status = '||l_api_return_status, 'Inv_Pick_Release_PVT.Process_Line');

Line 2517: IF p_allow_partial_pick = fnd_api.g_false THEN

2513: -- {{ Test Case # UTK-REALLOC-3.2.6:62 }}
2514: -- Description: Partially detailed should be set to 1 if allocation within tolerance but less
2515: -- than the requested quantity
2516: IF l_quantity_detailed < p_mo_line_rec.primary_quantity - l_min_tolerance THEN
2517: IF p_allow_partial_pick = fnd_api.g_false THEN
2518: IF (is_debug) THEN
2519: print_debug('Error - could not pick full', 'Inv_Pick_Release_PVT.Process_Line');
2520: END IF;
2521: ROLLBACK TO process_line_pvt;

Line 2524: RAISE fnd_api.g_exc_unexpected_error;

2520: END IF;
2521: ROLLBACK TO process_line_pvt;
2522: fnd_message.set_name('INV', 'INV_COULD_NOT_PICK_FULL');
2523: fnd_msg_pub.ADD;
2524: RAISE fnd_api.g_exc_unexpected_error;
2525: ELSE
2526: -- Set a flag to later set the return status for success,
2527: -- but only partially detailed
2528: IF (is_debug) THEN

Line 2579: ,p_init_msg_lst => fnd_api.g_false

2575: print_debug('Delete org level reservation', 'Inv_Pick_Release_PVT.Process_Reservations');
2576: END IF;
2577: inv_reservation_pvt.delete_reservation(
2578: p_api_version_number => 1.0
2579: ,p_init_msg_lst => fnd_api.g_false
2580: ,x_return_status => l_api_return_status
2581: ,x_msg_count => x_msg_count
2582: ,x_msg_data => x_msg_data
2583: ,p_rsv_rec => l_demand_rsvs_ordered(l_index)

Line 2585: ,p_validation_flag => fnd_api.g_true

2581: ,x_msg_count => x_msg_count
2582: ,x_msg_data => x_msg_data
2583: ,p_rsv_rec => l_demand_rsvs_ordered(l_index)
2584: ,p_original_serial_number => l_dummy_sn
2585: ,p_validation_flag => fnd_api.g_true
2586: );
2587:
2588: IF (l_api_return_status = fnd_api.g_ret_sts_error) THEN
2589: IF (is_debug) THEN

Line 2588: IF (l_api_return_status = fnd_api.g_ret_sts_error) THEN

2584: ,p_original_serial_number => l_dummy_sn
2585: ,p_validation_flag => fnd_api.g_true
2586: );
2587:
2588: IF (l_api_return_status = fnd_api.g_ret_sts_error) THEN
2589: IF (is_debug) THEN
2590: print_debug('return error from delete_reservation', 'Inv_Pick_Release_Pvt.Process_Line');
2591: END IF;
2592: RAISE fnd_api.g_exc_error;

Line 2592: RAISE fnd_api.g_exc_error;

2588: IF (l_api_return_status = fnd_api.g_ret_sts_error) THEN
2589: IF (is_debug) THEN
2590: print_debug('return error from delete_reservation', 'Inv_Pick_Release_Pvt.Process_Line');
2591: END IF;
2592: RAISE fnd_api.g_exc_error;
2593: ELSIF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
2594: IF (is_debug) THEN
2595: print_debug('return unexpected error from delete_reservation','Inv_Pick_Release_Pvt.Process_Line');
2596: END IF;

Line 2593: ELSIF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN

2589: IF (is_debug) THEN
2590: print_debug('return error from delete_reservation', 'Inv_Pick_Release_Pvt.Process_Line');
2591: END IF;
2592: RAISE fnd_api.g_exc_error;
2593: ELSIF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
2594: IF (is_debug) THEN
2595: print_debug('return unexpected error from delete_reservation','Inv_Pick_Release_Pvt.Process_Line');
2596: END IF;
2597: RAISE fnd_api.g_exc_unexpected_error;

Line 2597: RAISE fnd_api.g_exc_unexpected_error;

2593: ELSIF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
2594: IF (is_debug) THEN
2595: print_debug('return unexpected error from delete_reservation','Inv_Pick_Release_Pvt.Process_Line');
2596: END IF;
2597: RAISE fnd_api.g_exc_unexpected_error;
2598: END IF;
2599:
2600: Else
2601: --update quantity tree

Line 2634: , p_init_msg_lst => fnd_api.g_false

2630:
2631: -- Added secondary qty related parameters section for Bug 7377744
2632: inv_quantity_tree_pub.update_quantities(
2633: p_api_version_number => 1.0
2634: , p_init_msg_lst => fnd_api.g_false
2635: , x_return_status => l_api_return_status
2636: , x_msg_count => x_msg_count
2637: , x_msg_data => x_msg_data
2638: , p_organization_id => p_mo_line_rec.organization_id

Line 2672: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

2668: , x_sqs => l_sec_qty_sug
2669: , x_satt => l_sec_qty_att
2670: , x_satr => l_sec_qty_available_to_reserve
2671: );
2672: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
2673: IF (is_debug) THEN
2674: print_debug('Error from update quantity tree',
2675: 'Inv_Pick_Release_PVT.Process_Line');
2676: END IF;

Line 2677: RAISE fnd_api.g_exc_unexpected_error;

2673: IF (is_debug) THEN
2674: print_debug('Error from update quantity tree',
2675: 'Inv_Pick_Release_PVT.Process_Line');
2676: END IF;
2677: RAISE fnd_api.g_exc_unexpected_error;
2678: END IF;
2679:
2680: --handle conversion to reservation UOM
2681: IF l_demand_rsvs_ordered(l_index).reservation_uom_code IS NULL OR l_new_prim_rsv_quantity = 0 THEN

Line 2708: RAISE fnd_api.g_exc_unexpected_error;

2704: fnd_message.set_name('INV', 'INV-CANNOT CONVERT');
2705: fnd_message.set_token('UOM', l_primary_uom);
2706: fnd_message.set_token('ROUTINE', 'Pick Release process');
2707: fnd_msg_pub.ADD;
2708: RAISE fnd_api.g_exc_unexpected_error;
2709: END IF;
2710: END IF;
2711: IF (is_debug) THEN
2712: print_debug('New prim rsv qty: ' || l_new_prim_rsv_quantity,'Inv_Pick_Release_PVT.Process_Line');

Line 2727: IF l_api_return_status = fnd_api.g_ret_sts_error THEN

2723: , x_return_status => l_api_return_status
2724: , x_msg_count => x_msg_count
2725: , x_msg_data => x_msg_data);
2726:
2727: IF l_api_return_status = fnd_api.g_ret_sts_error THEN
2728: IF (is_debug) THEN
2729: print_debug('Error from inv_rsv_synch.for_update','Inv_Pick_Release_PVT.Process_Reservations');
2730: END IF;
2731: RAISE fnd_api.g_exc_error;

Line 2731: RAISE fnd_api.g_exc_error;

2727: IF l_api_return_status = fnd_api.g_ret_sts_error THEN
2728: IF (is_debug) THEN
2729: print_debug('Error from inv_rsv_synch.for_update','Inv_Pick_Release_PVT.Process_Reservations');
2730: END IF;
2731: RAISE fnd_api.g_exc_error;
2732: END IF;
2733: --
2734: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
2735: IF (is_debug) THEN

Line 2734: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN

2730: END IF;
2731: RAISE fnd_api.g_exc_error;
2732: END IF;
2733: --
2734: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
2735: IF (is_debug) THEN
2736: print_debug('Unexp. error from inv_rsv_synch.for_update','Inv_Pick_Release_PVT.Process_Reservations');
2737: END IF;
2738: RAISE fnd_api.g_exc_unexpected_error;

Line 2738: RAISE fnd_api.g_exc_unexpected_error;

2734: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
2735: IF (is_debug) THEN
2736: print_debug('Unexp. error from inv_rsv_synch.for_update','Inv_Pick_Release_PVT.Process_Reservations');
2737: END IF;
2738: RAISE fnd_api.g_exc_unexpected_error;
2739: END IF;
2740:
2741: End If; -- new rsv qty = 0
2742: END IF; -- demand rsvs ordered count > 0

Line 2814: RAISE fnd_api.g_exc_unexpected_error;

2810: fnd_message.set_name('INV', 'INV-CANNOT CONVERT');
2811: fnd_message.set_token('UOM', l_primary_uom);
2812: fnd_message.set_token('ROUTINE', 'Pick Release process');
2813: fnd_msg_pub.ADD;
2814: RAISE fnd_api.g_exc_unexpected_error;
2815: END IF;
2816: END IF;
2817: IF (is_debug) THEN
2818: print_debug('New prim rsv qty: ' || l_new_prim_rsv_quantity,'Inv_Pick_Release_PVT.Process_Line');

Line 2837: , p_init_msg_lst => fnd_api.g_false

2833: l_to_rsv_record.reservation_quantity := l_new_rsv_quantity;
2834:
2835: inv_reservation_pub.update_reservation(
2836: p_api_version_number => 1.0
2837: , p_init_msg_lst => fnd_api.g_false
2838: , x_return_status => l_api_return_status
2839: , x_msg_count => l_count
2840: , x_msg_data => l_message
2841: , p_original_rsv_rec => l_original_rsv_record

Line 2845: , p_validation_flag => fnd_api.g_true

2841: , p_original_rsv_rec => l_original_rsv_record
2842: , p_to_rsv_rec => l_to_rsv_record
2843: , p_original_serial_number => l_dummy_sn
2844: , p_to_serial_number => l_dummy_sn
2845: , p_validation_flag => fnd_api.g_true
2846: );
2847:
2848: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
2849: IF (is_debug) THEN

Line 2848: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

2844: , p_to_serial_number => l_dummy_sn
2845: , p_validation_flag => fnd_api.g_true
2846: );
2847:
2848: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
2849: IF (is_debug) THEN
2850: print_debug('error in update reservation', 'Inv_Pick_Release_PVT.Process_Reservations');
2851: END IF;
2852: fnd_message.set_name('INV', 'INV_UPD_RSV_FAILED');

Line 2854: RAISE fnd_api.g_exc_unexpected_error;

2850: print_debug('error in update reservation', 'Inv_Pick_Release_PVT.Process_Reservations');
2851: END IF;
2852: fnd_message.set_name('INV', 'INV_UPD_RSV_FAILED');
2853: fnd_msg_pub.ADD;
2854: RAISE fnd_api.g_exc_unexpected_error;
2855: END IF;
2856:
2857: /* inv_rsv_synch.for_update(
2858: p_reservation_id => l_demand_rsvs_ordered(l_res_ordered_index).reservation_id

Line 2863: IF l_api_return_status = fnd_api.g_ret_sts_error THEN

2859: , x_return_status => l_api_return_status
2860: , x_msg_count => x_msg_count
2861: , x_msg_data => x_msg_data);
2862:
2863: IF l_api_return_status = fnd_api.g_ret_sts_error THEN
2864: IF (is_debug) THEN
2865: print_debug('Error from inv_rsv_synch.for_update','Inv_Pick_Release_PVT.Process_Line');
2866: END IF;
2867: RAISE fnd_api.g_exc_error;

Line 2867: RAISE fnd_api.g_exc_error;

2863: IF l_api_return_status = fnd_api.g_ret_sts_error THEN
2864: IF (is_debug) THEN
2865: print_debug('Error from inv_rsv_synch.for_update','Inv_Pick_Release_PVT.Process_Line');
2866: END IF;
2867: RAISE fnd_api.g_exc_error;
2868: END IF;
2869: --
2870: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
2871: IF (is_debug) THEN

Line 2870: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN

2866: END IF;
2867: RAISE fnd_api.g_exc_error;
2868: END IF;
2869: --
2870: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
2871: IF (is_debug) THEN
2872: print_debug('Unexp. error from inv_rsv_synch.for_update','Inv_Pick_Release_PVT.Process_Line');
2873: END IF;
2874: RAISE fnd_api.g_exc_unexpected_error;

Line 2874: RAISE fnd_api.g_exc_unexpected_error;

2870: IF l_api_return_status = fnd_api.g_ret_sts_unexp_error THEN
2871: IF (is_debug) THEN
2872: print_debug('Unexp. error from inv_rsv_synch.for_update','Inv_Pick_Release_PVT.Process_Line');
2873: END IF;
2874: RAISE fnd_api.g_exc_unexpected_error;
2875: END IF;*/
2876: /* end bug 7253296 */
2877: END IF; /* IF NVL(l_reduce_rsv_qty,0) > 0 THEN */
2878: END IF;

Line 2962: , p_init_msg_lst => fnd_api.g_false

2958: print_debug('updating quantity tree', 'Inv_Pick_Release_PVT.Process_Line');
2959: END IF;
2960: inv_quantity_tree_pub.update_quantities(
2961: p_api_version_number => 1.0
2962: , p_init_msg_lst => fnd_api.g_false
2963: , x_return_status => l_api_return_status
2964: , x_msg_count => x_msg_count
2965: , x_msg_data => x_msg_data
2966: , p_organization_id => p_mo_line_rec.organization_id

Line 3000: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

2996: , x_sqs => l_sec_qty_sug
2997: , x_satt => l_sec_qty_att
2998: , x_satr => l_sec_qty_available_to_reserve
2999: );
3000: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
3001: IF (is_debug) THEN
3002: print_debug('Error from update quantity tree', 'Inv_Pick_Release_PVT.Process_Line');
3003: END IF;
3004: RAISE fnd_api.g_exc_unexpected_error;

Line 3004: RAISE fnd_api.g_exc_unexpected_error;

3000: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
3001: IF (is_debug) THEN
3002: print_debug('Error from update quantity tree', 'Inv_Pick_Release_PVT.Process_Line');
3003: END IF;
3004: RAISE fnd_api.g_exc_unexpected_error;
3005: END IF;
3006: IF (is_debug) THEN
3007: print_debug('update reservation with quantity_detailed', 'Inv_Pick_Release_PVT.Process_Line');
3008: print_debug('quantity_detailed'|| l_reservation_detailed_qty, 'Inv_Pick_Release_PVT.Process_Line');

Line 3040: RAISE fnd_api.g_exc_unexpected_error;

3036: fnd_message.set_name('INV', 'INV-CANNOT CONVERT');
3037: fnd_message.set_token('UOM', l_primary_uom);
3038: fnd_message.set_token('ROUTINE', 'Pick Release process');
3039: fnd_msg_pub.ADD;
3040: RAISE fnd_api.g_exc_unexpected_error;
3041: END IF;
3042: END IF;
3043: -- End of Bug Fix 5624514
3044: IF (is_debug) THEN

Line 3102: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

3098: );
3099:
3100:
3101:
3102: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
3103: ROLLBACK TO process_line_pvt;
3104: RAISE fnd_api.g_exc_unexpected_error;
3105: END IF;
3106:

Line 3104: RAISE fnd_api.g_exc_unexpected_error;

3100:
3101:
3102: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
3103: ROLLBACK TO process_line_pvt;
3104: RAISE fnd_api.g_exc_unexpected_error;
3105: END IF;
3106:
3107: IF (is_debug) THEN
3108: print_debug('Value of locator id obtained from process_prj_dynamic_locator '||l_dest_locator_id,'Inv_Pick_Release_PVT.Process_Line');

Line 3160: IF l_api_return_status <> fnd_api.g_ret_sts_success OR l_pick_slip_number = -1 THEN

3156: IF (is_debug) THEN
3157: print_debug('l_call_mode'|| l_call_mode, 'Inv_Pick_Release_PVT.Process_Line');
3158: END IF;
3159:
3160: IF l_api_return_status <> fnd_api.g_ret_sts_success OR l_pick_slip_number = -1 THEN
3161: ROLLBACK TO process_line_pvt;
3162: fnd_message.set_name('INV', 'INV_NO_PICK_SLIP_NUMBER');
3163: fnd_msg_pub.ADD;
3164: RAISE fnd_api.g_exc_unexpected_error;

Line 3164: RAISE fnd_api.g_exc_unexpected_error;

3160: IF l_api_return_status <> fnd_api.g_ret_sts_success OR l_pick_slip_number = -1 THEN
3161: ROLLBACK TO process_line_pvt;
3162: fnd_message.set_name('INV', 'INV_NO_PICK_SLIP_NUMBER');
3163: fnd_msg_pub.ADD;
3164: RAISE fnd_api.g_exc_unexpected_error;
3165: END IF;
3166: IF ( l_pick_slip_mode <> 'I' ) THEN
3167: WSH_INV_INTEGRATION_GRP.FIND_PRINTER
3168: ( p_subinventory => l_mold_sub_code

Line 3174: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

3170: , x_error_message => l_api_error_msg
3171: , x_api_Status => l_api_return_status
3172: ) ;
3173:
3174: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
3175: IF (is_debug) THEN
3176: print_debug('return error from WSH_INV_INTEGRATION.find_printer','Inv_Pick_Release_Pvt.Process_Line');
3177: END IF;
3178: RAISE fnd_api.g_exc_unexpected_error;

Line 3178: RAISE fnd_api.g_exc_unexpected_error;

3174: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
3175: IF (is_debug) THEN
3176: print_debug('return error from WSH_INV_INTEGRATION.find_printer','Inv_Pick_Release_Pvt.Process_Line');
3177: END IF;
3178: RAISE fnd_api.g_exc_unexpected_error;
3179: END IF;
3180: END IF ;
3181: -- Assign the pick slip number to the record in MTL_MATERIAL_TRANSACTIONS_TEMP
3182: UPDATE mtl_material_transactions_temp

Line 3196: IF l_ready_to_print = fnd_api.g_true

3192: -- picking is allowed) commit
3193: -- and print at this point.
3194: -- Bug 1663376 - Don't Commit if Ship_set_Id is not null,
3195: -- since we need to be able to rollback
3196: IF l_ready_to_print = fnd_api.g_true
3197: AND p_allow_partial_pick = fnd_api.g_true
3198: AND p_mo_line_rec.ship_set_id IS NULL
3199: AND p_mo_line_rec.ship_model_id IS NULL
3200: AND l_call_mode IS NULL THEN

Line 3197: AND p_allow_partial_pick = fnd_api.g_true

3193: -- and print at this point.
3194: -- Bug 1663376 - Don't Commit if Ship_set_Id is not null,
3195: -- since we need to be able to rollback
3196: IF l_ready_to_print = fnd_api.g_true
3197: AND p_allow_partial_pick = fnd_api.g_true
3198: AND p_mo_line_rec.ship_set_id IS NULL
3199: AND p_mo_line_rec.ship_model_id IS NULL
3200: AND l_call_mode IS NULL THEN
3201: COMMIT WORK;

Line 3208: raise fnd_api.g_exc_unexpected_error;

3204: IF NOT l_return_value THEN
3205: If is_debug THEN
3206: print_debug('Error setting header cache','Inv_Pick_Release_PVT.Process_Line');
3207: End If;
3208: raise fnd_api.g_exc_unexpected_error;
3209: END IF;
3210: l_request_number := INV_CACHE.mtrh_rec.request_number;
3211:
3212: IF g_request_number is NOT NULL and

Line 3228: x_return_status := fnd_api.g_ret_sts_error;

3224: IF is_debug THEN
3225: print_debug('No Data found - document set',
3226: 'Inv_Pick_Release_PVT.Process_Line');
3227: END IF;
3228: x_return_status := fnd_api.g_ret_sts_error;
3229: RAISE fnd_api.g_exc_error;
3230: END;
3231: g_request_number := l_request_number;
3232: g_report_set_id := l_report_set_id;

Line 3229: RAISE fnd_api.g_exc_error;

3225: print_debug('No Data found - document set',
3226: 'Inv_Pick_Release_PVT.Process_Line');
3227: END IF;
3228: x_return_status := fnd_api.g_ret_sts_error;
3229: RAISE fnd_api.g_exc_error;
3230: END;
3231: g_request_number := l_request_number;
3232: g_report_set_id := l_report_set_id;
3233: END IF;

Line 3241: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN

3237: , p_organization_id => p_mo_line_rec.organization_id
3238: , x_api_status => l_api_return_status
3239: , x_error_message => l_api_error_msg
3240: );
3241: IF l_api_return_status <> fnd_api.g_ret_sts_success THEN
3242: ROLLBACK TO process_line_pvt;
3243: fnd_message.set_name('INV', 'INV_PRINT_PICK_SLIP_FAILED');
3244: fnd_message.set_token('PICK_SLIP_NUM', TO_CHAR(l_pick_slip_number));
3245: fnd_msg_pub.ADD;

Line 3246: RAISE fnd_api.g_exc_unexpected_error;

3242: ROLLBACK TO process_line_pvt;
3243: fnd_message.set_name('INV', 'INV_PRINT_PICK_SLIP_FAILED');
3244: fnd_message.set_token('PICK_SLIP_NUM', TO_CHAR(l_pick_slip_number));
3245: fnd_msg_pub.ADD;
3246: RAISE fnd_api.g_exc_unexpected_error;
3247: END IF;
3248: END IF;
3249: END IF; -- end the patchset J and WMS org check
3250: END IF;

Line 3260: IF x_return_status = fnd_api.g_ret_sts_success

3256: END IF; -- if l_num_detail_rec > 0
3257:
3258: -- If the line was only partially detailed and the API was about to return success,
3259: -- set the return status to 'P' (for partial) instead.
3260: IF x_return_status = fnd_api.g_ret_sts_success
3261: AND l_partially_detailed = 1 THEN
3262: IF (is_debug) THEN
3263: print_debug('x_return_status is '|| x_return_status, 'Inv_Pick_Release_PVT.Process_Line');
3264: END IF;

Line 3280: IF p_commit = fnd_api.g_true

3276:
3277: --x_detail_rec_count := l_num_detail_recs;
3278: -- Standard call to commit
3279: <>
3280: IF p_commit = fnd_api.g_true
3281: AND p_allow_partial_pick = fnd_api.g_true THEN
3282: COMMIT;
3283: END IF;
3284: print_debug('Commit? is '|| p_commit, 'Inv_Pick_Release_PVT.Process_Line');

Line 3281: AND p_allow_partial_pick = fnd_api.g_true THEN

3277: --x_detail_rec_count := l_num_detail_recs;
3278: -- Standard call to commit
3279: <>
3280: IF p_commit = fnd_api.g_true
3281: AND p_allow_partial_pick = fnd_api.g_true THEN
3282: COMMIT;
3283: END IF;
3284: print_debug('Commit? is '|| p_commit, 'Inv_Pick_Release_PVT.Process_Line');
3285:

Line 3288: WHEN fnd_api.g_exc_error THEN

3284: print_debug('Commit? is '|| p_commit, 'Inv_Pick_Release_PVT.Process_Line');
3285:
3286: x_detail_rec_count := l_num_detail_recs;
3287: EXCEPTION
3288: WHEN fnd_api.g_exc_error THEN
3289: x_return_status := fnd_api.g_ret_sts_error;
3290: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
3291: WHEN fnd_api.g_exc_unexpected_error THEN
3292: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 3289: x_return_status := fnd_api.g_ret_sts_error;

3285:
3286: x_detail_rec_count := l_num_detail_recs;
3287: EXCEPTION
3288: WHEN fnd_api.g_exc_error THEN
3289: x_return_status := fnd_api.g_ret_sts_error;
3290: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
3291: WHEN fnd_api.g_exc_unexpected_error THEN
3292: x_return_status := fnd_api.g_ret_sts_unexp_error;
3293: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);

Line 3291: WHEN fnd_api.g_exc_unexpected_error THEN

3287: EXCEPTION
3288: WHEN fnd_api.g_exc_error THEN
3289: x_return_status := fnd_api.g_ret_sts_error;
3290: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
3291: WHEN fnd_api.g_exc_unexpected_error THEN
3292: x_return_status := fnd_api.g_ret_sts_unexp_error;
3293: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
3294: WHEN OTHERS THEN
3295: x_return_status := fnd_api.g_ret_sts_unexp_error;

Line 3292: x_return_status := fnd_api.g_ret_sts_unexp_error;

3288: WHEN fnd_api.g_exc_error THEN
3289: x_return_status := fnd_api.g_ret_sts_error;
3290: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
3291: WHEN fnd_api.g_exc_unexpected_error THEN
3292: x_return_status := fnd_api.g_ret_sts_unexp_error;
3293: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
3294: WHEN OTHERS THEN
3295: x_return_status := fnd_api.g_ret_sts_unexp_error;
3296:

Line 3295: x_return_status := fnd_api.g_ret_sts_unexp_error;

3291: WHEN fnd_api.g_exc_unexpected_error THEN
3292: x_return_status := fnd_api.g_ret_sts_unexp_error;
3293: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
3294: WHEN OTHERS THEN
3295: x_return_status := fnd_api.g_ret_sts_unexp_error;
3296:
3297: IF fnd_msg_pub.check_msg_level(fnd_msg_pub.g_msg_lvl_unexp_error) THEN
3298: fnd_msg_pub.add_exc_msg(g_pkg_name, l_api_name);
3299: END IF;