118: IF p_token3 is NOT NULL THEN
119: fnd_message.set_token('TOKEN3',p_token3);
120: END IF;
121:
122: FND_MSG_PUB.Add;
123: l_text := substrb(fnd_message.get,1,2000);
124: g_error_count := g_error_count+1;
125: g_errors_rec.extend(1);
126: g_errors_rec(g_error_count).ERROR_NUMBER := g_error_count;
331:
332: EXCEPTION
333: WHEN fnd_api.g_exc_error THEN
334: x_return_status := fnd_api.g_ret_sts_error;
335: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
336: WHEN fnd_api.g_exc_unexpected_error THEN
337: x_return_status := fnd_api.g_ret_sts_unexp_error;
338: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
339: WHEN others THEN
334: x_return_status := fnd_api.g_ret_sts_error;
335: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
336: WHEN fnd_api.g_exc_unexpected_error THEN
337: x_return_status := fnd_api.g_ret_sts_unexp_error;
338: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
339: WHEN others THEN
340: x_return_status := fnd_api.g_ret_sts_unexp_error;
341: logerrors('Exception at '||g_pkg_name || '.' || l_api_name ||' is '||sqlerrm);
342: x_msg_count := 1;
459:
460: EXCEPTION
461: WHEN fnd_api.g_exc_error THEN
462: x_return_status := fnd_api.g_ret_sts_error;
463: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
464: WHEN fnd_api.g_exc_unexpected_error THEN
465: x_return_status := fnd_api.g_ret_sts_unexp_error;
466: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
467: WHEN others THEN
462: x_return_status := fnd_api.g_ret_sts_error;
463: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
464: WHEN fnd_api.g_exc_unexpected_error THEN
465: x_return_status := fnd_api.g_ret_sts_unexp_error;
466: fnd_msg_pub.count_and_get(p_count => x_msg_count, p_data => x_msg_data);
467: WHEN others THEN
468: x_return_status := fnd_api.g_ret_sts_unexp_error;
469: logerrors('Exception at '||g_pkg_name || '.' || l_api_name ||' is '||sqlerrm);
470: x_msg_count := 1;
596: END IF;
597:
598: -- Initialize message list if p_init_msg_list is set to TRUE
599: IF fnd_api.to_boolean(p_init_msg_list) THEN
600: fnd_msg_pub.initialize;
601: END IF;
602:
603: -- Initialize API return status to success
604: l_return_status := fnd_api.g_ret_sts_success;
1127: x_msg_data => l_msg_data);
1128:
1129: IF l_return_status <> 'S' THEN
1130: fnd_message.set_name('LNS', 'LNS_DISTRIBUTION_INVALID');
1131: fnd_msg_pub.ADD;
1132: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1133: RAISE fnd_api.g_exc_error;
1134: END IF;
1135:
1128:
1129: IF l_return_status <> 'S' THEN
1130: fnd_message.set_name('LNS', 'LNS_DISTRIBUTION_INVALID');
1131: fnd_msg_pub.ADD;
1132: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1133: RAISE fnd_api.g_exc_error;
1134: END IF;
1135:
1136: logmessage(fnd_log.level_unexpected, 'Distributions created successfully');
1347: );
1348:
1349: IF l_return_status <> 'S' THEN
1350: fnd_message.set_name('LNS', 'LNS_APPL_CR_FAIL');
1351: fnd_msg_pub.ADD;
1352: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1353: RAISE fnd_api.g_exc_error;
1354: END IF;
1355:
1348:
1349: IF l_return_status <> 'S' THEN
1350: fnd_message.set_name('LNS', 'LNS_APPL_CR_FAIL');
1351: fnd_msg_pub.ADD;
1352: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1353: RAISE fnd_api.g_exc_error;
1354: END IF;
1355:
1356: logmessage(fnd_log.level_unexpected, 'Principal paid successfully');
1379: );
1380:
1381: IF l_return_status <> 'S' THEN
1382: fnd_message.set_name('LNS', 'LNS_APPL_CR_FAIL');
1383: fnd_msg_pub.ADD;
1384: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1385: RAISE fnd_api.g_exc_error;
1386: END IF;
1387:
1380:
1381: IF l_return_status <> 'S' THEN
1382: fnd_message.set_name('LNS', 'LNS_APPL_CR_FAIL');
1383: fnd_msg_pub.ADD;
1384: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1385: RAISE fnd_api.g_exc_error;
1386: END IF;
1387:
1388: logmessage(fnd_log.level_unexpected, 'Interest paid successfully');
1411: );
1412:
1413: IF l_return_status <> 'S' THEN
1414: fnd_message.set_name('LNS', 'LNS_APPL_CR_FAIL');
1415: fnd_msg_pub.ADD;
1416: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1417: RAISE fnd_api.g_exc_error;
1418: END IF;
1419:
1412:
1413: IF l_return_status <> 'S' THEN
1414: fnd_message.set_name('LNS', 'LNS_APPL_CR_FAIL');
1415: fnd_msg_pub.ADD;
1416: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1417: RAISE fnd_api.g_exc_error;
1418: END IF;
1419:
1420: logmessage(fnd_log.level_unexpected, 'Fee paid successfully');
1446:
1447: IF l_return_status <> 'S' THEN
1448: -- LogMessage(FND_LOG.LEVEL_UNEXPECTED, 'ERROR: Failed to update term object.');
1449: fnd_message.set_name('LNS', 'LNS_IMRT_FAIL_UPD_TERM');
1450: fnd_msg_pub.ADD;
1451: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1452: RAISE fnd_api.g_exc_error;
1453: END IF;
1454:
1447: IF l_return_status <> 'S' THEN
1448: -- LogMessage(FND_LOG.LEVEL_UNEXPECTED, 'ERROR: Failed to update term object.');
1449: fnd_message.set_name('LNS', 'LNS_IMRT_FAIL_UPD_TERM');
1450: fnd_msg_pub.ADD;
1451: logmessage(fnd_log.level_unexpected, fnd_msg_pub.GET(p_encoded => 'F'));
1452: RAISE fnd_api.g_exc_error;
1453: END IF;
1454:
1455: logmessage(fnd_log.level_unexpected, 'Term object updated successfully');
1514: --InsertErrors;
1515: ROLLBACK TO import_loan;
1516: LogMessage(FND_LOG.LEVEL_UNEXPECTED, 'Rollbacked');
1517: X_RETURN_STATUS := 'E';
1518: FND_MSG_PUB.Count_And_Get(p_count => x_msg_count, p_data => x_msg_data);
1519: END IMPORT_LOAN;
1520:
1521:
1522: