DBA Data[Home] [Help]

APPS.OKL_AM_ASSET_DISPOSE_PVT dependencies on OKC_API

Line 291: okc_api.set_message(p_app_name => 'OKL',

287: IF l_return_status <> okl_api.g_ret_sts_success
288: THEN
289: -- Error occurred when creating accounting entries for transaction TRX_TYPE.
290: --currency conversion rate was not found in Oracle GL
291: okc_api.set_message(p_app_name => 'OKL',
292: p_msg_name => 'OKL_LLA_CONV_RATE_NOT_FOUND',
293: p_token1 => 'FROM_CURRENCY',
294: p_token1_value => l_contract_currency,
295: p_token2 => 'TO_CURRENCY',

Line 912: p_init_msg_list => OKC_API.G_FALSE,

908: -- rmunjulu EDAT -- Set new parameters with dates ------ end +++++++
909:
910: fa_adjustment_pub.do_adjustment(
911: p_api_version => p_api_version,
912: p_init_msg_list => OKC_API.G_FALSE,
913: p_commit => FND_API.G_FALSE,
914: p_validation_level => FND_API.G_VALID_LEVEL_FULL,
915: p_calling_fn => NULL,
916: x_return_status => x_return_status,

Line 931: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN

927: x_asset_deprn_rec_new => l_asset_deprn_rec_new,
928: x_asset_deprn_mrc_tbl_new => l_asset_deprn_mrc_tbl_new,
929: p_group_reclass_options_rec => l_group_reclass_options_rec);
930:
931: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
932:
933: -- Error updating asset cost for asset ASSET_NUMBER in BOOK_CLASS book BOOK.
934: OKC_API.set_message( p_app_name => 'OKL',
935: p_msg_name => 'OKL_AM_ADJ_TRANS_FAILED',

Line 934: OKC_API.set_message( p_app_name => 'OKL',

930:
931: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
932:
933: -- Error updating asset cost for asset ASSET_NUMBER in BOOK_CLASS book BOOK.
934: OKC_API.set_message( p_app_name => 'OKL',
935: p_msg_name => 'OKL_AM_ADJ_TRANS_FAILED',
936: p_token1 => 'ASSET_NUMBER',
937: p_token1_value => p_asset_number,
938: p_token2 => 'BOOK_CLASS',

Line 1019: p_init_msg_list => OKC_API.G_FALSE,

1015:
1016: l_asset_dist_tbl.DELETE;
1017:
1018: FA_RETIREMENT_PUB.do_retirement( p_api_version => p_api_version,
1019: p_init_msg_list => OKC_API.G_FALSE,
1020: p_commit => FND_API.G_FALSE,
1021: p_validation_level => FND_API.G_VALID_LEVEL_FULL,
1022: p_calling_fn => NULL,
1023: x_return_status => x_return_status,

Line 1035: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN

1031: p_subcomp_tbl => l_subcomp_tbl,
1032: p_inv_tbl => l_inv_tbl);
1033:
1034:
1035: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1036:
1037: -- Error retiring asset ASSET_NUMBER in book BOOK. Retirement transaction was not performed for this asset in Fixed Assets.
1038: OKC_API.set_message( p_app_name => 'OKL',
1039: p_msg_name => 'OKL_AM_RET_TRANS_FAILED',

Line 1038: OKC_API.set_message( p_app_name => 'OKL',

1034:
1035: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1036:
1037: -- Error retiring asset ASSET_NUMBER in book BOOK. Retirement transaction was not performed for this asset in Fixed Assets.
1038: OKC_API.set_message( p_app_name => 'OKL',
1039: p_msg_name => 'OKL_AM_RET_TRANS_FAILED',
1040: p_token1 => 'ASSET_NUMBER',
1041: p_token1_value => p_asset_number,
1042: p_token2 => 'BOOK_CLASS',

Line 1200: p_init_msg_list => OKC_API.G_FALSE,

1196: -- rmunjulu EDAT -- Set new parameters with dates ------ end +++++++
1197:
1198: fa_adjustment_pub.do_adjustment(
1199: p_api_version => p_api_version,
1200: p_init_msg_list => OKC_API.G_FALSE,
1201: p_commit => FND_API.G_FALSE,
1202: p_validation_level => FND_API.G_VALID_LEVEL_FULL,
1203: p_calling_fn => NULL,
1204: x_return_status => x_return_status,

Line 1219: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN

1215: x_asset_deprn_rec_new => l_asset_deprn_rec_new,
1216: x_asset_deprn_mrc_tbl_new => l_asset_deprn_mrc_tbl_new,
1217: p_group_reclass_options_rec => l_group_reclass_options_rec);
1218:
1219: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1220:
1221: -- Error updating asset cost for asset ASSET_NUMBER in BOOK_CLASS book BOOK.
1222: OKC_API.set_message( p_app_name => 'OKL',
1223: p_msg_name => 'OKL_AM_ADJ_TRANS_FAILED',

Line 1222: OKC_API.set_message( p_app_name => 'OKL',

1218:
1219: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1220:
1221: -- Error updating asset cost for asset ASSET_NUMBER in BOOK_CLASS book BOOK.
1222: OKC_API.set_message( p_app_name => 'OKL',
1223: p_msg_name => 'OKL_AM_ADJ_TRANS_FAILED',
1224: p_token1 => 'ASSET_NUMBER',
1225: p_token1_value => p_asset_number,
1226: p_token2 => 'BOOK_CLASS',

Line 1302: p_init_msg_list => OKC_API.G_FALSE,

1298:
1299:
1300:
1301: FA_RETIREMENT_PUB.do_retirement( p_api_version => p_api_version,
1302: p_init_msg_list => OKC_API.G_FALSE,
1303: p_commit => FND_API.G_FALSE,
1304: p_validation_level => FND_API.G_VALID_LEVEL_FULL,
1305: p_calling_fn => NULL,
1306: x_return_status => x_return_status,

Line 1318: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN

1314: p_subcomp_tbl => l_subcomp_tbl,
1315: p_inv_tbl => l_inv_tbl);
1316:
1317: -- SECHAWLA Bug # 2701440 : Added this message
1318: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1319: --SECHAWLA 23-DEC-02 Bug # 2701440 : Added BOOK_CLASS token
1320: -- Error retiring asset ASSET_NUMBER in book BOOK. Retirement transaction was not performed for this asset in Fixed Assets.
1321: OKC_API.set_message( p_app_name => 'OKL',
1322: p_msg_name => 'OKL_AM_RET_TRANS_FAILED',

Line 1321: OKC_API.set_message( p_app_name => 'OKL',

1317: -- SECHAWLA Bug # 2701440 : Added this message
1318: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1319: --SECHAWLA 23-DEC-02 Bug # 2701440 : Added BOOK_CLASS token
1320: -- Error retiring asset ASSET_NUMBER in book BOOK. Retirement transaction was not performed for this asset in Fixed Assets.
1321: OKC_API.set_message( p_app_name => 'OKL',
1322: p_msg_name => 'OKL_AM_RET_TRANS_FAILED',
1323: p_token1 => 'ASSET_NUMBER',
1324: p_token1_value => p_asset_number,
1325: p_token2 => 'BOOK_CLASS',

Line 1482: p_init_msg_list => OKC_API.G_FALSE,

1478: -- rmunjulu EDAT -- Set new parameters with dates ------ end +++++++
1479:
1480: fa_adjustment_pub.do_adjustment(
1481: p_api_version => p_api_version,
1482: p_init_msg_list => OKC_API.G_FALSE,
1483: p_commit => FND_API.G_FALSE,
1484: p_validation_level => FND_API.G_VALID_LEVEL_FULL,
1485: p_calling_fn => NULL,
1486: x_return_status => x_return_status,

Line 1501: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN

1497: x_asset_deprn_rec_new => l_asset_deprn_rec_new,
1498: x_asset_deprn_mrc_tbl_new => l_asset_deprn_mrc_tbl_new,
1499: p_group_reclass_options_rec => l_group_reclass_options_rec);
1500:
1501: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1502:
1503: -- Error updating asset cost for asset ASSET_NUMBER in BOOK_CLASS book BOOK.
1504: OKC_API.set_message( p_app_name => 'OKL',
1505: p_msg_name => 'OKL_AM_ADJ_TRANS_FAILED',

Line 1504: OKC_API.set_message( p_app_name => 'OKL',

1500:
1501: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1502:
1503: -- Error updating asset cost for asset ASSET_NUMBER in BOOK_CLASS book BOOK.
1504: OKC_API.set_message( p_app_name => 'OKL',
1505: p_msg_name => 'OKL_AM_ADJ_TRANS_FAILED',
1506: p_token1 => 'ASSET_NUMBER',
1507: p_token1_value => p_asset_number,
1508: p_token2 => 'BOOK_CLASS',

Line 1598: p_init_msg_list => OKC_API.G_FALSE,

1594: END IF;
1595:
1596:
1597: FA_RETIREMENT_PUB.do_retirement( p_api_version => p_api_version,
1598: p_init_msg_list => OKC_API.G_FALSE,
1599: p_commit => FND_API.G_FALSE,
1600: p_validation_level => FND_API.G_VALID_LEVEL_FULL,
1601: p_calling_fn => NULL,
1602: x_return_status => x_return_status,

Line 1614: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN

1610: p_subcomp_tbl => l_subcomp_tbl,
1611: p_inv_tbl => l_inv_tbl);
1612:
1613: -- SECHAWLA Bug # 2701440 : Added this message
1614: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1615:
1616: --SECHAWLA 23-DEC-02 Bug # 2701440 : Added BOOK_CLASS token
1617: -- Error retiring asset ASSET_NUMBER in book BOOK. Retirement transaction was not performed for this asset in Fixed Assets.
1618: OKC_API.set_message( p_app_name => 'OKL',

Line 1618: OKC_API.set_message( p_app_name => 'OKL',

1614: IF x_return_status <> OKC_API.G_RET_STS_SUCCESS THEN
1615:
1616: --SECHAWLA 23-DEC-02 Bug # 2701440 : Added BOOK_CLASS token
1617: -- Error retiring asset ASSET_NUMBER in book BOOK. Retirement transaction was not performed for this asset in Fixed Assets.
1618: OKC_API.set_message( p_app_name => 'OKL',
1619: p_msg_name => 'OKL_AM_RET_TRANS_FAILED',
1620: p_token1 => 'ASSET_NUMBER',
1621: p_token1_value => p_asset_number,
1622: p_token2 => 'BOOK_CLASS',

Line 1887: l_return_status VARCHAR2(1) := OKC_API.G_RET_STS_SUCCESS;

1883: l_cost NUMBER;
1884: --SECHAWLA 21-NOV-2003 3262519 : end new declarations
1885:
1886:
1887: l_return_status VARCHAR2(1) := OKC_API.G_RET_STS_SUCCESS;
1888: l_tsu_code VARCHAR2(30);
1889: l_try_id OKL_TRX_TYPES_V.id%TYPE;
1890: lp_thpv_rec thpv_rec_type;
1891: lp_thpv_empty_rec thpv_rec_type;

Line 1977: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

1973: p_api_version,
1974: '_PVT',
1975: x_return_status);
1976:
1977: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
1978: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
1979: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
1980: RAISE OKC_API.G_EXCEPTION_ERROR;
1981: END IF;

Line 1978: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

1974: '_PVT',
1975: x_return_status);
1976:
1977: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
1978: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
1979: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
1980: RAISE OKC_API.G_EXCEPTION_ERROR;
1981: END IF;
1982:

Line 1979: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN

1975: x_return_status);
1976:
1977: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
1978: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
1979: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
1980: RAISE OKC_API.G_EXCEPTION_ERROR;
1981: END IF;
1982:
1983: -- Get the sysdate

Line 1980: RAISE OKC_API.G_EXCEPTION_ERROR;

1976:
1977: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
1978: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
1979: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
1980: RAISE OKC_API.G_EXCEPTION_ERROR;
1981: END IF;
1982:
1983: -- Get the sysdate
1984: SELECT SYSDATE INTO l_sys_date FROM DUAL;

Line 2013: OKC_API.set_message( p_app_name => 'OKC',

2009:
2010: IF p_financial_asset_id IS NULL OR p_financial_asset_id = OKL_API.G_MISS_NUM THEN
2011: x_return_status := OKL_API.G_RET_STS_ERROR;
2012: -- Finacial Asset id is a required parameter
2013: OKC_API.set_message( p_app_name => 'OKC',
2014: p_msg_name => G_REQUIRED_VALUE,
2015: p_token1 => G_COL_NAME_TOKEN,
2016: p_token1_value => 'FINANCIAL_ASSET_ID');
2017:

Line 2019: RAISE OKC_API.G_EXCEPTION_ERROR;

2015: p_token1 => G_COL_NAME_TOKEN,
2016: p_token1_value => 'FINANCIAL_ASSET_ID');
2017:
2018:
2019: RAISE OKC_API.G_EXCEPTION_ERROR;
2020: END IF;
2021:
2022: -- RRAVIKIR Legal Entity Changes
2023: IF (p_legal_entity_id is null or p_legal_entity_id = OKC_API.G_MISS_NUM) THEN

Line 2023: IF (p_legal_entity_id is null or p_legal_entity_id = OKC_API.G_MISS_NUM) THEN

2019: RAISE OKC_API.G_EXCEPTION_ERROR;
2020: END IF;
2021:
2022: -- RRAVIKIR Legal Entity Changes
2023: IF (p_legal_entity_id is null or p_legal_entity_id = OKC_API.G_MISS_NUM) THEN
2024: OKL_API.SET_MESSAGE(p_app_name => g_app_name,
2025: p_msg_name => g_required_value,
2026: p_token1 => g_col_name_token,
2027: p_token1_value => 'legal_entity_id');

Line 2028: RAISE OKC_API.G_EXCEPTION_ERROR;

2024: OKL_API.SET_MESSAGE(p_app_name => g_app_name,
2025: p_msg_name => g_required_value,
2026: p_token1 => g_col_name_token,
2027: p_token1_value => 'legal_entity_id');
2028: RAISE OKC_API.G_EXCEPTION_ERROR;
2029: END IF;
2030: -- Legal Entity Changes End
2031:
2032: --SECHAWLA 21-NOV-2003 3262519 : Added the following validation

Line 2038: OKC_API.set_message( p_app_name => 'OKC',

2034: FETCH l_okclines_csr INTO l_dummy;
2035: IF l_okclines_csr%NOTFOUND THEN
2036: x_return_status := OKL_API.G_RET_STS_ERROR;
2037: -- Finacial Asset id is invalid
2038: OKC_API.set_message( p_app_name => 'OKC',
2039: p_msg_name => G_INVALID_VALUE,
2040: p_token1 => G_COL_NAME_TOKEN,
2041: p_token1_value => 'FINANCIAL_ASSET_ID');
2042:

Line 2043: RAISE OKC_API.G_EXCEPTION_ERROR;

2039: p_msg_name => G_INVALID_VALUE,
2040: p_token1 => G_COL_NAME_TOKEN,
2041: p_token1_value => 'FINANCIAL_ASSET_ID');
2042:
2043: RAISE OKC_API.G_EXCEPTION_ERROR;
2044: END IF;
2045: CLOSE l_okclines_csr;
2046: --SECHAWLA 21-NOV-2003 3262519 : end
2047:

Line 2057: OKC_API.set_message( p_app_name => 'OKC',

2053: l_proceeds_of_sale := 0;
2054: /*
2055: x_return_status := OKL_API.G_RET_STS_ERROR;
2056: -- proceeds_of_sale is required
2057: OKC_API.set_message( p_app_name => 'OKC',
2058: p_msg_name => G_REQUIRED_VALUE,
2059: p_token1 => G_COL_NAME_TOKEN,
2060: p_token1_value => 'PROCEEDS_OF_SALE');
2061:

Line 2063: RAISE OKC_API.G_EXCEPTION_ERROR;

2059: p_token1 => G_COL_NAME_TOKEN,
2060: p_token1_value => 'PROCEEDS_OF_SALE');
2061:
2062:
2063: RAISE OKC_API.G_EXCEPTION_ERROR;
2064: */
2065: END IF;
2066:
2067: -- SECHAWLA 11-MAR-03 : Allow negative amount

Line 2072: OKC_API.set_message( p_app_name => 'OKC',

2068: /*
2069: IF p_proceeds_of_sale < 0 THEN
2070: x_return_status := OKL_API.G_RET_STS_ERROR;
2071: -- proceeds_of_sale is invalid
2072: OKC_API.set_message( p_app_name => 'OKC',
2073: p_msg_name => G_INVALID_VALUE,
2074: p_token1 => G_COL_NAME_TOKEN,
2075: p_token1_value => 'PROCEEDS_OF_SALE');
2076:

Line 2078: RAISE OKC_API.G_EXCEPTION_ERROR;

2074: p_token1 => G_COL_NAME_TOKEN,
2075: p_token1_value => 'PROCEEDS_OF_SALE');
2076:
2077:
2078: RAISE OKC_API.G_EXCEPTION_ERROR;
2079: END IF;
2080: */
2081:
2082: IF p_quantity IS NOT NULL THEN

Line 2086: OKC_API.set_message( p_app_name => 'OKC',

2082: IF p_quantity IS NOT NULL THEN
2083: IF p_quantity < 0 THEN
2084: x_return_status := OKL_API.G_RET_STS_ERROR;
2085: -- Quantity is invalid
2086: OKC_API.set_message( p_app_name => 'OKC',
2087: p_msg_name => G_INVALID_VALUE,
2088: p_token1 => G_COL_NAME_TOKEN,
2089: p_token1_value => 'QUANTITY');
2090:

Line 2092: RAISE OKC_API.G_EXCEPTION_ERROR;

2088: p_token1 => G_COL_NAME_TOKEN,
2089: p_token1_value => 'QUANTITY');
2090:
2091:
2092: RAISE OKC_API.G_EXCEPTION_ERROR;
2093: END IF;
2094: IF trunc(p_quantity) <> p_quantity THEN
2095: x_return_status := OKL_API.G_RET_STS_ERROR;
2096: -- Units retired should be a whole number.

Line 2097: OKC_API.set_message( p_app_name => 'OKL',

2093: END IF;
2094: IF trunc(p_quantity) <> p_quantity THEN
2095: x_return_status := OKL_API.G_RET_STS_ERROR;
2096: -- Units retired should be a whole number.
2097: OKC_API.set_message( p_app_name => 'OKL',
2098: p_msg_name => 'OKL_AM_WHOLE_UNITS_ERR');
2099: RAISE OKC_API.G_EXCEPTION_ERROR;
2100: END IF;
2101: END IF;

Line 2099: RAISE OKC_API.G_EXCEPTION_ERROR;

2095: x_return_status := OKL_API.G_RET_STS_ERROR;
2096: -- Units retired should be a whole number.
2097: OKC_API.set_message( p_app_name => 'OKL',
2098: p_msg_name => 'OKL_AM_WHOLE_UNITS_ERR');
2099: RAISE OKC_API.G_EXCEPTION_ERROR;
2100: END IF;
2101: END IF;
2102:
2103: --SECHAWLA 21-NOV-2003 3262519 : Added the following code to get the deal type and tax owner

Line 2111: OKC_API.set_message( p_app_name => 'OKC',

2107: FETCH l_dealtype_csr INTO l_chr_id, l_deal_type, l_contract_number;
2108: IF l_dealtype_csr%NOTFOUND THEN
2109: x_return_status := OKL_API.G_RET_STS_ERROR;
2110: -- chr id is invalid
2111: OKC_API.set_message( p_app_name => 'OKC',
2112: p_msg_name => G_INVALID_VALUE,
2113: p_token1 => G_COL_NAME_TOKEN,
2114: p_token1_value => 'CHR_ID');
2115:

Line 2116: RAISE OKC_API.G_EXCEPTION_ERROR;

2112: p_msg_name => G_INVALID_VALUE,
2113: p_token1 => G_COL_NAME_TOKEN,
2114: p_token1_value => 'CHR_ID');
2115:
2116: RAISE OKC_API.G_EXCEPTION_ERROR;
2117: END IF;
2118: CLOSE l_dealtype_csr;
2119:
2120: IF l_deal_type IN ('LEASEDF','LEASEST') THEN

Line 2132: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2128: ,x_return_status => x_return_status
2129: ,x_msg_count => x_msg_count
2130: ,x_msg_data => x_msg_data);
2131:
2132: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2133: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2134: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2135: RAISE OKC_API.G_EXCEPTION_ERROR;
2136: END IF;

Line 2133: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2129: ,x_msg_count => x_msg_count
2130: ,x_msg_data => x_msg_data);
2131:
2132: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2133: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2134: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2135: RAISE OKC_API.G_EXCEPTION_ERROR;
2136: END IF;
2137:

Line 2134: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2130: ,x_msg_data => x_msg_data);
2131:
2132: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2133: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2134: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2135: RAISE OKC_API.G_EXCEPTION_ERROR;
2136: END IF;
2137:
2138: -- check if tax owner is defined

Line 2135: RAISE OKC_API.G_EXCEPTION_ERROR;

2131:
2132: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2133: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2134: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2135: RAISE OKC_API.G_EXCEPTION_ERROR;
2136: END IF;
2137:
2138: -- check if tax owner is defined
2139: IF l_rulv_rec.rule_information1 IS NULL OR l_rulv_rec.rule_information1 = OKL_API.G_MISS_CHAR THEN

Line 2147: RAISE OKC_API.G_EXCEPTION_ERROR;

2143: OKL_API.set_message( p_app_name => 'OKL',
2144: p_msg_name => 'OKL_AM_NO_TAX_OWNER',
2145: p_token1 => 'CONTRACT_NUMBER',
2146: p_token1_value => l_contract_number);
2147: RAISE OKC_API.G_EXCEPTION_ERROR;
2148:
2149: ELSE
2150: -- l_rulv_rec.RULE_INFORMATION1 will contain the value 'LESSEE' or 'LESSOR'
2151: l_tax_owner := l_rulv_rec.RULE_INFORMATION1;

Line 2162: OKC_API.set_message( p_app_name => 'OKL',

2158:
2159: IF l_residual_value IS NULL THEN
2160: x_return_status := OKL_API.G_RET_STS_ERROR;
2161: -- Residual value is not defined for the asset
2162: OKC_API.set_message( p_app_name => 'OKL',
2163: p_msg_name => 'OKL_AM_NO_RESIDUAL_VALUE',
2164: p_token1 => 'ASSET_NUMBER',
2165: p_token1_value => l_name);
2166:

Line 2168: RAISE OKC_API.G_EXCEPTION_ERROR;

2164: p_token1 => 'ASSET_NUMBER',
2165: p_token1_value => l_name);
2166:
2167:
2168: RAISE OKC_API.G_EXCEPTION_ERROR;
2169: END IF;
2170:
2171: -- rbruno 5436987 -- start
2172: l_contract_currency_code := OKL_AM_UTIL_PVT.get_chr_currency(l_chr_id);

Line 2200: OKC_API.set_message( p_app_name => 'OKL',

2196:
2197: IF l_residual_value < 0 THEN
2198: x_return_status := OKL_API.G_RET_STS_ERROR;
2199: -- Residual value is negative for the asset
2200: OKC_API.set_message( p_app_name => 'OKL',
2201: p_msg_name => 'OKL_AM_INVALID_RESIDUAL',
2202: p_token1 => 'ASSET_NUMBER',
2203: p_token1_value => l_name);
2204:

Line 2206: RAISE OKC_API.G_EXCEPTION_ERROR;

2202: p_token1 => 'ASSET_NUMBER',
2203: p_token1_value => l_name);
2204:
2205:
2206: RAISE OKC_API.G_EXCEPTION_ERROR;
2207: END IF;
2208: END IF;
2209:
2210:

Line 2245: RAISE OKC_API.G_EXCEPTION_ERROR;

2241: p_token1 => 'ASSET_NUMBER',
2242: p_token1_value => l_name);
2243:
2244:
2245: RAISE OKC_API.G_EXCEPTION_ERROR;
2246:
2247:
2248: ELSIF l_trx_status IN ( 'PROCESSED','CANCELED') THEN
2249: l_delta_cost := 0; -- no cost update required, as cost has already been updated thru off lease trx

Line 2268: OKC_API.set_message( p_app_name => 'OKC',

2264: FETCH l_bookcontrols_csr INTO l_fiscal_year_name;
2265: IF l_bookcontrols_csr%NOTFOUND OR l_fiscal_year_name IS NULL THEN
2266: x_return_status := OKL_API.G_RET_STS_ERROR;
2267: -- Fiscal Year Name is required
2268: OKC_API.set_message( p_app_name => 'OKC',
2269: p_msg_name => G_REQUIRED_VALUE,
2270: p_token1 => G_COL_NAME_TOKEN,
2271: p_token1_value => 'Fiscal Year Name');
2272:

Line 2274: RAISE OKC_API.G_EXCEPTION_ERROR;

2270: p_token1 => G_COL_NAME_TOKEN,
2271: p_token1_value => 'Fiscal Year Name');
2272:
2273:
2274: RAISE OKC_API.G_EXCEPTION_ERROR;
2275: END IF;
2276: CLOSE l_bookcontrols_csr;
2277: fa_cache_pkg.fazcbc_record.fiscal_year_name := l_fiscal_year_name;
2278: -- END IF;

Line 2288: x_return_status := OKC_API.G_RET_STS_ERROR;

2284: p_effective_date => NULL,
2285: x_period_rec => l_period_rec
2286: ) THEN
2287:
2288: x_return_status := OKC_API.G_RET_STS_ERROR;
2289: --Error getting current open period for the book BOOK_TYPE_CODE.
2290: OKL_API.set_message(
2291: p_app_name => 'OKL',
2292: p_msg_name => 'OKL_AM_OPEN_PERIOD_ERR',

Line 2300: RAISE OKC_API.G_EXCEPTION_ERROR;

2296: p_token2_value => l_okxassetlines_rec.book_type_code
2297: );
2298:
2299:
2300: RAISE OKC_API.G_EXCEPTION_ERROR;
2301: END IF;
2302:
2303: --- check period of addition. If 'N' then run retirements
2304: OPEN l_periodofaddition_csr(l_okxassetlines_rec.asset_id, l_okxassetlines_rec.book_type_code,l_period_rec.period_open_date);

Line 2317: x_return_status := OKC_API.G_RET_STS_ERROR;

2313:
2314: IF l_period_of_addition = 'Y' THEN
2315: -- Can nor retire asset ASSET_NUMBER as the asset was added to the book
2316: -- in the current open period. Please retire the asset manually.
2317: x_return_status := OKC_API.G_RET_STS_ERROR;
2318:
2319: OKL_API.set_message( p_app_name => 'OKL',
2320: p_msg_name => 'OKL_AM_RETIRE_MANUALLY',
2321: p_token1 => 'ASSET_NUMBER',

Line 2328: RAISE OKC_API.G_EXCEPTION_ERROR;

2324: p_token2_value => lower(l_okxassetlines_rec.book_class),
2325: p_token3 => 'BOOK_TYPE_CODE',
2326: p_token3_value => l_okxassetlines_rec.book_type_code);
2327:
2328: RAISE OKC_API.G_EXCEPTION_ERROR;
2329:
2330: END IF;
2331: /* ansethur for bug 5664106 -- start
2332: -- SECHAWLA 03-JUN-03 Bug 2999419: Added the following validation

Line 2336: OKC_API.set_message( p_app_name => 'OKL',

2332: -- SECHAWLA 03-JUN-03 Bug 2999419: Added the following validation
2333: IF l_okxassetlines_rec.prorate_convention_code IS NULL THEN
2334: x_return_status := OKL_API.G_RET_STS_ERROR;
2335: -- Unable to find retirement prorate convention for asset ASSET_NUMBER and book BOOK_TYPE_CODE.
2336: OKC_API.set_message( p_app_name => 'OKL',
2337: p_msg_name => 'OKL_AM_NO_PRORATE_CONVENTION',
2338: p_token1 => 'ASSET_NUMBER',
2339: p_token1_value => l_okxassetlines_rec.asset_number,
2340: p_token2 => 'BOOK_CLASS',

Line 2344: RAISE OKC_API.G_EXCEPTION_ERROR;

2340: p_token2 => 'BOOK_CLASS',
2341: p_token2_value => l_okxassetlines_rec.book_class,
2342: p_token3 => 'BOOK_TYPE_CODE',
2343: p_token3_value => l_okxassetlines_rec.book_type_code);
2344: RAISE OKC_API.G_EXCEPTION_ERROR;
2345: END IF;
2346: -- SECHAWLA 03-JUN-03 Bug 2999419 : end new code
2347: */ -- ansethur for bug 5655545 - end
2348:

Line 2392: p_init_msg_list => OKC_API.G_FALSE,

2388:
2389:
2390: do_full_units_retirement(
2391: p_api_version => p_api_version,
2392: p_init_msg_list => OKC_API.G_FALSE,
2393: p_tax_owner => l_tax_owner,
2394: p_delta_cost => l_delta_cost,
2395: p_asset_id => l_okxassetlines_rec.asset_id,
2396: p_asset_number => l_okxassetlines_rec.asset_number,

Line 2411: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2407: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2408: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2409:
2410:
2411: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2412: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2413: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2414: RAISE OKC_API.G_EXCEPTION_ERROR;
2415: END IF;

Line 2412: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2408: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2409:
2410:
2411: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2412: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2413: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2414: RAISE OKC_API.G_EXCEPTION_ERROR;
2415: END IF;
2416:

Line 2413: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2409:
2410:
2411: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2412: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2413: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2414: RAISE OKC_API.G_EXCEPTION_ERROR;
2415: END IF;
2416:
2417: l_units_retired := l_okxassetlines_rec.current_units;

Line 2414: RAISE OKC_API.G_EXCEPTION_ERROR;

2410:
2411: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2412: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2413: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2414: RAISE OKC_API.G_EXCEPTION_ERROR;
2415: END IF;
2416:
2417: l_units_retired := l_okxassetlines_rec.current_units;
2418: ELSE

Line 2464: OKC_API.set_message( p_app_name => 'OKL',

2460:
2461: IF l_dist_quantity > 0 THEN -- quantity to be retired (for non-retired distributions)
2462: -- x_return_status := OKL_API.G_RET_STS_ERROR;
2463: -- Sold quantity is more than the total quantity assigned to asset distributions.
2464: OKC_API.set_message( p_app_name => 'OKL',
2465: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
2466: --RAISE okc_api.G_EXCEPTION_ERROR;
2467: END IF;
2468:

Line 2466: --RAISE okc_api.G_EXCEPTION_ERROR;

2462: -- x_return_status := OKL_API.G_RET_STS_ERROR;
2463: -- Sold quantity is more than the total quantity assigned to asset distributions.
2464: OKC_API.set_message( p_app_name => 'OKL',
2465: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
2466: --RAISE okc_api.G_EXCEPTION_ERROR;
2467: END IF;
2468:
2469: -- SECHAWLA 21-NOV-03 3262519 : Added p_tax_owner and delta cost parameters to the following procedure call
2470:

Line 2474: p_init_msg_list => OKC_API.G_FALSE,

2470:
2471:
2472: do_partial_units_retirement(
2473: p_api_version => p_api_version,
2474: p_init_msg_list => OKC_API.G_FALSE,
2475: p_tax_owner => l_tax_owner,
2476: p_delta_cost => l_delta_cost,
2477: p_asset_id => l_okxassetlines_rec.asset_id,
2478: p_asset_number => l_okxassetlines_rec.asset_number,

Line 2493: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2489: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2490: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2491:
2492:
2493: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2494: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2495: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2496: RAISE OKC_API.G_EXCEPTION_ERROR;
2497: END IF;

Line 2494: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2490: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2491:
2492:
2493: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2494: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2495: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2496: RAISE OKC_API.G_EXCEPTION_ERROR;
2497: END IF;
2498:

Line 2495: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2491:
2492:
2493: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2494: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2495: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2496: RAISE OKC_API.G_EXCEPTION_ERROR;
2497: END IF;
2498:
2499: l_units_retired := l_units_to_be_retired ;

Line 2496: RAISE OKC_API.G_EXCEPTION_ERROR;

2492:
2493: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2494: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2495: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2496: RAISE OKC_API.G_EXCEPTION_ERROR;
2497: END IF;
2498:
2499: l_units_retired := l_units_to_be_retired ;
2500: END IF; --l_non_retired_quantity = l_quantity

Line 2505: OKC_API.set_message( p_app_name => 'OKL',

2501:
2502:
2503: ELSIF l_retired_quantity = l_okxassetlines_rec.current_units AND l_non_retired_quantity = 0 THEN -- retired qty = current units
2504: -- Asset is already fully retired.
2505: OKC_API.set_message( p_app_name => 'OKL',
2506: p_msg_name => 'OKL_AM_ALREADY_RETIRED',
2507: p_token1 => 'ASSET_NUMBER',
2508: p_token1_value => l_okxassetlines_rec.asset_number);
2509: l_already_retired := 'Y';

Line 2550: p_init_msg_list => OKC_API.G_FALSE,

2546:
2547: -- SECHAWLA 21-NOV-03 3262519 : Added p_tax_owner and delta cost parameter to the following procedure call
2548: do_partial_units_retirement(
2549: p_api_version => p_api_version,
2550: p_init_msg_list => OKC_API.G_FALSE,
2551: p_tax_owner => l_tax_owner,
2552: p_delta_cost => l_delta_cost,
2553: p_asset_id => l_okxassetlines_rec.asset_id,
2554: p_asset_number => l_okxassetlines_rec.asset_number,

Line 2569: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2565: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2566: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2567:
2568:
2569: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2570: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2571: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2572: RAISE OKC_API.G_EXCEPTION_ERROR;
2573: END IF;

Line 2570: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2566: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2567:
2568:
2569: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2570: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2571: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2572: RAISE OKC_API.G_EXCEPTION_ERROR;
2573: END IF;
2574:

Line 2571: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2567:
2568:
2569: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2570: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2571: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2572: RAISE OKC_API.G_EXCEPTION_ERROR;
2573: END IF;
2574:
2575: l_units_retired := l_units_to_be_retired;

Line 2572: RAISE OKC_API.G_EXCEPTION_ERROR;

2568:
2569: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2570: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2571: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2572: RAISE OKC_API.G_EXCEPTION_ERROR;
2573: END IF;
2574:
2575: l_units_retired := l_units_to_be_retired;
2576: ELSIF l_retired_quantity > l_okxassetlines_rec.current_units AND l_non_retired_quantity = 0 THEN

Line 2579: OKC_API.set_message( p_app_name => 'OKL',

2575: l_units_retired := l_units_to_be_retired;
2576: ELSIF l_retired_quantity > l_okxassetlines_rec.current_units AND l_non_retired_quantity = 0 THEN
2577: -- x_return_status := OKL_API.G_RET_STS_ERROR;
2578: -- Asset ASSET_NUMBER is already retired with invalid retired quantity which is more than the original quantity.
2579: OKC_API.set_message( p_app_name => 'OKL',
2580: p_msg_name => 'OKL_AM_INVALID_RETIRED_QTY',
2581: p_token1 => 'ASSET_NUMBER',
2582: p_token1_value => l_okxassetlines_rec.asset_number);
2583: -- RAISE okc_api.G_EXCEPTION_ERROR;

Line 2583: -- RAISE okc_api.G_EXCEPTION_ERROR;

2579: OKC_API.set_message( p_app_name => 'OKL',
2580: p_msg_name => 'OKL_AM_INVALID_RETIRED_QTY',
2581: p_token1 => 'ASSET_NUMBER',
2582: p_token1_value => l_okxassetlines_rec.asset_number);
2583: -- RAISE okc_api.G_EXCEPTION_ERROR;
2584:
2585: ELSIF l_retired_quantity < l_okxassetlines_rec.current_units AND l_non_retired_quantity > 0 THEN
2586:
2587:

Line 2631: OKC_API.set_message( p_app_name => 'OKL',

2627: IF l_dist_quantity > 0 THEN
2628: IF l_retired_quantity < l_dist_quantity THEN
2629: -- x_return_status := OKL_API.G_RET_STS_ERROR;
2630: -- Sold quantity is more than the total quantity assigned to asset distributions.
2631: OKC_API.set_message( p_app_name => 'OKL',
2632: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
2633: -- RAISE okc_api.G_EXCEPTION_ERROR;
2634: END IF;
2635: END IF;

Line 2633: -- RAISE okc_api.G_EXCEPTION_ERROR;

2629: -- x_return_status := OKL_API.G_RET_STS_ERROR;
2630: -- Sold quantity is more than the total quantity assigned to asset distributions.
2631: OKC_API.set_message( p_app_name => 'OKL',
2632: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
2633: -- RAISE okc_api.G_EXCEPTION_ERROR;
2634: END IF;
2635: END IF;
2636:
2637: -- SECHAWLA 21-NOV-03 3262519 : Added p_tax_owner and delta cost parameter to the following procedure call

Line 2640: p_init_msg_list => OKC_API.G_FALSE,

2636:
2637: -- SECHAWLA 21-NOV-03 3262519 : Added p_tax_owner and delta cost parameter to the following procedure call
2638: do_partial_units_retirement(
2639: p_api_version => p_api_version,
2640: p_init_msg_list => OKC_API.G_FALSE,
2641: p_tax_owner => l_tax_owner,
2642: p_delta_cost => l_delta_cost,
2643: p_asset_id => l_okxassetlines_rec.asset_id,
2644: p_asset_number => l_okxassetlines_rec.asset_number,

Line 2658: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2654: x_return_status => x_return_status,
2655: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2656: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2657:
2658: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2659: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2660: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2661: RAISE OKC_API.G_EXCEPTION_ERROR;
2662: END IF;

Line 2659: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2655: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2656: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2657:
2658: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2659: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2660: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2661: RAISE OKC_API.G_EXCEPTION_ERROR;
2662: END IF;
2663:

Line 2660: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2656: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2657:
2658: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2659: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2660: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2661: RAISE OKC_API.G_EXCEPTION_ERROR;
2662: END IF;
2663:
2664: l_units_retired := l_units_to_be_retired;

Line 2661: RAISE OKC_API.G_EXCEPTION_ERROR;

2657:
2658: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2659: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2660: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2661: RAISE OKC_API.G_EXCEPTION_ERROR;
2662: END IF;
2663:
2664: l_units_retired := l_units_to_be_retired;
2665:

Line 2688: p_init_msg_list => OKC_API.G_FALSE,

2684:
2685: -- SECHAWLA 21-nov-03 3262519 Added tax owner and delta cost parameters
2686: do_cost_retirement(
2687: p_api_version => p_api_version,
2688: p_init_msg_list => OKC_API.G_FALSE,
2689: p_tax_owner => l_tax_owner,
2690: p_delta_cost => l_delta_cost,
2691: p_asset_id => l_okxassetlines_rec.asset_id,
2692: p_asset_number => l_okxassetlines_rec.asset_number,

Line 2707: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2703: x_return_status => x_return_status,
2704: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2705: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2706:
2707: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2708: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2709: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2710: RAISE OKC_API.G_EXCEPTION_ERROR;
2711: END IF;

Line 2708: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2704: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2705: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2706:
2707: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2708: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2709: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2710: RAISE OKC_API.G_EXCEPTION_ERROR;
2711: END IF;
2712: END IF;

Line 2709: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2705: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2706:
2707: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2708: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2709: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2710: RAISE OKC_API.G_EXCEPTION_ERROR;
2711: END IF;
2712: END IF;
2713: -- SECHAWLA 23-DEC-02 Bug # 2701440 : end new code

Line 2710: RAISE OKC_API.G_EXCEPTION_ERROR;

2706:
2707: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2708: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2709: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2710: RAISE OKC_API.G_EXCEPTION_ERROR;
2711: END IF;
2712: END IF;
2713: -- SECHAWLA 23-DEC-02 Bug # 2701440 : end new code
2714: END IF;

Line 2771: OKC_API.set_message( p_app_name => 'OKL',

2767: IF l_dist_quantity > 0 THEN -- quantity to be retired (for non-retired distributions)
2768:
2769: IF l_retired_dist_units < l_dist_quantity THEN -- retired quantity isn't enough to match up with total qty
2770: -- Sold quantity is more than the total quantity assigned to asset distributions.
2771: OKC_API.set_message( p_app_name => 'OKL',
2772: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
2773: END IF;
2774: l_units_to_be_retired := p_quantity - l_dist_quantity;
2775: ELSE

Line 2783: p_init_msg_list => OKC_API.G_FALSE,

2779: IF l_dist_tbl.COUNT > 0 THEN
2780: -- SECHAWLA 21-NOV-03 3262519 : Added p_tax_owner and delta cost parameter to the following procedure call
2781: do_partial_units_retirement(
2782: p_api_version => p_api_version,
2783: p_init_msg_list => OKC_API.G_FALSE,
2784: p_tax_owner => l_tax_owner,
2785: p_delta_cost => l_delta_cost,
2786: p_asset_id => l_okxassetlines_rec.asset_id,
2787: p_asset_number => l_okxassetlines_rec.asset_number,

Line 2801: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2797: x_return_status => x_return_status,
2798: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2799: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2800:
2801: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2802: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2803: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2804: RAISE OKC_API.G_EXCEPTION_ERROR;
2805: END IF;

Line 2802: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2798: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2799: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2800:
2801: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2802: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2803: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2804: RAISE OKC_API.G_EXCEPTION_ERROR;
2805: END IF;
2806:

Line 2803: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2799: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2800:
2801: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2802: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2803: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2804: RAISE OKC_API.G_EXCEPTION_ERROR;
2805: END IF;
2806:
2807:

Line 2804: RAISE OKC_API.G_EXCEPTION_ERROR;

2800:
2801: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2802: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2803: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2804: RAISE OKC_API.G_EXCEPTION_ERROR;
2805: END IF;
2806:
2807:
2808: /* SECHAWLA 21-NOV-03 3262519 : This fetch is not required. Cost to be retired from the tax book should be

Line 2860: p_init_msg_list => OKC_API.G_FALSE,

2856:
2857:
2858: do_cost_retirement(
2859: p_api_version => p_api_version,
2860: p_init_msg_list => OKC_API.G_FALSE,
2861: p_tax_owner => l_tax_owner,
2862: p_delta_cost => l_delta_cost,
2863: p_asset_id => l_okxassetlines_rec.asset_id,
2864: p_asset_number => l_okxassetlines_rec.asset_number,

Line 2876: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2872: x_return_status => x_return_status,
2873: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2874: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2875:
2876: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2877: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2878: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2879: RAISE OKC_API.G_EXCEPTION_ERROR;
2880: END IF;

Line 2877: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2873: p_quote_eff_date => l_quote_eff_date, -- rmunjulu EDAT 10-Jan-2005
2874: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2875:
2876: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2877: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2878: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2879: RAISE OKC_API.G_EXCEPTION_ERROR;
2880: END IF;
2881: -- SECHAWLA 13-JAN-03 Bug # 2701440 : If the tax book's cost is less than the cost retierd from the corp book

Line 2878: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2874: p_quote_accpt_date => l_quote_accpt_date ); -- rmunjulu EDAT 10-Jan-2005
2875:
2876: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2877: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2878: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2879: RAISE OKC_API.G_EXCEPTION_ERROR;
2880: END IF;
2881: -- SECHAWLA 13-JAN-03 Bug # 2701440 : If the tax book's cost is less than the cost retierd from the corp book
2882: -- but has not been fully retired yet, then perform a full cost retirement for tax book

Line 2879: RAISE OKC_API.G_EXCEPTION_ERROR;

2875:
2876: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2877: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2878: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2879: RAISE OKC_API.G_EXCEPTION_ERROR;
2880: END IF;
2881: -- SECHAWLA 13-JAN-03 Bug # 2701440 : If the tax book's cost is less than the cost retierd from the corp book
2882: -- but has not been fully retired yet, then perform a full cost retirement for tax book
2883:

Line 2893: p_init_msg_list => OKC_API.G_FALSE,

2889:
2890: -- SECHAWLA 21-nov-03 3262519 Added tax owner and delta cost parameters
2891: do_cost_retirement(
2892: p_api_version => p_api_version,
2893: p_init_msg_list => OKC_API.G_FALSE,
2894: p_tax_owner => l_tax_owner,
2895: p_delta_cost => l_delta_cost,
2896: p_asset_id => l_okxassetlines_rec.asset_id,
2897: p_asset_number => l_okxassetlines_rec.asset_number,

Line 2907: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2903: x_msg_count => x_msg_count,
2904: x_msg_data => x_msg_data,
2905: x_return_status => x_return_status);
2906:
2907: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2908: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2909: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2910: RAISE OKC_API.G_EXCEPTION_ERROR;
2911: END IF;

Line 2908: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2904: x_msg_data => x_msg_data,
2905: x_return_status => x_return_status);
2906:
2907: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2908: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2909: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2910: RAISE OKC_API.G_EXCEPTION_ERROR;
2911: END IF;
2912: */

Line 2909: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2905: x_return_status => x_return_status);
2906:
2907: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2908: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2909: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2910: RAISE OKC_API.G_EXCEPTION_ERROR;
2911: END IF;
2912: */
2913: END IF;

Line 2910: RAISE OKC_API.G_EXCEPTION_ERROR;

2906:
2907: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2908: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2909: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2910: RAISE OKC_API.G_EXCEPTION_ERROR;
2911: END IF;
2912: */
2913: END IF;
2914:

Line 2938: RAISE OKC_API.G_EXCEPTION_ERROR;

2934: OKL_API.set_message(p_app_name => 'OKL',
2935: p_msg_name => 'OKL_AM_NO_TRX_TYPE_FOUND',
2936: p_token1 => 'TRY_NAME',
2937: p_token1_value => 'Asset Disposition');
2938: RAISE OKC_API.G_EXCEPTION_ERROR;
2939: END IF;
2940:
2941:
2942: lp_thpv_rec.tas_type := 'RFA';

Line 2952: p_init_msg_list => OKC_API.G_FALSE,

2948: lp_thpv_rec.legal_entity_id := p_legal_entity_id;
2949: -- Legal Entity Changes End
2950:
2951: OKL_TRX_ASSETS_PUB.create_trx_ass_h_def( p_api_version => p_api_version,
2952: p_init_msg_list => OKC_API.G_FALSE,
2953: x_return_status => x_return_status,
2954: x_msg_count => x_msg_count,
2955: x_msg_data => x_msg_data,
2956: p_thpv_rec => lp_thpv_rec,

Line 2959: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

2955: x_msg_data => x_msg_data,
2956: p_thpv_rec => lp_thpv_rec,
2957: x_thpv_rec => lx_thpv_rec);
2958:
2959: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2960: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2961: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2962: RAISE OKC_API.G_EXCEPTION_ERROR;
2963: END IF;

Line 2960: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

2956: p_thpv_rec => lp_thpv_rec,
2957: x_thpv_rec => lx_thpv_rec);
2958:
2959: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2960: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2961: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2962: RAISE OKC_API.G_EXCEPTION_ERROR;
2963: END IF;
2964:

Line 2961: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

2957: x_thpv_rec => lx_thpv_rec);
2958:
2959: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2960: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2961: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2962: RAISE OKC_API.G_EXCEPTION_ERROR;
2963: END IF;
2964:
2965: --SECHAWLA 03-JAN-03 2683876 Pass the currency code if creating/updating amounts in txl assets

Line 2962: RAISE OKC_API.G_EXCEPTION_ERROR;

2958:
2959: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
2960: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
2961: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
2962: RAISE OKC_API.G_EXCEPTION_ERROR;
2963: END IF;
2964:
2965: --SECHAWLA 03-JAN-03 2683876 Pass the currency code if creating/updating amounts in txl assets
2966: l_func_curr_code := okl_am_util_pvt.get_functional_currency;

Line 3015: p_init_msg_list => OKC_API.G_FALSE,

3011: -- SECHAWLA 15-DEC-04 4028371 : set FA date on trx line
3012: lp_tlpv_rec.FA_TRX_DATE := l_fa_trx_date;
3013:
3014: OKL_TXL_ASSETS_PUB.create_txl_asset_def(p_api_version => p_api_version,
3015: p_init_msg_list => OKC_API.G_FALSE,
3016: x_return_status => x_return_status,
3017: x_msg_count => x_msg_count,
3018: x_msg_data => x_msg_data,
3019: p_tlpv_rec => lp_tlpv_rec,

Line 3022: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3018: x_msg_data => x_msg_data,
3019: p_tlpv_rec => lp_tlpv_rec,
3020: x_tlpv_rec => lx_tlpv_rec);
3021:
3022: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3023: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3024: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3025: RAISE OKC_API.G_EXCEPTION_ERROR;
3026: END IF;

Line 3023: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3019: p_tlpv_rec => lp_tlpv_rec,
3020: x_tlpv_rec => lx_tlpv_rec);
3021:
3022: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3023: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3024: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3025: RAISE OKC_API.G_EXCEPTION_ERROR;
3026: END IF;
3027:

Line 3024: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

3020: x_tlpv_rec => lx_tlpv_rec);
3021:
3022: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3023: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3024: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3025: RAISE OKC_API.G_EXCEPTION_ERROR;
3026: END IF;
3027:
3028: -----------------end Store Transaction in OKL -----------------

Line 3025: RAISE OKC_API.G_EXCEPTION_ERROR;

3021:
3022: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3023: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3024: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3025: RAISE OKC_API.G_EXCEPTION_ERROR;
3026: END IF;
3027:
3028: -----------------end Store Transaction in OKL -----------------
3029:

Line 3033: p_init_msg_list => OKC_API.G_FALSE,

3029:
3030: -- make call to accounting entries
3031: process_accounting_entries(
3032: p_api_version => p_api_version,
3033: p_init_msg_list => OKC_API.G_FALSE,
3034: x_return_status => x_return_status,
3035: x_msg_count => x_msg_count,
3036: x_msg_data => x_msg_data,
3037: p_kle_id => p_financial_asset_id,

Line 3051: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3047: --akrangan end
3048: );
3049:
3050: -- rollback if error in accounting entries
3051: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3052: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3053: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3054: RAISE OKC_API.G_EXCEPTION_ERROR;
3055: END IF;

Line 3052: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3048: );
3049:
3050: -- rollback if error in accounting entries
3051: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3052: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3053: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3054: RAISE OKC_API.G_EXCEPTION_ERROR;
3055: END IF;
3056:

Line 3053: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

3049:
3050: -- rollback if error in accounting entries
3051: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3052: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3053: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3054: RAISE OKC_API.G_EXCEPTION_ERROR;
3055: END IF;
3056:
3057: -- Store the amount at the header and line level in trx tables

Line 3054: RAISE OKC_API.G_EXCEPTION_ERROR;

3050: -- rollback if error in accounting entries
3051: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3052: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3053: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3054: RAISE OKC_API.G_EXCEPTION_ERROR;
3055: END IF;
3056:
3057: -- Store the amount at the header and line level in trx tables
3058:

Line 3066: p_init_msg_list => OKC_API.G_FALSE,

3062: lp_thpv_rec.total_match_amount := lx_total_amount;
3063:
3064: OKL_TRX_ASSETS_PUB.update_trx_ass_h_def(
3065: p_api_version => p_api_version,
3066: p_init_msg_list => OKC_API.G_FALSE,
3067: x_return_status => x_return_status,
3068: x_msg_count => x_msg_count,
3069: x_msg_data => x_msg_data,
3070: p_thpv_rec => lp_thpv_rec,

Line 3073: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3069: x_msg_data => x_msg_data,
3070: p_thpv_rec => lp_thpv_rec,
3071: x_thpv_rec => lx_thpv_rec);
3072:
3073: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3074: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3075: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3076: RAISE OKC_API.G_EXCEPTION_ERROR;
3077: END IF;

Line 3074: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3070: p_thpv_rec => lp_thpv_rec,
3071: x_thpv_rec => lx_thpv_rec);
3072:
3073: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3074: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3075: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3076: RAISE OKC_API.G_EXCEPTION_ERROR;
3077: END IF;
3078:

Line 3075: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

3071: x_thpv_rec => lx_thpv_rec);
3072:
3073: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3074: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3075: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3076: RAISE OKC_API.G_EXCEPTION_ERROR;
3077: END IF;
3078:
3079: -- Update amount in the lines table.

Line 3076: RAISE OKC_API.G_EXCEPTION_ERROR;

3072:
3073: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3074: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3075: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3076: RAISE OKC_API.G_EXCEPTION_ERROR;
3077: END IF;
3078:
3079: -- Update amount in the lines table.
3080: lp_tlpv_rec := lp_tlpv_empty_rec;

Line 3103: p_init_msg_list => OKC_API.G_FALSE,

3099:
3100:
3101: OKL_TXL_ASSETS_PUB.update_txl_asset_Def(
3102: p_api_version => p_api_version,
3103: p_init_msg_list => OKC_API.G_FALSE,
3104: x_return_status => x_return_status,
3105: x_msg_count => x_msg_count,
3106: x_msg_data => x_msg_data,
3107: p_tlpv_rec => lp_tlpv_rec,

Line 3110: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3106: x_msg_data => x_msg_data,
3107: p_tlpv_rec => lp_tlpv_rec,
3108: x_tlpv_rec => lx_tlpv_rec);
3109:
3110: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3111: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3112: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3113: RAISE OKC_API.G_EXCEPTION_ERROR;
3114: END IF;

Line 3111: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3107: p_tlpv_rec => lp_tlpv_rec,
3108: x_tlpv_rec => lx_tlpv_rec);
3109:
3110: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3111: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3112: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3113: RAISE OKC_API.G_EXCEPTION_ERROR;
3114: END IF;
3115:

Line 3112: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

3108: x_tlpv_rec => lx_tlpv_rec);
3109:
3110: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3111: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3112: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3113: RAISE OKC_API.G_EXCEPTION_ERROR;
3114: END IF;
3115:
3116: END IF;

Line 3113: RAISE OKC_API.G_EXCEPTION_ERROR;

3109:
3110: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3111: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3112: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3113: RAISE OKC_API.G_EXCEPTION_ERROR;
3114: END IF;
3115:
3116: END IF;
3117: END IF; -- if l_already_retired = 'N'

Line 3133: p_init_msg_list => OKC_API.G_FALSE,

3129:
3130: IF l_itemlocation_rec.instance_end_date IS NULL THEN-- Instance is not already expired.
3131: expire_item (
3132: p_api_version => p_api_version,
3133: p_init_msg_list => OKC_API.G_FALSE,
3134: x_msg_count => x_msg_count,
3135: x_msg_data => x_msg_data,
3136: x_return_status => x_return_status ,
3137: p_instance_id => l_itemlocation_rec.instance_id,

Line 3140: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3136: x_return_status => x_return_status ,
3137: p_instance_id => l_itemlocation_rec.instance_id,
3138: p_end_date => l_sys_date); -- rmunjulu EDAT 23-Nov-04 -- change back to sysdate -- rmunjulu EDAT Changed from sysdate to eff date
3139:
3140: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3141: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3142: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3143: RAISE OKC_API.G_EXCEPTION_ERROR;
3144: END IF;

Line 3141: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3137: p_instance_id => l_itemlocation_rec.instance_id,
3138: p_end_date => l_sys_date); -- rmunjulu EDAT 23-Nov-04 -- change back to sysdate -- rmunjulu EDAT Changed from sysdate to eff date
3139:
3140: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3141: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3142: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3143: RAISE OKC_API.G_EXCEPTION_ERROR;
3144: END IF;
3145:

Line 3142: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

3138: p_end_date => l_sys_date); -- rmunjulu EDAT 23-Nov-04 -- change back to sysdate -- rmunjulu EDAT Changed from sysdate to eff date
3139:
3140: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3141: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3142: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3143: RAISE OKC_API.G_EXCEPTION_ERROR;
3144: END IF;
3145:
3146: END IF;

Line 3143: RAISE OKC_API.G_EXCEPTION_ERROR;

3139:
3140: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3141: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3142: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3143: RAISE OKC_API.G_EXCEPTION_ERROR;
3144: END IF;
3145:
3146: END IF;
3147:

Line 3160: p_init_msg_list => OKC_API.G_FALSE,

3156:
3157: IF l_itemlocation_rec.instance_end_date IS NULL THEN-- Instance is not already expired.
3158: expire_item (
3159: p_api_version => p_api_version,
3160: p_init_msg_list => OKC_API.G_FALSE,
3161: x_msg_count => x_msg_count,
3162: x_msg_data => x_msg_data,
3163: x_return_status => x_return_status ,
3164: p_instance_id => l_itemlocation_rec.instance_id,

Line 3167: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3163: x_return_status => x_return_status ,
3164: p_instance_id => l_itemlocation_rec.instance_id,
3165: p_end_date => l_sys_date); -- rmunjulu EDAT 23-Nov-04 Change back to sysdate -- rmunjulu EDAT Changed from sysdate to eff date
3166:
3167: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3168: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3169: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3170: RAISE OKC_API.G_EXCEPTION_ERROR;
3171: END IF;

Line 3168: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3164: p_instance_id => l_itemlocation_rec.instance_id,
3165: p_end_date => l_sys_date); -- rmunjulu EDAT 23-Nov-04 Change back to sysdate -- rmunjulu EDAT Changed from sysdate to eff date
3166:
3167: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3168: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3169: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3170: RAISE OKC_API.G_EXCEPTION_ERROR;
3171: END IF;
3172:

Line 3169: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

3165: p_end_date => l_sys_date); -- rmunjulu EDAT 23-Nov-04 Change back to sysdate -- rmunjulu EDAT Changed from sysdate to eff date
3166:
3167: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3168: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3169: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3170: RAISE OKC_API.G_EXCEPTION_ERROR;
3171: END IF;
3172:
3173: IF instance_counter = p_quantity THEN

Line 3170: RAISE OKC_API.G_EXCEPTION_ERROR;

3166:
3167: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3168: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3169: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3170: RAISE OKC_API.G_EXCEPTION_ERROR;
3171: END IF;
3172:
3173: IF instance_counter = p_quantity THEN
3174: EXIT;

Line 3201: p_init_msg_list => OKC_API.G_FALSE,

3197: lp_thpv_rec.tsu_code := 'CANCELED';
3198:
3199: OKL_TRX_ASSETS_PUB.update_trx_ass_h_def(
3200: p_api_version => p_api_version,
3201: p_init_msg_list => OKC_API.G_FALSE,
3202: x_return_status => x_return_status,
3203: x_msg_count => x_msg_count,
3204: x_msg_data => x_msg_data,
3205: p_thpv_rec => lp_thpv_rec,

Line 3208: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3204: x_msg_data => x_msg_data,
3205: p_thpv_rec => lp_thpv_rec,
3206: x_thpv_rec => lx_thpv_rec);
3207:
3208: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3209: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3210: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3211: RAISE OKC_API.G_EXCEPTION_ERROR;
3212: END IF;

Line 3209: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3205: p_thpv_rec => lp_thpv_rec,
3206: x_thpv_rec => lx_thpv_rec);
3207:
3208: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3209: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3210: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3211: RAISE OKC_API.G_EXCEPTION_ERROR;
3212: END IF;
3213: END LOOP;

Line 3210: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

3206: x_thpv_rec => lx_thpv_rec);
3207:
3208: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3209: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3210: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3211: RAISE OKC_API.G_EXCEPTION_ERROR;
3212: END IF;
3213: END LOOP;
3214:

Line 3211: RAISE OKC_API.G_EXCEPTION_ERROR;

3207:
3208: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3209: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3210: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3211: RAISE OKC_API.G_EXCEPTION_ERROR;
3212: END IF;
3213: END LOOP;
3214:
3215:

Line 3240: p_init_msg_list => OKC_API.G_FALSE,

3236: -------------- Securitization Processing -----------------------
3237:
3238: OKL_AM_SECURITIZATION_PVT.process_securitized_streams(
3239: p_api_version => p_api_version,
3240: p_init_msg_list => OKC_API.G_FALSE,
3241: x_return_status => x_return_status,
3242: x_msg_count => x_msg_count,
3243: x_msg_data => x_msg_data,
3244: p_kle_id => p_financial_asset_id,

Line 3250: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3246: p_effective_date => l_quote_eff_date, -- rmunjulu EDAT Added
3247: p_transaction_date => l_quote_accpt_date, -- rmunjulu EDAT Added
3248: p_call_origin => OKL_SECURITIZATION_PVT.G_TRX_REASON_ASSET_DISPOSAL);
3249:
3250: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3251: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3252: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3253: RAISE OKC_API.G_EXCEPTION_ERROR;
3254: END IF;

Line 3251: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3247: p_transaction_date => l_quote_accpt_date, -- rmunjulu EDAT Added
3248: p_call_origin => OKL_SECURITIZATION_PVT.G_TRX_REASON_ASSET_DISPOSAL);
3249:
3250: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3251: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3252: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3253: RAISE OKC_API.G_EXCEPTION_ERROR;
3254: END IF;
3255: -------------- end Securitization Processing -----------------------

Line 3252: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

3248: p_call_origin => OKL_SECURITIZATION_PVT.G_TRX_REASON_ASSET_DISPOSAL);
3249:
3250: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3251: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3252: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3253: RAISE OKC_API.G_EXCEPTION_ERROR;
3254: END IF;
3255: -------------- end Securitization Processing -----------------------
3256: --akrangan added for sla populate sources cr start

Line 3253: RAISE OKC_API.G_EXCEPTION_ERROR;

3249:
3250: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3251: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3252: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3253: RAISE OKC_API.G_EXCEPTION_ERROR;
3254: END IF;
3255: -------------- end Securitization Processing -----------------------
3256: --akrangan added for sla populate sources cr start
3257: IF g_trans_id_tbl.COUNT > 0

Line 3275: p_init_msg_list => okc_api.g_false,

3271: l_fxlv_rec.fa_transaction_id := g_trans_id_tbl(i);
3272: l_fxlv_rec.asset_book_type_name := lx_tlpv_rec.corporate_book;
3273:
3274: okl_sla_acc_sources_pvt.populate_sources(p_api_version => p_api_version,
3275: p_init_msg_list => okc_api.g_false,
3276: p_fxhv_rec => l_fxhv_rec,
3277: p_fxlv_rec => l_fxlv_rec,
3278: x_return_status => x_return_status,
3279: x_msg_count => x_msg_count,

Line 3282: IF (x_return_status = okc_api.g_ret_sts_unexp_error)

3278: x_return_status => x_return_status,
3279: x_msg_count => x_msg_count,
3280: x_msg_data => x_msg_data);
3281:
3282: IF (x_return_status = okc_api.g_ret_sts_unexp_error)
3283: THEN
3284: RAISE okl_api.g_exception_unexpected_error;
3285: ELSIF (x_return_status = okc_api.g_ret_sts_error)
3286: THEN

Line 3285: ELSIF (x_return_status = okc_api.g_ret_sts_error)

3281:
3282: IF (x_return_status = okc_api.g_ret_sts_unexp_error)
3283: THEN
3284: RAISE okl_api.g_exception_unexpected_error;
3285: ELSIF (x_return_status = okc_api.g_ret_sts_error)
3286: THEN
3287: RAISE okl_api.g_exception_error;
3288: END IF;
3289: END LOOP;

Line 3293: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);

3289: END LOOP;
3290: END IF;
3291: --akrangan added for sla populate sources cr end
3292:
3293: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);
3294: EXCEPTION
3295: WHEN OKC_API.G_EXCEPTION_ERROR THEN
3296:
3297: IF l_okxassetlines_csr%ISOPEN THEN

Line 3295: WHEN OKC_API.G_EXCEPTION_ERROR THEN

3291: --akrangan added for sla populate sources cr end
3292:
3293: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);
3294: EXCEPTION
3295: WHEN OKC_API.G_EXCEPTION_ERROR THEN
3296:
3297: IF l_okxassetlines_csr%ISOPEN THEN
3298: CLOSE l_okxassetlines_csr;
3299: END IF;

Line 3342: x_return_status := OKC_API.HANDLE_EXCEPTIONS

3338: CLOSE l_offlseassettrx_csr;
3339: END IF;
3340:
3341:
3342: x_return_status := OKC_API.HANDLE_EXCEPTIONS
3343: (
3344: l_api_name,
3345: G_PKG_NAME,
3346: 'OKC_API.G_RET_STS_ERROR',

Line 3346: 'OKC_API.G_RET_STS_ERROR',

3342: x_return_status := OKC_API.HANDLE_EXCEPTIONS
3343: (
3344: l_api_name,
3345: G_PKG_NAME,
3346: 'OKC_API.G_RET_STS_ERROR',
3347: x_msg_count,
3348: x_msg_data,
3349: '_PVT'
3350: );

Line 3351: WHEN OKC_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

3347: x_msg_count,
3348: x_msg_data,
3349: '_PVT'
3350: );
3351: WHEN OKC_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
3352:
3353: IF l_okxassetlines_csr%ISOPEN THEN
3354: CLOSE l_okxassetlines_csr;
3355: END IF;

Line 3397: x_return_status :=OKC_API.HANDLE_EXCEPTIONS

3393: IF l_offlseassettrx_csr%ISOPEN THEN
3394: CLOSE l_offlseassettrx_csr;
3395: END IF;
3396:
3397: x_return_status :=OKC_API.HANDLE_EXCEPTIONS
3398: (
3399: l_api_name,
3400: G_PKG_NAME,
3401: 'OKC_API.G_RET_STS_UNEXP_ERROR',

Line 3401: 'OKC_API.G_RET_STS_UNEXP_ERROR',

3397: x_return_status :=OKC_API.HANDLE_EXCEPTIONS
3398: (
3399: l_api_name,
3400: G_PKG_NAME,
3401: 'OKC_API.G_RET_STS_UNEXP_ERROR',
3402: x_msg_count,
3403: x_msg_data,
3404: '_PVT'
3405: );

Line 3452: x_return_status :=OKC_API.HANDLE_EXCEPTIONS

3448: IF l_offlseassettrx_csr%ISOPEN THEN
3449: CLOSE l_offlseassettrx_csr;
3450: END IF;
3451:
3452: x_return_status :=OKC_API.HANDLE_EXCEPTIONS
3453: (
3454: l_api_name,
3455: G_PKG_NAME,
3456: 'OTHERS',

Line 3702: l_return_status VARCHAR2(1) := OKC_API.G_RET_STS_SUCCESS;

3698:
3699:
3700: l_dist_quantity NUMBER;
3701: l_dist_tbl asset_dist_tbl;
3702: l_return_status VARCHAR2(1) := OKC_API.G_RET_STS_SUCCESS;
3703: l_order_number NUMBER;
3704: i NUMBER;
3705: l_kle_id NUMBER;
3706: l_quantity NUMBER;

Line 3774: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3770: p_api_version,
3771: '_PVT',
3772: x_return_status);
3773:
3774: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3775: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3776: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
3777: RAISE OKC_API.G_EXCEPTION_ERROR;
3778: END IF;

Line 3775: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3771: '_PVT',
3772: x_return_status);
3773:
3774: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3775: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3776: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
3777: RAISE OKC_API.G_EXCEPTION_ERROR;
3778: END IF;
3779:

Line 3776: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN

3772: x_return_status);
3773:
3774: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3775: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3776: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
3777: RAISE OKC_API.G_EXCEPTION_ERROR;
3778: END IF;
3779:
3780: -- Get the sysdate

Line 3777: RAISE OKC_API.G_EXCEPTION_ERROR;

3773:
3774: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3775: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3776: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
3777: RAISE OKC_API.G_EXCEPTION_ERROR;
3778: END IF;
3779:
3780: -- Get the sysdate
3781: SELECT SYSDATE INTO l_sys_date FROM DUAL;

Line 3791: RAISE okc_api.G_EXCEPTION_ERROR;

3787: OKL_API.set_message( p_app_name => 'OKC',
3788: p_msg_name => G_REQUIRED_VALUE,
3789: p_token1 => G_COL_NAME_TOKEN,
3790: p_token1_value => 'ORDER_LINE_ID');
3791: RAISE okc_api.G_EXCEPTION_ERROR;
3792: END IF;
3793:
3794: /* -- SECHAWLA 21-OCT-04 3924244
3795: OPEN l_orderheaders_csr(p_order_header_Id);

Line 3804: RAISE okc_api.G_EXCEPTION_ERROR;

3800: OKL_API.set_message( p_app_name => 'OKC',
3801: p_msg_name => G_INVALID_VALUE,
3802: p_token1 => G_COL_NAME_TOKEN,
3803: p_token1_value => 'ORDER_HEADER_ID');
3804: RAISE okc_api.G_EXCEPTION_ERROR;
3805: END IF;
3806: CLOSE l_orderheaders_csr;
3807: */
3808:

Line 3820: RAISE okc_api.G_EXCEPTION_ERROR;

3816: OKL_API.set_message( p_app_name => 'OKC',
3817: p_msg_name => G_INVALID_VALUE,
3818: p_token1 => G_COL_NAME_TOKEN,
3819: p_token1_value => 'ORDER_LINE_ID');
3820: RAISE okc_api.G_EXCEPTION_ERROR;
3821: END IF;
3822: CLOSE l_orderlines_csr;
3823:
3824: OPEN l_orderheaders_csr(l_header_id);

Line 3839: OKC_API.set_message( p_app_name => 'OKC',

3835:
3836: IF l_ordered_quantity < 0 THEN -- SECHAWLA 21-OCT-04 3924244
3837: x_return_status := OKL_API.G_RET_STS_ERROR;
3838: -- ordered quantity is invalid
3839: OKC_API.set_message( p_app_name => 'OKC',
3840: p_msg_name => G_INVALID_VALUE,
3841: p_token1 => G_COL_NAME_TOKEN,
3842: p_token1_value => 'ORDERED_QUANTITY');
3843:

Line 3845: RAISE OKC_API.G_EXCEPTION_ERROR;

3841: p_token1 => G_COL_NAME_TOKEN,
3842: p_token1_value => 'ORDERED_QUANTITY');
3843:
3844:
3845: RAISE OKC_API.G_EXCEPTION_ERROR;
3846: END IF;
3847:
3848: IF trunc(l_ordered_quantity) <> l_ordered_quantity THEN -- SECHAWLA 21-OCT-04 3924244
3849: x_return_status := OKL_API.G_RET_STS_ERROR;

Line 3851: OKC_API.set_message( p_app_name => 'OKL',

3847:
3848: IF trunc(l_ordered_quantity) <> l_ordered_quantity THEN -- SECHAWLA 21-OCT-04 3924244
3849: x_return_status := OKL_API.G_RET_STS_ERROR;
3850: -- Ordered quantity should be a whole number.
3851: OKC_API.set_message( p_app_name => 'OKL',
3852: p_msg_name => 'OKL_AM_WHOLE_QTY_ERR');
3853: RAISE OKC_API.G_EXCEPTION_ERROR;
3854: END IF;
3855:

Line 3853: RAISE OKC_API.G_EXCEPTION_ERROR;

3849: x_return_status := OKL_API.G_RET_STS_ERROR;
3850: -- Ordered quantity should be a whole number.
3851: OKC_API.set_message( p_app_name => 'OKL',
3852: p_msg_name => 'OKL_AM_WHOLE_QTY_ERR');
3853: RAISE OKC_API.G_EXCEPTION_ERROR;
3854: END IF;
3855:
3856:
3857:

Line 3869: RAISE okc_api.G_EXCEPTION_ERROR;

3865: OKL_API.set_message( p_app_name => 'OKL',
3866: p_msg_name => 'OKL_AM_NO_ASSET_RETURN',
3867: p_token1 => 'ORDER_NUMBER',
3868: p_token1_value => l_order_number);
3869: RAISE okc_api.G_EXCEPTION_ERROR;
3870: END IF;
3871:
3872: IF l_quantity IS NULL OR l_quantity = OKL_API.G_MISS_NUM THEN
3873: x_return_status := OKL_API.G_RET_STS_ERROR;

Line 3879: RAISE okc_api.G_EXCEPTION_ERROR;

3875: OKL_API.set_message( p_app_name => 'OKC',
3876: p_msg_name => G_REQUIRED_VALUE,
3877: p_token1 => G_COL_NAME_TOKEN,
3878: p_token1_value => 'ASSET_RETURN_QUANTITY');
3879: RAISE okc_api.G_EXCEPTION_ERROR;
3880: END IF;
3881:
3882: -- RRAVIKIR Legal Entity Changes
3883: IF (l_legal_entity_id is null or l_legal_entity_id = OKC_API.G_MISS_NUM) THEN

Line 3883: IF (l_legal_entity_id is null or l_legal_entity_id = OKC_API.G_MISS_NUM) THEN

3879: RAISE okc_api.G_EXCEPTION_ERROR;
3880: END IF;
3881:
3882: -- RRAVIKIR Legal Entity Changes
3883: IF (l_legal_entity_id is null or l_legal_entity_id = OKC_API.G_MISS_NUM) THEN
3884: OKL_API.SET_MESSAGE(p_app_name => g_app_name,
3885: p_msg_name => g_required_value,
3886: p_token1 => g_col_name_token,
3887: p_token1_value => 'legal_entity_id');

Line 3888: RAISE OKC_API.G_EXCEPTION_ERROR;

3884: OKL_API.SET_MESSAGE(p_app_name => g_app_name,
3885: p_msg_name => g_required_value,
3886: p_token1 => g_col_name_token,
3887: p_token1_value => 'legal_entity_id');
3888: RAISE OKC_API.G_EXCEPTION_ERROR;
3889: END IF;
3890: -- Legal Entity Changes End
3891:
3892: IF l_quantity < 0 THEN

Line 3899: RAISE okc_api.G_EXCEPTION_ERROR;

3895: OKL_API.set_message( p_app_name => 'OKC',
3896: p_msg_name => G_INVALID_VALUE,
3897: p_token1 => G_COL_NAME_TOKEN,
3898: p_token1_value => 'ASSET_RETURN_QUANTITY');
3899: RAISE okc_api.G_EXCEPTION_ERROR;
3900: END IF;
3901:
3902: CLOSE l_assetreturn_csr;
3903:

Line 3915: OKC_API.set_message( p_app_name => 'OKC',

3911: FETCH l_dealtype_csr INTO l_chr_id, l_deal_type, l_contract_number;
3912: IF l_dealtype_csr%NOTFOUND THEN
3913: x_return_status := OKL_API.G_RET_STS_ERROR;
3914: -- chr id is invalid
3915: OKC_API.set_message( p_app_name => 'OKC',
3916: p_msg_name => G_INVALID_VALUE,
3917: p_token1 => G_COL_NAME_TOKEN,
3918: p_token1_value => 'CHR_ID');
3919:

Line 3920: RAISE OKC_API.G_EXCEPTION_ERROR;

3916: p_msg_name => G_INVALID_VALUE,
3917: p_token1 => G_COL_NAME_TOKEN,
3918: p_token1_value => 'CHR_ID');
3919:
3920: RAISE OKC_API.G_EXCEPTION_ERROR;
3921: END IF;
3922: CLOSE l_dealtype_csr;
3923:
3924: IF l_deal_type IN ('LEASEDF','LEASEST') THEN

Line 3936: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

3932: ,x_return_status => x_return_status
3933: ,x_msg_count => x_msg_count
3934: ,x_msg_data => x_msg_data);
3935:
3936: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3937: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3938: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3939: RAISE OKC_API.G_EXCEPTION_ERROR;
3940: END IF;

Line 3937: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

3933: ,x_msg_count => x_msg_count
3934: ,x_msg_data => x_msg_data);
3935:
3936: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3937: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3938: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3939: RAISE OKC_API.G_EXCEPTION_ERROR;
3940: END IF;
3941:

Line 3938: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

3934: ,x_msg_data => x_msg_data);
3935:
3936: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3937: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3938: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3939: RAISE OKC_API.G_EXCEPTION_ERROR;
3940: END IF;
3941:
3942: -- check if tax owner is defined

Line 3939: RAISE OKC_API.G_EXCEPTION_ERROR;

3935:
3936: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
3937: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
3938: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
3939: RAISE OKC_API.G_EXCEPTION_ERROR;
3940: END IF;
3941:
3942: -- check if tax owner is defined
3943: IF l_rulv_rec.rule_information1 IS NULL OR l_rulv_rec.rule_information1 = OKL_API.G_MISS_CHAR THEN

Line 3951: RAISE OKC_API.G_EXCEPTION_ERROR;

3947: OKL_API.set_message( p_app_name => 'OKL',
3948: p_msg_name => 'OKL_AM_NO_TAX_OWNER',
3949: p_token1 => 'CONTRACT_NUMBER',
3950: p_token1_value => l_contract_number);
3951: RAISE OKC_API.G_EXCEPTION_ERROR;
3952:
3953: ELSE
3954: -- l_rulv_rec.RULE_INFORMATION1 will contain the value 'LESSEE' or 'LESSOR'
3955: l_tax_owner := l_rulv_rec.RULE_INFORMATION1;

Line 3966: OKC_API.set_message( p_app_name => 'OKL',

3962:
3963: IF l_residual_value IS NULL THEN
3964: x_return_status := OKL_API.G_RET_STS_ERROR;
3965: -- Residual value is not defined for the asset
3966: OKC_API.set_message( p_app_name => 'OKL',
3967: p_msg_name => 'OKL_AM_NO_RESIDUAL_VALUE',
3968: p_token1 => 'ASSET_NUMBER',
3969: p_token1_value => l_name);
3970:

Line 3972: RAISE OKC_API.G_EXCEPTION_ERROR;

3968: p_token1 => 'ASSET_NUMBER',
3969: p_token1_value => l_name);
3970:
3971:
3972: RAISE OKC_API.G_EXCEPTION_ERROR;
3973: END IF;
3974:
3975: IF l_residual_value < 0 THEN
3976: x_return_status := OKL_API.G_RET_STS_ERROR;

Line 3978: OKC_API.set_message( p_app_name => 'OKL',

3974:
3975: IF l_residual_value < 0 THEN
3976: x_return_status := OKL_API.G_RET_STS_ERROR;
3977: -- Residual value is negative for the asset
3978: OKC_API.set_message( p_app_name => 'OKL',
3979: p_msg_name => 'OKL_AM_INVALID_RESIDUAL',
3980: p_token1 => 'ASSET_NUMBER',
3981: p_token1_value => l_name);
3982:

Line 3984: RAISE OKC_API.G_EXCEPTION_ERROR;

3980: p_token1 => 'ASSET_NUMBER',
3981: p_token1_value => l_name);
3982:
3983:
3984: RAISE OKC_API.G_EXCEPTION_ERROR;
3985: END IF;
3986: END IF;
3987:
3988:

Line 4024: RAISE OKC_API.G_EXCEPTION_ERROR;

4020: OKL_API.set_message( p_app_name => 'OKL',
4021: p_msg_name => 'OKL_AM_PENDING_OFFLEASE',
4022: p_token1 => 'ASSET_NUMBER',
4023: p_token1_value => l_name);
4024: RAISE OKC_API.G_EXCEPTION_ERROR;
4025:
4026:
4027: ELSIF l_trx_status IN ('PROCESSED','CANCELED') THEN
4028: l_delta_cost := 0; -- no cost update required, as cost has already been updated thru off lease trx

Line 4045: OKC_API.set_message( p_app_name => 'OKC',

4041: FETCH l_bookcontrols_csr INTO l_fiscal_year_name;
4042: IF l_bookcontrols_csr%NOTFOUND OR l_fiscal_year_name IS NULL THEN
4043: x_return_status := OKL_API.G_RET_STS_ERROR;
4044: -- Fiscal Year Name is required
4045: OKC_API.set_message( p_app_name => 'OKC',
4046: p_msg_name => G_REQUIRED_VALUE,
4047: p_token1 => G_COL_NAME_TOKEN,
4048: p_token1_value => 'Fiscal Year Name');
4049:

Line 4051: RAISE OKC_API.G_EXCEPTION_ERROR;

4047: p_token1 => G_COL_NAME_TOKEN,
4048: p_token1_value => 'Fiscal Year Name');
4049:
4050:
4051: RAISE OKC_API.G_EXCEPTION_ERROR;
4052: END IF;
4053: CLOSE l_bookcontrols_csr;
4054: fa_cache_pkg.fazcbc_record.fiscal_year_name := l_fiscal_year_name;
4055: -- END IF;

Line 4065: x_return_status := OKC_API.G_RET_STS_ERROR;

4061: p_effective_date => NULL,
4062: x_period_rec => l_period_rec
4063: ) THEN
4064:
4065: x_return_status := OKC_API.G_RET_STS_ERROR;
4066: --Error getting current open period for the book BOOK_TYPE_CODE.
4067: OKL_API.set_message(
4068: p_app_name => 'OKL',
4069: p_msg_name => 'OKL_AM_OPEN_PERIOD_ERR',

Line 4077: RAISE OKC_API.G_EXCEPTION_ERROR;

4073: p_token2_value => l_okxassetlines_rec.book_type_code
4074: );
4075:
4076:
4077: RAISE OKC_API.G_EXCEPTION_ERROR;
4078: END IF;
4079:
4080: --- check period of addition. If 'N' then run retirements
4081: OPEN l_periodofaddition_csr(l_okxassetlines_rec.asset_id, l_okxassetlines_rec.book_type_code,l_period_rec.period_open_date);

Line 4094: x_return_status := OKC_API.G_RET_STS_ERROR;

4090:
4091: IF l_period_of_addition = 'Y' THEN
4092: -- Can nor retire asset ASSET_NUMBER as the asset was added to the book
4093: -- in the current open period. Please retire the asset manually.
4094: x_return_status := OKC_API.G_RET_STS_ERROR;
4095:
4096: OKL_API.set_message( p_app_name => 'OKL',
4097: p_msg_name => 'OKL_AM_RETIRE_MANUALLY',
4098: p_token1 => 'ASSET_NUMBER',

Line 4105: RAISE OKC_API.G_EXCEPTION_ERROR;

4101: p_token2_value => lower(l_okxassetlines_rec.book_class),
4102: p_token3 => 'BOOK_TYPE_CODE',
4103: p_token3_value => l_okxassetlines_rec.book_type_code);
4104:
4105: RAISE OKC_API.G_EXCEPTION_ERROR;
4106:
4107: END IF;
4108:
4109: ---------- SECHAWLA 05-FEB-03 Bug # 2781557 : end moved code ----------------

Line 4116: OKC_API.set_message( p_app_name => 'OKL',

4112: -- SECHAWLA 03-JUN-03 Bug 2999419 : Added the following validation
4113: IF l_okxassetlines_rec.prorate_convention_code IS NULL THEN
4114: x_return_status := OKL_API.G_RET_STS_ERROR;
4115: -- Unable to find retirement prorate convention for asset ASSET_NUMBER and book BOOK_TYPE_CODE.
4116: OKC_API.set_message( p_app_name => 'OKL',
4117: p_msg_name => 'OKL_AM_NO_PRORATE_CONVENTION',
4118: p_token1 => 'ASSET_NUMBER',
4119: p_token1_value => l_okxassetlines_rec.asset_number,
4120: p_token2 => 'BOOK_CLASS',

Line 4124: RAISE OKC_API.G_EXCEPTION_ERROR;

4120: p_token2 => 'BOOK_CLASS',
4121: p_token2_value => l_okxassetlines_rec.book_class,
4122: p_token3 => 'BOOK_TYPE_CODE',
4123: p_token3_value => l_okxassetlines_rec.book_type_code);
4124: RAISE OKC_API.G_EXCEPTION_ERROR;
4125: END IF;
4126: -- SECHAWLA 03-JUN-03 Bug 2999419: end new code
4127: */ -- ansethur for Bug:5664106 End
4128:

Line 4166: p_init_msg_list => OKC_API.G_FALSE,

4162:
4163: -- SECHAWLA 21-NOV-03, 3262519 : added tax owner and delta cost parameter to the following procedure
4164: do_full_units_retirement(
4165: p_api_version => p_api_version,
4166: p_init_msg_list => OKC_API.G_FALSE,
4167: p_tax_owner => l_tax_owner,
4168: p_delta_cost => l_delta_cost,
4169: p_asset_id => l_okxassetlines_rec.asset_id,
4170: p_asset_number => l_okxassetlines_rec.asset_number,

Line 4182: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4178: x_msg_count => x_msg_count,
4179: x_msg_data => x_msg_data,
4180: x_return_status => x_return_status);
4181:
4182: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4183: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4184: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4185: RAISE OKC_API.G_EXCEPTION_ERROR;
4186: END IF;

Line 4183: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4179: x_msg_data => x_msg_data,
4180: x_return_status => x_return_status);
4181:
4182: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4183: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4184: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4185: RAISE OKC_API.G_EXCEPTION_ERROR;
4186: END IF;
4187:

Line 4184: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4180: x_return_status => x_return_status);
4181:
4182: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4183: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4184: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4185: RAISE OKC_API.G_EXCEPTION_ERROR;
4186: END IF;
4187:
4188: l_units_retired := l_quantity;

Line 4185: RAISE OKC_API.G_EXCEPTION_ERROR;

4181:
4182: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4183: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4184: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4185: RAISE OKC_API.G_EXCEPTION_ERROR;
4186: END IF;
4187:
4188: l_units_retired := l_quantity;
4189: ELSE -- distribution qty is either less or more than the original asset return qty

Line 4235: OKC_API.set_message( p_app_name => 'OKL',

4231:
4232: IF l_dist_quantity > 0 THEN -- quantity to be retired (for non-retired distributions)
4233: -- x_return_status := OKL_API.G_RET_STS_ERROR;
4234: -- Sold quantity is more than the total quantity assigned to asset distributions.
4235: OKC_API.set_message( p_app_name => 'OKL',
4236: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
4237: --RAISE okc_api.G_EXCEPTION_ERROR;
4238: END IF;
4239:

Line 4237: --RAISE okc_api.G_EXCEPTION_ERROR;

4233: -- x_return_status := OKL_API.G_RET_STS_ERROR;
4234: -- Sold quantity is more than the total quantity assigned to asset distributions.
4235: OKC_API.set_message( p_app_name => 'OKL',
4236: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
4237: --RAISE okc_api.G_EXCEPTION_ERROR;
4238: END IF;
4239:
4240: -- SECHAWLA 21-NOV-03 3262519 : Added p_tax_owner and delta cost parameter to the following procedure call
4241: do_partial_units_retirement(

Line 4243: p_init_msg_list => OKC_API.G_FALSE,

4239:
4240: -- SECHAWLA 21-NOV-03 3262519 : Added p_tax_owner and delta cost parameter to the following procedure call
4241: do_partial_units_retirement(
4242: p_api_version => p_api_version,
4243: p_init_msg_list => OKC_API.G_FALSE,
4244: p_tax_owner => l_tax_owner,
4245: p_delta_cost => l_delta_cost,
4246: p_asset_id => l_okxassetlines_rec.asset_id,
4247: p_asset_number => l_okxassetlines_rec.asset_number,

Line 4260: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4256: x_msg_data => x_msg_data,
4257: x_return_status => x_return_status);
4258:
4259:
4260: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4261: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4262: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4263: RAISE OKC_API.G_EXCEPTION_ERROR;
4264: END IF;

Line 4261: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4257: x_return_status => x_return_status);
4258:
4259:
4260: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4261: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4262: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4263: RAISE OKC_API.G_EXCEPTION_ERROR;
4264: END IF;
4265:

Line 4262: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4258:
4259:
4260: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4261: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4262: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4263: RAISE OKC_API.G_EXCEPTION_ERROR;
4264: END IF;
4265:
4266: l_units_retired := l_units_to_be_retired;

Line 4263: RAISE OKC_API.G_EXCEPTION_ERROR;

4259:
4260: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4261: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4262: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4263: RAISE OKC_API.G_EXCEPTION_ERROR;
4264: END IF;
4265:
4266: l_units_retired := l_units_to_be_retired;
4267:

Line 4271: OKC_API.set_message( p_app_name => 'OKL',

4267:
4268: END IF; --l_non_retired_quantity = l_quantity
4269: ELSIF l_retired_quantity = l_quantity AND l_non_retired_quantity = 0 THEN -- retired qty = original asset return qty
4270: -- Asset is already fully retired.
4271: OKC_API.set_message( p_app_name => 'OKL',
4272: p_msg_name => 'OKL_AM_ALREADY_RETIRED',
4273: p_token1 => 'ASSET_NUMBER',
4274: p_token1_value => l_okxassetlines_rec.asset_number);
4275: l_already_retired := 'Y';

Line 4315: p_init_msg_list => OKC_API.G_FALSE,

4311:
4312: -- SECHAWLA 21-NOV-03, 3262519 : added tax owner and delta cost parameter to the following procedure
4313: do_partial_units_retirement(
4314: p_api_version => p_api_version,
4315: p_init_msg_list => OKC_API.G_FALSE,
4316: p_tax_owner => l_tax_owner,
4317: p_delta_cost => l_delta_cost,
4318: p_asset_id => l_okxassetlines_rec.asset_id,
4319: p_asset_number => l_okxassetlines_rec.asset_number,

Line 4332: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4328: x_msg_data => x_msg_data,
4329: x_return_status => x_return_status);
4330:
4331:
4332: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4333: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4334: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4335: RAISE OKC_API.G_EXCEPTION_ERROR;
4336: END IF;

Line 4333: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4329: x_return_status => x_return_status);
4330:
4331:
4332: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4333: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4334: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4335: RAISE OKC_API.G_EXCEPTION_ERROR;
4336: END IF;
4337:

Line 4334: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4330:
4331:
4332: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4333: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4334: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4335: RAISE OKC_API.G_EXCEPTION_ERROR;
4336: END IF;
4337:
4338: l_units_retired := l_units_to_be_retired;

Line 4335: RAISE OKC_API.G_EXCEPTION_ERROR;

4331:
4332: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4333: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4334: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4335: RAISE OKC_API.G_EXCEPTION_ERROR;
4336: END IF;
4337:
4338: l_units_retired := l_units_to_be_retired;
4339:

Line 4343: OKC_API.set_message( p_app_name => 'OKL',

4339:
4340: ELSIF l_retired_quantity > l_quantity AND l_non_retired_quantity = 0 THEN
4341: -- x_return_status := OKL_API.G_RET_STS_ERROR;
4342: -- Asset ASSET_NUMBER is already retired with invalid retired quantity which is more than the original quantity.
4343: OKC_API.set_message( p_app_name => 'OKL',
4344: p_msg_name => 'OKL_AM_INVALID_RETIRED_QTY',
4345: p_token1 => 'ASSET_NUMBER',
4346: p_token1_value => l_okxassetlines_rec.asset_number);
4347: -- RAISE okc_api.G_EXCEPTION_ERROR;

Line 4347: -- RAISE okc_api.G_EXCEPTION_ERROR;

4343: OKC_API.set_message( p_app_name => 'OKL',
4344: p_msg_name => 'OKL_AM_INVALID_RETIRED_QTY',
4345: p_token1 => 'ASSET_NUMBER',
4346: p_token1_value => l_okxassetlines_rec.asset_number);
4347: -- RAISE okc_api.G_EXCEPTION_ERROR;
4348: ELSIF l_retired_quantity < l_quantity AND l_non_retired_quantity > 0 THEN
4349: -- user requested for full retirement, but the asset is already retired partially
4350:
4351:

Line 4399: OKC_API.set_message( p_app_name => 'OKL',

4395: IF l_dist_quantity > 0 THEN
4396: IF l_retired_quantity < l_dist_quantity THEN
4397: -- x_return_status := OKL_API.G_RET_STS_ERROR;
4398: -- Sold quantity is more than the total quantity assigned to asset distributions.
4399: OKC_API.set_message( p_app_name => 'OKL',
4400: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
4401: -- RAISE okc_api.G_EXCEPTION_ERROR;
4402: END IF;
4403: END IF;

Line 4401: -- RAISE okc_api.G_EXCEPTION_ERROR;

4397: -- x_return_status := OKL_API.G_RET_STS_ERROR;
4398: -- Sold quantity is more than the total quantity assigned to asset distributions.
4399: OKC_API.set_message( p_app_name => 'OKL',
4400: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
4401: -- RAISE okc_api.G_EXCEPTION_ERROR;
4402: END IF;
4403: END IF;
4404:
4405: -- SECHAWLA 21-NOV-03, 3262519 : added tax owner and delta cost parameter to the following procedure

Line 4408: p_init_msg_list => OKC_API.G_FALSE,

4404:
4405: -- SECHAWLA 21-NOV-03, 3262519 : added tax owner and delta cost parameter to the following procedure
4406: do_partial_units_retirement(
4407: p_api_version => p_api_version,
4408: p_init_msg_list => OKC_API.G_FALSE,
4409: p_tax_owner => l_tax_owner,
4410: p_delta_cost => l_delta_cost,
4411: p_asset_id => l_okxassetlines_rec.asset_id,
4412: p_asset_number => l_okxassetlines_rec.asset_number,

Line 4425: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4421: x_msg_data => x_msg_data,
4422: x_return_status => x_return_status);
4423:
4424:
4425: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4426: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4427: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4428: RAISE OKC_API.G_EXCEPTION_ERROR;
4429: END IF;

Line 4426: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4422: x_return_status => x_return_status);
4423:
4424:
4425: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4426: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4427: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4428: RAISE OKC_API.G_EXCEPTION_ERROR;
4429: END IF;
4430:

Line 4427: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4423:
4424:
4425: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4426: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4427: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4428: RAISE OKC_API.G_EXCEPTION_ERROR;
4429: END IF;
4430:
4431: l_units_retired := l_units_to_be_retired;

Line 4428: RAISE OKC_API.G_EXCEPTION_ERROR;

4424:
4425: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4426: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4427: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4428: RAISE OKC_API.G_EXCEPTION_ERROR;
4429: END IF;
4430:
4431: l_units_retired := l_units_to_be_retired;
4432:

Line 4453: p_init_msg_list => OKC_API.G_FALSE,

4449:
4450: -- SECHAWLA 21-NOV-03, 3262519 : added tax owner and delta cost parameter to the following procedure
4451: do_cost_retirement(
4452: p_api_version => p_api_version,
4453: p_init_msg_list => OKC_API.G_FALSE,
4454: p_tax_owner => l_tax_owner,
4455: p_delta_cost => l_delta_cost,
4456: p_asset_id => l_okxassetlines_rec.asset_id,
4457: p_asset_number => l_okxassetlines_rec.asset_number,

Line 4470: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4466: x_msg_count => x_msg_count,
4467: x_msg_data => x_msg_data,
4468: x_return_status => x_return_status);
4469:
4470: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4471: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4472: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4473: RAISE OKC_API.G_EXCEPTION_ERROR;
4474: END IF;

Line 4471: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4467: x_msg_data => x_msg_data,
4468: x_return_status => x_return_status);
4469:
4470: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4471: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4472: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4473: RAISE OKC_API.G_EXCEPTION_ERROR;
4474: END IF;
4475: END IF;

Line 4472: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4468: x_return_status => x_return_status);
4469:
4470: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4471: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4472: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4473: RAISE OKC_API.G_EXCEPTION_ERROR;
4474: END IF;
4475: END IF;
4476: -- SECHAWLA 23-DEC-02 Bug # 2701440 : end new code

Line 4473: RAISE OKC_API.G_EXCEPTION_ERROR;

4469:
4470: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4471: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4472: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4473: RAISE OKC_API.G_EXCEPTION_ERROR;
4474: END IF;
4475: END IF;
4476: -- SECHAWLA 23-DEC-02 Bug # 2701440 : end new code
4477:

Line 4531: OKC_API.set_message( p_app_name => 'OKL',

4527: IF l_dist_quantity > 0 THEN -- quantity to be retired (for non-retired distributions)
4528: IF l_retired_dist_units < l_dist_quantity THEN -- retired quantity isn't enough to match up with total qty
4529:
4530: -- Sold quantity is more than the total quantity assigned to asset distributions.
4531: OKC_API.set_message( p_app_name => 'OKL',
4532: p_msg_name => 'OKL_AM_INVALID_DIST_QTY');
4533: END IF;
4534: -- SECHAWLA 21-OCT-04 3924244
4535: l_units_to_be_retired := l_ordered_quantity - l_dist_quantity; -- retire whatever is left

Line 4545: p_init_msg_list => OKC_API.G_FALSE,

4541: IF l_dist_tbl.COUNT > 0 THEN
4542: -- SECHAWLA 21-NOV-03, 3262519 : added tax owner and delta cost parameter to the following procedure
4543: do_partial_units_retirement(
4544: p_api_version => p_api_version,
4545: p_init_msg_list => OKC_API.G_FALSE,
4546: p_tax_owner => l_tax_owner,
4547: p_delta_cost => l_delta_cost,
4548: p_asset_id => l_okxassetlines_rec.asset_id,
4549: p_asset_number => l_okxassetlines_rec.asset_number,

Line 4562: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4558: x_msg_data => x_msg_data,
4559: x_return_status => x_return_status);
4560:
4561:
4562: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4563: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4564: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4565: RAISE OKC_API.G_EXCEPTION_ERROR;
4566: END IF;

Line 4563: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4559: x_return_status => x_return_status);
4560:
4561:
4562: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4563: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4564: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4565: RAISE OKC_API.G_EXCEPTION_ERROR;
4566: END IF;
4567:

Line 4564: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4560:
4561:
4562: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4563: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4564: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4565: RAISE OKC_API.G_EXCEPTION_ERROR;
4566: END IF;
4567:
4568:

Line 4565: RAISE OKC_API.G_EXCEPTION_ERROR;

4561:
4562: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4563: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4564: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4565: RAISE OKC_API.G_EXCEPTION_ERROR;
4566: END IF;
4567:
4568:
4569: /* SECHAWLA 21-NOV-03 3262519 : This fetch is not required. Cost to be retired from the tax book should be

Line 4617: p_init_msg_list => OKC_API.G_FALSE,

4613: -- do cost retirement for the tax book
4614: -- SECHAWLA 21-NOV-03, 3262519 : added tax owner and delta cost parameter to the following procedure
4615: do_cost_retirement(
4616: p_api_version => p_api_version,
4617: p_init_msg_list => OKC_API.G_FALSE,
4618: p_tax_owner => l_tax_owner,
4619: p_delta_cost => l_delta_cost,
4620: p_asset_id => l_okxassetlines_rec.asset_id,
4621: p_asset_number => l_okxassetlines_rec.asset_number,

Line 4631: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4627: x_msg_count => x_msg_count,
4628: x_msg_data => x_msg_data,
4629: x_return_status => x_return_status);
4630:
4631: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4632: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4633: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4634: RAISE OKC_API.G_EXCEPTION_ERROR;
4635: END IF;

Line 4632: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4628: x_msg_data => x_msg_data,
4629: x_return_status => x_return_status);
4630:
4631: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4632: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4633: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4634: RAISE OKC_API.G_EXCEPTION_ERROR;
4635: END IF;
4636:

Line 4633: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4629: x_return_status => x_return_status);
4630:
4631: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4632: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4633: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4634: RAISE OKC_API.G_EXCEPTION_ERROR;
4635: END IF;
4636:
4637: --SECHAWLA 21-NOV-2003 3262519 : This condition will not occur now that we calculate cost to be

Line 4634: RAISE OKC_API.G_EXCEPTION_ERROR;

4630:
4631: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4632: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4633: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4634: RAISE OKC_API.G_EXCEPTION_ERROR;
4635: END IF;
4636:
4637: --SECHAWLA 21-NOV-2003 3262519 : This condition will not occur now that we calculate cost to be
4638: -- retired from tax book using tax book cost itself

Line 4649: p_init_msg_list => OKC_API.G_FALSE,

4645: -- retire the whole remaining cost
4646: -- SECHAWLA 21-NOV-03, 3262519 : added tax owner and delta cost parameter to the following procedure
4647: do_cost_retirement(
4648: p_api_version => p_api_version,
4649: p_init_msg_list => OKC_API.G_FALSE,
4650: p_tax_owner => l_tax_owner,
4651: p_delta_cost => l_delta_cost,
4652: p_asset_id => l_okxassetlines_rec.asset_id,
4653: p_asset_number => l_okxassetlines_rec.asset_number,

Line 4663: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4659: x_msg_count => x_msg_count,
4660: x_msg_data => x_msg_data,
4661: x_return_status => x_return_status);
4662:
4663: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4664: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4665: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4666: RAISE OKC_API.G_EXCEPTION_ERROR;
4667: END IF;

Line 4664: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4660: x_msg_data => x_msg_data,
4661: x_return_status => x_return_status);
4662:
4663: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4664: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4665: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4666: RAISE OKC_API.G_EXCEPTION_ERROR;
4667: END IF;
4668: */

Line 4665: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4661: x_return_status => x_return_status);
4662:
4663: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4664: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4665: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4666: RAISE OKC_API.G_EXCEPTION_ERROR;
4667: END IF;
4668: */
4669:

Line 4666: RAISE OKC_API.G_EXCEPTION_ERROR;

4662:
4663: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4664: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4665: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4666: RAISE OKC_API.G_EXCEPTION_ERROR;
4667: END IF;
4668: */
4669:
4670: END IF;

Line 4693: RAISE OKC_API.G_EXCEPTION_ERROR;

4689: OKL_API.set_message(p_app_name => 'OKL',
4690: p_msg_name => 'OKL_AM_NO_TRX_TYPE_FOUND',
4691: p_token1 => 'TRY_NAME',
4692: p_token1_value => 'Asset Disposition');
4693: RAISE OKC_API.G_EXCEPTION_ERROR;
4694: END IF;
4695:
4696: lp_thpv_rec.tas_type := 'RFA';
4697: lp_thpv_rec.tsu_code := 'PROCESSED';

Line 4706: p_init_msg_list => OKC_API.G_FALSE,

4702: lp_thpv_rec.legal_entity_id := l_legal_entity_id;
4703: -- Legal Entity Changes End
4704:
4705: OKL_TRX_ASSETS_PUB.create_trx_ass_h_def( p_api_version => p_api_version,
4706: p_init_msg_list => OKC_API.G_FALSE,
4707: x_return_status => x_return_status,
4708: x_msg_count => x_msg_count,
4709: x_msg_data => x_msg_data,
4710: p_thpv_rec => lp_thpv_rec,

Line 4714: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4710: p_thpv_rec => lp_thpv_rec,
4711: x_thpv_rec => lx_thpv_rec);
4712:
4713:
4714: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4715: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4716: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4717: RAISE OKC_API.G_EXCEPTION_ERROR;
4718: END IF;

Line 4715: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4711: x_thpv_rec => lx_thpv_rec);
4712:
4713:
4714: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4715: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4716: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4717: RAISE OKC_API.G_EXCEPTION_ERROR;
4718: END IF;
4719:

Line 4716: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4712:
4713:
4714: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4715: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4716: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4717: RAISE OKC_API.G_EXCEPTION_ERROR;
4718: END IF;
4719:
4720: --SECHAWLA 03-JAN-03 2683876 Pass the currency code if creating/updating amounts in txl assets

Line 4717: RAISE OKC_API.G_EXCEPTION_ERROR;

4713:
4714: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4715: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4716: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4717: RAISE OKC_API.G_EXCEPTION_ERROR;
4718: END IF;
4719:
4720: --SECHAWLA 03-JAN-03 2683876 Pass the currency code if creating/updating amounts in txl assets
4721: l_func_curr_code := okl_am_util_pvt.get_functional_currency;

Line 4743: p_init_msg_list => OKC_API.G_FALSE,

4739: -- SECHAWLA 15-DEC-04 4028371 : set FA date on trx line
4740: lp_tlpv_rec.FA_TRX_DATE := l_fa_trx_date;
4741:
4742: OKL_TXL_ASSETS_PUB.create_txl_asset_def(p_api_version => p_api_version,
4743: p_init_msg_list => OKC_API.G_FALSE,
4744: x_return_status => x_return_status,
4745: x_msg_count => x_msg_count,
4746: x_msg_data => x_msg_data,
4747: p_tlpv_rec => lp_tlpv_rec,

Line 4750: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4746: x_msg_data => x_msg_data,
4747: p_tlpv_rec => lp_tlpv_rec,
4748: x_tlpv_rec => lx_tlpv_rec);
4749:
4750: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4751: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4752: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4753: RAISE OKC_API.G_EXCEPTION_ERROR;
4754: END IF;

Line 4751: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4747: p_tlpv_rec => lp_tlpv_rec,
4748: x_tlpv_rec => lx_tlpv_rec);
4749:
4750: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4751: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4752: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4753: RAISE OKC_API.G_EXCEPTION_ERROR;
4754: END IF;
4755:

Line 4752: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4748: x_tlpv_rec => lx_tlpv_rec);
4749:
4750: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4751: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4752: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4753: RAISE OKC_API.G_EXCEPTION_ERROR;
4754: END IF;
4755:
4756:

Line 4753: RAISE OKC_API.G_EXCEPTION_ERROR;

4749:
4750: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4751: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4752: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4753: RAISE OKC_API.G_EXCEPTION_ERROR;
4754: END IF;
4755:
4756:
4757:

Line 4761: p_init_msg_list => OKC_API.G_FALSE,

4757:
4758: -- make call to accounting entries
4759: process_accounting_entries(
4760: p_api_version => p_api_version,
4761: p_init_msg_list => OKC_API.G_FALSE,
4762: x_return_status => x_return_status,
4763: x_msg_count => x_msg_count,
4764: x_msg_data => x_msg_data,
4765: p_kle_id => l_kle_id,

Line 4776: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4772: x_total_amount => lx_total_amount,
4773: p_legal_entity_id => l_legal_entity_id);
4774:
4775: -- rollback if error in accounting entries
4776: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4777: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4778: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4779: RAISE OKC_API.G_EXCEPTION_ERROR;
4780: END IF;

Line 4777: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4773: p_legal_entity_id => l_legal_entity_id);
4774:
4775: -- rollback if error in accounting entries
4776: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4777: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4778: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4779: RAISE OKC_API.G_EXCEPTION_ERROR;
4780: END IF;
4781:

Line 4778: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4774:
4775: -- rollback if error in accounting entries
4776: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4777: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4778: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4779: RAISE OKC_API.G_EXCEPTION_ERROR;
4780: END IF;
4781:
4782: -- Store the amount at the header and line level in trx tables

Line 4779: RAISE OKC_API.G_EXCEPTION_ERROR;

4775: -- rollback if error in accounting entries
4776: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4777: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4778: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4779: RAISE OKC_API.G_EXCEPTION_ERROR;
4780: END IF;
4781:
4782: -- Store the amount at the header and line level in trx tables
4783:

Line 4791: p_init_msg_list => OKC_API.G_FALSE,

4787: lp_thpv_rec.total_match_amount := lx_total_amount;
4788:
4789: OKL_TRX_ASSETS_PUB.update_trx_ass_h_def(
4790: p_api_version => p_api_version,
4791: p_init_msg_list => OKC_API.G_FALSE,
4792: x_return_status => x_return_status,
4793: x_msg_count => x_msg_count,
4794: x_msg_data => x_msg_data,
4795: p_thpv_rec => lp_thpv_rec,

Line 4798: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4794: x_msg_data => x_msg_data,
4795: p_thpv_rec => lp_thpv_rec,
4796: x_thpv_rec => lx_thpv_rec);
4797:
4798: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4799: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4800: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4801: RAISE OKC_API.G_EXCEPTION_ERROR;
4802: END IF;

Line 4799: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4795: p_thpv_rec => lp_thpv_rec,
4796: x_thpv_rec => lx_thpv_rec);
4797:
4798: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4799: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4800: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4801: RAISE OKC_API.G_EXCEPTION_ERROR;
4802: END IF;
4803:

Line 4800: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4796: x_thpv_rec => lx_thpv_rec);
4797:
4798: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4799: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4800: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4801: RAISE OKC_API.G_EXCEPTION_ERROR;
4802: END IF;
4803:
4804: -- Update amount in the lines table.

Line 4801: RAISE OKC_API.G_EXCEPTION_ERROR;

4797:
4798: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4799: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4800: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4801: RAISE OKC_API.G_EXCEPTION_ERROR;
4802: END IF;
4803:
4804: -- Update amount in the lines table.
4805: lp_tlpv_rec := lp_tlpv_empty_rec;

Line 4817: p_init_msg_list => OKC_API.G_FALSE,

4813: lp_tlpv_rec.currency_code := l_func_curr_code;
4814:
4815: OKL_TXL_ASSETS_PUB.update_txl_asset_Def(
4816: p_api_version => p_api_version,
4817: p_init_msg_list => OKC_API.G_FALSE,
4818: x_return_status => x_return_status,
4819: x_msg_count => x_msg_count,
4820: x_msg_data => x_msg_data,
4821: p_tlpv_rec => lp_tlpv_rec,

Line 4824: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4820: x_msg_data => x_msg_data,
4821: p_tlpv_rec => lp_tlpv_rec,
4822: x_tlpv_rec => lx_tlpv_rec);
4823:
4824: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4825: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4826: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4827: RAISE OKC_API.G_EXCEPTION_ERROR;
4828: END IF;

Line 4825: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4821: p_tlpv_rec => lp_tlpv_rec,
4822: x_tlpv_rec => lx_tlpv_rec);
4823:
4824: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4825: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4826: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4827: RAISE OKC_API.G_EXCEPTION_ERROR;
4828: END IF;
4829: --- End store amounts at the header and line level

Line 4826: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4822: x_tlpv_rec => lx_tlpv_rec);
4823:
4824: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4825: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4826: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4827: RAISE OKC_API.G_EXCEPTION_ERROR;
4828: END IF;
4829: --- End store amounts at the header and line level
4830:

Line 4827: RAISE OKC_API.G_EXCEPTION_ERROR;

4823:
4824: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4825: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4826: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4827: RAISE OKC_API.G_EXCEPTION_ERROR;
4828: END IF;
4829: --- End store amounts at the header and line level
4830:
4831: END IF; -- if book_class = corporate

Line 4849: p_init_msg_list => OKC_API.G_FALSE,

4845: FOR l_itemlocation_rec in l_itemlocation_csr(l_kle_id) LOOP
4846: IF l_itemlocation_rec.instance_end_date IS NULL THEN-- Instance is not already expired.
4847: expire_item (
4848: p_api_version => p_api_version,
4849: p_init_msg_list => OKC_API.G_FALSE,
4850: x_msg_count => x_msg_count,
4851: x_msg_data => x_msg_data,
4852: x_return_status => x_return_status ,
4853: p_instance_id => l_itemlocation_rec.instance_id,

Line 4856: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4852: x_return_status => x_return_status ,
4853: p_instance_id => l_itemlocation_rec.instance_id,
4854: p_end_date => l_sys_date);
4855:
4856: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4857: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4858: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4859: RAISE OKC_API.G_EXCEPTION_ERROR;
4860: END IF;

Line 4857: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4853: p_instance_id => l_itemlocation_rec.instance_id,
4854: p_end_date => l_sys_date);
4855:
4856: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4857: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4858: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4859: RAISE OKC_API.G_EXCEPTION_ERROR;
4860: END IF;
4861:

Line 4858: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4854: p_end_date => l_sys_date);
4855:
4856: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4857: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4858: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4859: RAISE OKC_API.G_EXCEPTION_ERROR;
4860: END IF;
4861:
4862: END IF;

Line 4859: RAISE OKC_API.G_EXCEPTION_ERROR;

4855:
4856: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4857: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4858: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4859: RAISE OKC_API.G_EXCEPTION_ERROR;
4860: END IF;
4861:
4862: END IF;
4863:

Line 4873: p_init_msg_list => OKC_API.G_FALSE,

4869: FOR l_itemlocation_rec in l_itemlocation_csr(l_kle_id) LOOP
4870: IF l_itemlocation_rec.instance_end_date IS NULL THEN-- Instance is not already expired.
4871: expire_item (
4872: p_api_version => p_api_version,
4873: p_init_msg_list => OKC_API.G_FALSE,
4874: x_msg_count => x_msg_count,
4875: x_msg_data => x_msg_data,
4876: x_return_status => x_return_status ,
4877: p_instance_id => l_itemlocation_rec.instance_id,

Line 4880: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4876: x_return_status => x_return_status ,
4877: p_instance_id => l_itemlocation_rec.instance_id,
4878: p_end_date => l_sys_date);
4879:
4880: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4881: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4882: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4883: RAISE OKC_API.G_EXCEPTION_ERROR;
4884: END IF;

Line 4881: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4877: p_instance_id => l_itemlocation_rec.instance_id,
4878: p_end_date => l_sys_date);
4879:
4880: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4881: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4882: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4883: RAISE OKC_API.G_EXCEPTION_ERROR;
4884: END IF;
4885:

Line 4882: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4878: p_end_date => l_sys_date);
4879:
4880: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4881: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4882: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4883: RAISE OKC_API.G_EXCEPTION_ERROR;
4884: END IF;
4885:
4886: IF instance_counter = l_ordered_quantity THEN -- SECHAWLA 21-OCT-04 3924244

Line 4883: RAISE OKC_API.G_EXCEPTION_ERROR;

4879:
4880: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4881: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4882: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4883: RAISE OKC_API.G_EXCEPTION_ERROR;
4884: END IF;
4885:
4886: IF instance_counter = l_ordered_quantity THEN -- SECHAWLA 21-OCT-04 3924244
4887: EXIT;

Line 4910: p_init_msg_list => OKC_API.G_FALSE,

4906: lp_thpv_rec.id := l_assettrx_rec.id;
4907: lp_thpv_rec.tsu_code := 'CANCELED';
4908: OKL_TRX_ASSETS_PUB.update_trx_ass_h_def(
4909: p_api_version => p_api_version,
4910: p_init_msg_list => OKC_API.G_FALSE,
4911: x_return_status => x_return_status,
4912: x_msg_count => x_msg_count,
4913: x_msg_data => x_msg_data,
4914: p_thpv_rec => lp_thpv_rec,

Line 4917: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4913: x_msg_data => x_msg_data,
4914: p_thpv_rec => lp_thpv_rec,
4915: x_thpv_rec => lx_thpv_rec);
4916:
4917: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4918: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4919: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4920: RAISE OKC_API.G_EXCEPTION_ERROR;
4921: END IF;

Line 4918: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4914: p_thpv_rec => lp_thpv_rec,
4915: x_thpv_rec => lx_thpv_rec);
4916:
4917: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4918: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4919: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4920: RAISE OKC_API.G_EXCEPTION_ERROR;
4921: END IF;
4922: END LOOP;

Line 4919: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4915: x_thpv_rec => lx_thpv_rec);
4916:
4917: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4918: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4919: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4920: RAISE OKC_API.G_EXCEPTION_ERROR;
4921: END IF;
4922: END LOOP;
4923:

Line 4920: RAISE OKC_API.G_EXCEPTION_ERROR;

4916:
4917: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4918: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4919: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4920: RAISE OKC_API.G_EXCEPTION_ERROR;
4921: END IF;
4922: END LOOP;
4923:
4924: -- ++++++++++++++++++++ service contract integration begin ++++++++++++++++++

Line 4948: p_init_msg_list => OKC_API.G_FALSE,

4944: -------------- Securitization Processing -----------------------
4945:
4946: OKL_AM_SECURITIZATION_PVT.process_securitized_streams(
4947: p_api_version => p_api_version,
4948: p_init_msg_list => OKC_API.G_FALSE,
4949: x_return_status => x_return_status,
4950: x_msg_count => x_msg_count,
4951: x_msg_data => x_msg_data,
4952: p_kle_id => l_kle_id,

Line 4956: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

4952: p_kle_id => l_kle_id,
4953: p_sale_price => l_sale_amount,
4954: p_call_origin => OKL_SECURITIZATION_PVT.G_TRX_REASON_ASSET_DISPOSAL);
4955:
4956: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4957: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4958: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4959: RAISE OKC_API.G_EXCEPTION_ERROR;
4960: END IF;

Line 4957: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

4953: p_sale_price => l_sale_amount,
4954: p_call_origin => OKL_SECURITIZATION_PVT.G_TRX_REASON_ASSET_DISPOSAL);
4955:
4956: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4957: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4958: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4959: RAISE OKC_API.G_EXCEPTION_ERROR;
4960: END IF;
4961: -------------- end Securitization Processing -----------------------

Line 4958: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

4954: p_call_origin => OKL_SECURITIZATION_PVT.G_TRX_REASON_ASSET_DISPOSAL);
4955:
4956: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4957: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4958: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4959: RAISE OKC_API.G_EXCEPTION_ERROR;
4960: END IF;
4961: -------------- end Securitization Processing -----------------------
4962: --akrangan added for sla populate sources cr start

Line 4959: RAISE OKC_API.G_EXCEPTION_ERROR;

4955:
4956: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
4957: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
4958: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
4959: RAISE OKC_API.G_EXCEPTION_ERROR;
4960: END IF;
4961: -------------- end Securitization Processing -----------------------
4962: --akrangan added for sla populate sources cr start
4963: IF g_trans_id_tbl.COUNT > 0

Line 4981: p_init_msg_list => okc_api.g_false,

4977: l_fxlv_rec.fa_transaction_id := g_trans_id_tbl(i);
4978: l_fxlv_rec.asset_book_type_name := lx_tlpv_rec.corporate_book;
4979:
4980: okl_sla_acc_sources_pvt.populate_sources(p_api_version => p_api_version,
4981: p_init_msg_list => okc_api.g_false,
4982: p_fxhv_rec => l_fxhv_rec,
4983: p_fxlv_rec => l_fxlv_rec,
4984: x_return_status => x_return_status,
4985: x_msg_count => x_msg_count,

Line 4988: IF (x_return_status = okc_api.g_ret_sts_unexp_error)

4984: x_return_status => x_return_status,
4985: x_msg_count => x_msg_count,
4986: x_msg_data => x_msg_data);
4987:
4988: IF (x_return_status = okc_api.g_ret_sts_unexp_error)
4989: THEN
4990: RAISE okl_api.g_exception_unexpected_error;
4991: ELSIF (x_return_status = okc_api.g_ret_sts_error)
4992: THEN

Line 4991: ELSIF (x_return_status = okc_api.g_ret_sts_error)

4987:
4988: IF (x_return_status = okc_api.g_ret_sts_unexp_error)
4989: THEN
4990: RAISE okl_api.g_exception_unexpected_error;
4991: ELSIF (x_return_status = okc_api.g_ret_sts_error)
4992: THEN
4993: RAISE okl_api.g_exception_error;
4994: END IF;
4995: END LOOP;

Line 4999: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);

4995: END LOOP;
4996: END IF;
4997: --akrangan added for sla populate sources cr end
4998:
4999: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);
5000: EXCEPTION
5001: WHEN OKC_API.G_EXCEPTION_ERROR THEN
5002:
5003: IF l_orderheaders_csr%ISOPEN THEN

Line 5001: WHEN OKC_API.G_EXCEPTION_ERROR THEN

4997: --akrangan added for sla populate sources cr end
4998:
4999: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);
5000: EXCEPTION
5001: WHEN OKC_API.G_EXCEPTION_ERROR THEN
5002:
5003: IF l_orderheaders_csr%ISOPEN THEN
5004: CLOSE l_orderheaders_csr;
5005: END IF;

Line 5054: x_return_status := OKC_API.HANDLE_EXCEPTIONS

5050: IF l_offlseassettrx_csr%ISOPEN THEN
5051: CLOSE l_offlseassettrx_csr;
5052: END IF;
5053:
5054: x_return_status := OKC_API.HANDLE_EXCEPTIONS
5055: (
5056: l_api_name,
5057: G_PKG_NAME,
5058: 'OKC_API.G_RET_STS_ERROR',

Line 5058: 'OKC_API.G_RET_STS_ERROR',

5054: x_return_status := OKC_API.HANDLE_EXCEPTIONS
5055: (
5056: l_api_name,
5057: G_PKG_NAME,
5058: 'OKC_API.G_RET_STS_ERROR',
5059: x_msg_count,
5060: x_msg_data,
5061: '_PVT'
5062: );

Line 5063: WHEN OKC_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

5059: x_msg_count,
5060: x_msg_data,
5061: '_PVT'
5062: );
5063: WHEN OKC_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
5064:
5065: IF l_orderheaders_csr%ISOPEN THEN
5066: CLOSE l_orderheaders_csr;
5067: END IF;

Line 5116: x_return_status :=OKC_API.HANDLE_EXCEPTIONS

5112: IF l_offlseassettrx_csr%ISOPEN THEN
5113: CLOSE l_offlseassettrx_csr;
5114: END IF;
5115:
5116: x_return_status :=OKC_API.HANDLE_EXCEPTIONS
5117: (
5118: l_api_name,
5119: G_PKG_NAME,
5120: 'OKC_API.G_RET_STS_UNEXP_ERROR',

Line 5120: 'OKC_API.G_RET_STS_UNEXP_ERROR',

5116: x_return_status :=OKC_API.HANDLE_EXCEPTIONS
5117: (
5118: l_api_name,
5119: G_PKG_NAME,
5120: 'OKC_API.G_RET_STS_UNEXP_ERROR',
5121: x_msg_count,
5122: x_msg_data,
5123: '_PVT'
5124: );

Line 5178: x_return_status :=OKC_API.HANDLE_EXCEPTIONS

5174: IF l_offlseassettrx_csr%ISOPEN THEN
5175: CLOSE l_offlseassettrx_csr;
5176: END IF;
5177:
5178: x_return_status :=OKC_API.HANDLE_EXCEPTIONS
5179: (
5180: l_api_name,
5181: G_PKG_NAME,
5182: 'OTHERS',

Line 5215: l_return_status VARCHAR2(1) := OKC_API.G_RET_STS_SUCCESS;

5211: l_asset_retire_rec FA_API_TYPES.asset_retire_rec_type;
5212: l_asset_dist_tbl FA_API_TYPES.asset_dist_tbl_type;
5213: l_subcomp_tbl FA_API_TYPES.subcomp_tbl_type;
5214: l_inv_tbl FA_API_TYPES.inv_tbl_type;
5215: l_return_status VARCHAR2(1) := OKC_API.G_RET_STS_SUCCESS;
5216: l_api_name CONSTANT VARCHAR2(30) := 'undo_retirement';
5217: l_api_version CONSTANT NUMBER := 1;
5218: l_dummy VARCHAR2(1);
5219:

Line 5235: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

5231: p_api_version,
5232: '_PVT',
5233: x_return_status);
5234:
5235: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
5236: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
5237: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
5238: RAISE OKC_API.G_EXCEPTION_ERROR;
5239: END IF;

Line 5236: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

5232: '_PVT',
5233: x_return_status);
5234:
5235: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
5236: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
5237: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
5238: RAISE OKC_API.G_EXCEPTION_ERROR;
5239: END IF;
5240:

Line 5237: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN

5233: x_return_status);
5234:
5235: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
5236: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
5237: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
5238: RAISE OKC_API.G_EXCEPTION_ERROR;
5239: END IF;
5240:
5241: IF p_retirement_id IS NULL OR p_retirement_id = OKL_API.G_MISS_NUM THEN

Line 5238: RAISE OKC_API.G_EXCEPTION_ERROR;

5234:
5235: IF (l_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
5236: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
5237: ELSIF (l_return_status = OKC_API.G_RET_STS_ERROR) THEN
5238: RAISE OKC_API.G_EXCEPTION_ERROR;
5239: END IF;
5240:
5241: IF p_retirement_id IS NULL OR p_retirement_id = OKL_API.G_MISS_NUM THEN
5242: x_return_status := OKL_API.G_RET_STS_ERROR;

Line 5244: OKC_API.set_message( p_app_name => 'OKC',

5240:
5241: IF p_retirement_id IS NULL OR p_retirement_id = OKL_API.G_MISS_NUM THEN
5242: x_return_status := OKL_API.G_RET_STS_ERROR;
5243: -- retirement id is required
5244: OKC_API.set_message( p_app_name => 'OKC',
5245: p_msg_name => G_REQUIRED_VALUE,
5246: p_token1 => G_COL_NAME_TOKEN,
5247: p_token1_value => 'RETIREMENT_ID');
5248:

Line 5250: RAISE OKC_API.G_EXCEPTION_ERROR;

5246: p_token1 => G_COL_NAME_TOKEN,
5247: p_token1_value => 'RETIREMENT_ID');
5248:
5249:
5250: RAISE OKC_API.G_EXCEPTION_ERROR;
5251: END IF;
5252:
5253: OPEN l_faretirement_csr(p_retirement_id);
5254: FETCH l_faretirement_csr INTO l_dummy;

Line 5258: OKC_API.set_message( p_app_name => 'OKC',

5254: FETCH l_faretirement_csr INTO l_dummy;
5255: IF l_faretirement_csr%NOTFOUND THEN
5256: x_return_status := OKL_API.G_RET_STS_ERROR;
5257: -- retirement id is invalid
5258: OKC_API.set_message( p_app_name => 'OKC',
5259: p_msg_name => G_INVALID_VALUE,
5260: p_token1 => G_COL_NAME_TOKEN,
5261: p_token1_value => 'RETIREMENT_ID');
5262:

Line 5264: RAISE OKC_API.G_EXCEPTION_ERROR;

5260: p_token1 => G_COL_NAME_TOKEN,
5261: p_token1_value => 'RETIREMENT_ID');
5262:
5263:
5264: RAISE OKC_API.G_EXCEPTION_ERROR;
5265: END IF;
5266: CLOSE l_faretirement_csr;
5267:
5268: -- transaction information

Line 5281: p_init_msg_list => OKC_API.G_FALSE,

5277: l_asset_retire_rec.retirement_id := p_retirement_id;
5278:
5279:
5280: FA_RETIREMENT_PUB.undo_retirement( p_api_version => p_api_version,
5281: p_init_msg_list => OKC_API.G_FALSE,
5282: p_commit => FND_API.G_FALSE,
5283: p_validation_level => FND_API.G_VALID_LEVEL_FULL,
5284: p_calling_fn => NULL,
5285: x_return_status => x_return_status,

Line 5292: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN

5288: px_trans_rec => l_trans_rec,
5289: px_asset_hdr_rec => l_asset_hdr_rec,
5290: px_asset_retire_rec => l_asset_retire_rec );
5291:
5292: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
5293: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
5294: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
5295: RAISE OKC_API.G_EXCEPTION_ERROR;
5296: END IF;

Line 5293: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;

5289: px_asset_hdr_rec => l_asset_hdr_rec,
5290: px_asset_retire_rec => l_asset_retire_rec );
5291:
5292: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
5293: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
5294: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
5295: RAISE OKC_API.G_EXCEPTION_ERROR;
5296: END IF;
5297:

Line 5294: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN

5290: px_asset_retire_rec => l_asset_retire_rec );
5291:
5292: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
5293: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
5294: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
5295: RAISE OKC_API.G_EXCEPTION_ERROR;
5296: END IF;
5297:
5298:

Line 5295: RAISE OKC_API.G_EXCEPTION_ERROR;

5291:
5292: IF (x_return_status = OKC_API.G_RET_STS_UNEXP_ERROR) THEN
5293: RAISE OKC_API.G_EXCEPTION_UNEXPECTED_ERROR;
5294: ELSIF (x_return_status = OKC_API.G_RET_STS_ERROR) THEN
5295: RAISE OKC_API.G_EXCEPTION_ERROR;
5296: END IF;
5297:
5298:
5299: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);

Line 5299: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);

5295: RAISE OKC_API.G_EXCEPTION_ERROR;
5296: END IF;
5297:
5298:
5299: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);
5300: EXCEPTION
5301: WHEN OKC_API.G_EXCEPTION_ERROR THEN
5302: IF l_faretirement_csr%ISOPEN THEN
5303: CLOSE l_faretirement_csr;

Line 5301: WHEN OKC_API.G_EXCEPTION_ERROR THEN

5297:
5298:
5299: OKC_API.END_ACTIVITY(x_msg_count, x_msg_data);
5300: EXCEPTION
5301: WHEN OKC_API.G_EXCEPTION_ERROR THEN
5302: IF l_faretirement_csr%ISOPEN THEN
5303: CLOSE l_faretirement_csr;
5304: END IF;
5305: x_return_status := OKC_API.HANDLE_EXCEPTIONS

Line 5305: x_return_status := OKC_API.HANDLE_EXCEPTIONS

5301: WHEN OKC_API.G_EXCEPTION_ERROR THEN
5302: IF l_faretirement_csr%ISOPEN THEN
5303: CLOSE l_faretirement_csr;
5304: END IF;
5305: x_return_status := OKC_API.HANDLE_EXCEPTIONS
5306: (
5307: l_api_name,
5308: G_PKG_NAME,
5309: 'OKC_API.G_RET_STS_ERROR',

Line 5309: 'OKC_API.G_RET_STS_ERROR',

5305: x_return_status := OKC_API.HANDLE_EXCEPTIONS
5306: (
5307: l_api_name,
5308: G_PKG_NAME,
5309: 'OKC_API.G_RET_STS_ERROR',
5310: x_msg_count,
5311: x_msg_data,
5312: '_PVT'
5313: );

Line 5314: WHEN OKC_API.G_EXCEPTION_UNEXPECTED_ERROR THEN

5310: x_msg_count,
5311: x_msg_data,
5312: '_PVT'
5313: );
5314: WHEN OKC_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
5315: IF l_faretirement_csr%ISOPEN THEN
5316: CLOSE l_faretirement_csr;
5317: END IF;
5318: x_return_status :=OKC_API.HANDLE_EXCEPTIONS

Line 5318: x_return_status :=OKC_API.HANDLE_EXCEPTIONS

5314: WHEN OKC_API.G_EXCEPTION_UNEXPECTED_ERROR THEN
5315: IF l_faretirement_csr%ISOPEN THEN
5316: CLOSE l_faretirement_csr;
5317: END IF;
5318: x_return_status :=OKC_API.HANDLE_EXCEPTIONS
5319: (
5320: l_api_name,
5321: G_PKG_NAME,
5322: 'OKC_API.G_RET_STS_UNEXP_ERROR',

Line 5322: 'OKC_API.G_RET_STS_UNEXP_ERROR',

5318: x_return_status :=OKC_API.HANDLE_EXCEPTIONS
5319: (
5320: l_api_name,
5321: G_PKG_NAME,
5322: 'OKC_API.G_RET_STS_UNEXP_ERROR',
5323: x_msg_count,
5324: x_msg_data,
5325: '_PVT'
5326: );

Line 5331: x_return_status :=OKC_API.HANDLE_EXCEPTIONS

5327: WHEN OTHERS THEN
5328: IF l_faretirement_csr%ISOPEN THEN
5329: CLOSE l_faretirement_csr;
5330: END IF;
5331: x_return_status :=OKC_API.HANDLE_EXCEPTIONS
5332: (
5333: l_api_name,
5334: G_PKG_NAME,
5335: 'OTHERS',