DBA Data[Home] [Help]

APPS.HZ_PARTY_USG_ASSIGNMENT_PVT dependencies on FND_API

Line 406: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR

402: --
403: -- conditional mandatory: owner_table_name, owner_table_id
404: --
405: IF p_party_usg_assignment_rec.owner_table_name IS NOT NULL AND
406: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR
407: THEN
408: hz_utility_v2pub.validate_mandatory (
409: p_create_update_flag => p_create_update_flag,
410: p_column => 'owner_table_id',

Line 417: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM

413: );
414: END IF;
415:
416: IF p_party_usg_assignment_rec.owner_table_id IS NOT NULL AND
417: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM
418: THEN
419: hz_utility_v2pub.validate_mandatory (
420: p_create_update_flag => p_create_update_flag,
421: p_column => 'owner_table_name',

Line 449: x_return_status := fnd_api.G_RET_STS_ERROR;

445: fnd_message.set_token('FK', 'owner_table_id');
446: fnd_message.set_token('COLUMN', 'relationship_id');
447: fnd_message.set_token('TABLE', 'hz_relationships');
448: fnd_msg_pub.add;
449: x_return_status := fnd_api.G_RET_STS_ERROR;
450: END IF;
451:
452: -- Debug info.
453: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN

Line 553: x_return_status := fnd_api.G_RET_STS_ERROR;

549: fnd_message.set_name('AR', 'HZ_API_DATE_GREATER');
550: fnd_message.set_token('DATE2', 'effective_end_date');
551: fnd_message.set_token('DATE1', 'effective_start_date');
552: fnd_msg_pub.add;
553: x_return_status := fnd_api.G_RET_STS_ERROR;
554: END IF;
555:
556: -- Debug info.
557: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN

Line 578: IF x_return_status = fnd_api.G_RET_STS_ERROR THEN

574:
575: --
576: -- quit when basic validations fail
577: --
578: IF x_return_status = fnd_api.G_RET_STS_ERROR THEN
579: RETURN;
580: END IF;
581:
582: END IF; -- HIGH VALIDATION

Line 624: x_return_status := fnd_api.G_RET_STS_ERROR;

620: --
621: fnd_message.set_name('AR', 'HZ_PU_INVALID_PARTY_USAGE_CODE');
622: fnd_message.set_token('PARTY_USAGE_CODE', l_party_usage_code);
623: fnd_msg_pub.add;
624: x_return_status := fnd_api.G_RET_STS_ERROR;
625: END IF;
626:
627: -- Debug info.
628: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN

Line 644: x_return_status := fnd_api.G_RET_STS_ERROR;

640: IF db_party_usage_status <> 'A' THEN
641: fnd_message.set_name('AR', 'HZ_PU_INACTIVE_PARTY_USG_CODE');
642: fnd_message.set_token('PARTY_USAGE_CODE', p_party_usg_assignment_rec.party_usage_code);
643: fnd_msg_pub.add;
644: x_return_status := fnd_api.G_RET_STS_ERROR;
645: END IF;
646:
647: -- Debug info.
648: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN

Line 667: x_return_status := fnd_api.G_RET_STS_ERROR;

663: fnd_message.set_token('FK', 'party_id');
664: fnd_message.set_token('COLUMN', 'party_id');
665: fnd_message.set_token('TABLE', 'hz_parties');
666: fnd_msg_pub.add;
667: x_return_status := fnd_api.G_RET_STS_ERROR;
668: END IF;
669: CLOSE c_party;
670:
671: -- Debug info.

Line 689: x_return_status := fnd_api.G_RET_STS_ERROR;

685: fnd_message.set_name('AR', 'HZ_PU_INVALID_PARTY_TYPE');
686: fnd_message.set_token('PARTY_USAGE_CODE', p_party_usg_assignment_rec.party_usage_code);
687: fnd_message.set_token('PARTY_TYPE', db_party_type);
688: fnd_msg_pub.add;
689: x_return_status := fnd_api.G_RET_STS_ERROR;
690: END IF;
691:
692: -- Debug info.
693: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN

Line 723: x_return_status := fnd_api.G_RET_STS_ERROR;

719: THEN
720: fnd_message.set_name('AR', 'HZ_PU_SEED_CBM_ASSIGN');
721: fnd_message.set_token('PARTY_USAGE_CODE', l_party_usage_code);
722: fnd_msg_pub.add;
723: x_return_status := fnd_api.G_RET_STS_ERROR;
724: END IF;
725:
726: -- Debug info.
727: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN

Line 759: x_return_status := fnd_api.G_RET_STS_ERROR;

755: THEN
756: fnd_message.set_name('AR', 'HZ_PU_SEED_CBM_UPDATE');
757: fnd_message.set_token('PARTY_USAGE_CODE', l_party_usage_code);
758: fnd_msg_pub.add;
759: x_return_status := fnd_api.G_RET_STS_ERROR;
760: END IF;
761:
762: -- Debug info.
763: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN

Line 827: x_return_status := fnd_api.G_RET_STS_ERROR;

823: fnd_message.set_name('AR', 'HZ_PU_EXCLUSIVE_RULE_FAILED');
824: fnd_message.set_token('EXISTING_PARTY_USAGE_CODE', l_party_usage_codes_tbl(i));
825: fnd_message.set_token('NEW_PARTY_USAGE_CODE', l_party_usage_code);
826: fnd_msg_pub.add;
827: x_return_status := fnd_api.G_RET_STS_ERROR;
828:
829: l_continue := 'N';
830: END IF;
831:

Line 936: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR AND

932: --
933: -- check owner_table_name, owner_table_id
934: --
935: IF p_party_usg_assignment_rec.owner_table_name IS NOT NULL AND
936: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR AND
937: p_party_usg_assignment_rec.owner_table_id IS NOT NULL AND
938: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM
939: THEN
940: -- Debug info.

Line 938: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM

934: --
935: IF p_party_usg_assignment_rec.owner_table_name IS NOT NULL AND
936: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR AND
937: p_party_usg_assignment_rec.owner_table_id IS NOT NULL AND
938: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM
939: THEN
940: -- Debug info.
941: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN
942: hz_utility_v2pub.debug(

Line 966: p_party_usg_assignment_rec.party_id <> fnd_api.G_MISS_NUM AND

962: --
963: -- check party_id, party_usage_code, effective_start_date, effective_end_date
964: --
965: ELSIF p_party_usg_assignment_rec.party_id IS NOT NULL AND
966: p_party_usg_assignment_rec.party_id <> fnd_api.G_MISS_NUM AND
967: p_party_usg_assignment_rec.party_usage_code IS NOT NULL AND
968: p_party_usg_assignment_rec.party_usage_code <> fnd_api.G_MISS_CHAR
969: THEN
970: -- Debug info.

Line 968: p_party_usg_assignment_rec.party_usage_code <> fnd_api.G_MISS_CHAR

964: --
965: ELSIF p_party_usg_assignment_rec.party_id IS NOT NULL AND
966: p_party_usg_assignment_rec.party_id <> fnd_api.G_MISS_NUM AND
967: p_party_usg_assignment_rec.party_usage_code IS NOT NULL AND
968: p_party_usg_assignment_rec.party_usage_code <> fnd_api.G_MISS_CHAR
969: THEN
970: -- Debug info.
971: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN
972: hz_utility_v2pub.debug(

Line 1082: p_party_usg_assignment_rec.effective_start_date = fnd_api.G_MISS_DATE

1078: END IF;
1079:
1080: -- check dates.
1081: IF p_party_usg_assignment_rec.effective_start_date IS NULL OR
1082: p_party_usg_assignment_rec.effective_start_date = fnd_api.G_MISS_DATE
1083: THEN
1084: p_party_usg_assignment_rec.effective_start_date := trunc(sysdate);
1085: ELSE
1086: p_party_usg_assignment_rec.effective_start_date :=

Line 1091: p_party_usg_assignment_rec.effective_end_date = fnd_api.G_MISS_DATE

1087: trunc(p_party_usg_assignment_rec.effective_start_date);
1088: END IF;
1089:
1090: IF p_party_usg_assignment_rec.effective_end_date IS NULL OR
1091: p_party_usg_assignment_rec.effective_end_date = fnd_api.G_MISS_DATE
1092: THEN
1093: p_party_usg_assignment_rec.effective_end_date := D_FUTURE_DATE;
1094: ELSE
1095: p_party_usg_assignment_rec.effective_end_date :=

Line 1122: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN

1118: p_old_usg_assignment_rec => l_party_usg_assignment_rec,
1119: x_return_status => x_return_status
1120: );
1121:
1122: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
1123: RAISE fnd_api.G_EXC_ERROR;
1124: END IF;
1125: END IF;
1126:

Line 1123: RAISE fnd_api.G_EXC_ERROR;

1119: x_return_status => x_return_status
1120: );
1121:
1122: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
1123: RAISE fnd_api.G_EXC_ERROR;
1124: END IF;
1125: END IF;
1126:
1127: --

Line 1286: p_party_usg_assignment_rec.effective_start_date = fnd_api.G_MISS_DATE

1282: l_object_version_number1 := null;
1283:
1284: -- check dates.
1285: IF p_party_usg_assignment_rec.effective_start_date IS NULL OR
1286: p_party_usg_assignment_rec.effective_start_date = fnd_api.G_MISS_DATE
1287: THEN
1288: p_party_usg_assignment_rec.effective_start_date :=
1289: p_old_usg_assignment_rec_tbl(i).effective_start_date;
1290: ELSE

Line 1296: p_party_usg_assignment_rec.effective_end_date <> fnd_api.G_MISS_DATE

1292: trunc(p_party_usg_assignment_rec.effective_start_date);
1293: END IF;
1294:
1295: IF p_party_usg_assignment_rec.effective_end_date IS NOT NULL AND
1296: p_party_usg_assignment_rec.effective_end_date <> fnd_api.G_MISS_DATE
1297: THEN
1298: p_party_usg_assignment_rec.effective_end_date :=
1299: trunc(p_party_usg_assignment_rec.effective_end_date);
1300: ELSIF p_party_usg_assignment_rec.effective_end_date IS NULL THEN

Line 1330: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN

1326: p_old_usg_assignment_rec => p_old_usg_assignment_rec_tbl(i),
1327: x_return_status => x_return_status
1328: );
1329:
1330: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
1331: RAISE fnd_api.G_EXC_ERROR;
1332: END IF;
1333: END IF;
1334:

Line 1331: RAISE fnd_api.G_EXC_ERROR;

1327: x_return_status => x_return_status
1328: );
1329:
1330: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
1331: RAISE fnd_api.G_EXC_ERROR;
1332: END IF;
1333: END IF;
1334:
1335: --

Line 1736: RAISE fnd_api.g_exc_error;

1732: IF p_object_version_number <> l_object_version_number THEN
1733: fnd_message.set_name('AR', 'HZ_API_RECORD_CHANGED');
1734: fnd_message.set_token('TABLE', 'hz_party_usg_assignments');
1735: fnd_msg_pub.add;
1736: RAISE fnd_api.g_exc_error;
1737: END IF;
1738: END IF;
1739:
1740: p_object_version_number := l_object_version_number + 1;

Line 1861: * fnd_api.G_TRUE. Default is fnd_api.G_FALSE.

1857: *
1858: * ARGUMENTS
1859: * IN:
1860: * p_init_msg_list Initialize message stack if it is set to
1861: * fnd_api.G_TRUE. Default is fnd_api.G_FALSE.
1862: * p_validation_level Validation level. Default is full validation.
1863: * p_party_usg_assignment_rec Party usage assignment record.
1864: * IN/OUT:
1865: * OUT:

Line 1867: * be fnd_api.G_RET_STS_SUCCESS (success),

1863: * p_party_usg_assignment_rec Party usage assignment record.
1864: * IN/OUT:
1865: * OUT:
1866: * x_return_status Return status after the call. The status can
1867: * be fnd_api.G_RET_STS_SUCCESS (success),
1868: * fnd_api.G_RET_STS_ERROR (error),
1869: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
1870: * x_msg_count Number of messages in message stack.
1871: * x_msg_data Message text if x_msg_count is 1.

Line 1868: * fnd_api.G_RET_STS_ERROR (error),

1864: * IN/OUT:
1865: * OUT:
1866: * x_return_status Return status after the call. The status can
1867: * be fnd_api.G_RET_STS_SUCCESS (success),
1868: * fnd_api.G_RET_STS_ERROR (error),
1869: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
1870: * x_msg_count Number of messages in message stack.
1871: * x_msg_data Message text if x_msg_count is 1.
1872: *

Line 1869: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).

1865: * OUT:
1866: * x_return_status Return status after the call. The status can
1867: * be fnd_api.G_RET_STS_SUCCESS (success),
1868: * fnd_api.G_RET_STS_ERROR (error),
1869: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
1870: * x_msg_count Number of messages in message stack.
1871: * x_msg_data Message text if x_msg_count is 1.
1872: *
1873: * NOTES

Line 1913: fnd_api.To_Boolean(p_init_msg_list)

1909: END IF;
1910:
1911: -- initialize message list if p_init_msg_list is set to TRUE.
1912: IF p_init_msg_list IS NOT NULL AND
1913: fnd_api.To_Boolean(p_init_msg_list)
1914: THEN
1915: fnd_msg_pub.initialize;
1916: END IF;
1917:

Line 1926: x_return_status := fnd_api.G_RET_STS_SUCCESS;

1922: l_validation_level := p_validation_level;
1923: END IF;
1924:
1925: -- initialize API return status to success.
1926: x_return_status := fnd_api.G_RET_STS_SUCCESS;
1927:
1928: -- call to business logic.
1929: l_party_usg_assignment_rec := p_party_usg_assignment_rec;
1930:

Line 1939: p_encoded => fnd_api.G_FALSE,

1935: );
1936:
1937: -- standard call to get message count and if count is 1, get message info.
1938: fnd_msg_pub.Count_And_Get (
1939: p_encoded => fnd_api.G_FALSE,
1940: p_count => x_msg_count,
1941: p_data => x_msg_data);
1942:
1943: -- Debug info.

Line 1962: WHEN fnd_api.G_EXC_ERROR THEN

1958: );
1959: END IF;
1960:
1961: EXCEPTION
1962: WHEN fnd_api.G_EXC_ERROR THEN
1963: ROLLBACK TO assign_party_usage;
1964: x_return_status := fnd_api.G_RET_STS_ERROR;
1965:
1966: fnd_msg_pub.Count_And_Get (

Line 1964: x_return_status := fnd_api.G_RET_STS_ERROR;

1960:
1961: EXCEPTION
1962: WHEN fnd_api.G_EXC_ERROR THEN
1963: ROLLBACK TO assign_party_usage;
1964: x_return_status := fnd_api.G_RET_STS_ERROR;
1965:
1966: fnd_msg_pub.Count_And_Get (
1967: p_encoded => fnd_api.G_FALSE,
1968: p_count => x_msg_count,

Line 1967: p_encoded => fnd_api.G_FALSE,

1963: ROLLBACK TO assign_party_usage;
1964: x_return_status := fnd_api.G_RET_STS_ERROR;
1965:
1966: fnd_msg_pub.Count_And_Get (
1967: p_encoded => fnd_api.G_FALSE,
1968: p_count => x_msg_count,
1969: p_data => x_msg_data
1970: );
1971:

Line 1990: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN

1986: p_msg_level => fnd_log.level_procedure
1987: );
1988: END IF;
1989:
1990: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
1991: ROLLBACK TO assign_party_usage;
1992: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
1993: fnd_msg_pub.Count_And_Get (
1994: p_encoded => fnd_api.G_FALSE,

Line 1992: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

1988: END IF;
1989:
1990: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
1991: ROLLBACK TO assign_party_usage;
1992: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
1993: fnd_msg_pub.Count_And_Get (
1994: p_encoded => fnd_api.G_FALSE,
1995: p_count => x_msg_count,
1996: p_data => x_msg_data

Line 1994: p_encoded => fnd_api.G_FALSE,

1990: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
1991: ROLLBACK TO assign_party_usage;
1992: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
1993: fnd_msg_pub.Count_And_Get (
1994: p_encoded => fnd_api.G_FALSE,
1995: p_count => x_msg_count,
1996: p_data => x_msg_data
1997: );
1998:

Line 2019: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

2015: END IF;
2016:
2017: WHEN OTHERS THEN
2018: ROLLBACK TO assign_party_usage;
2019: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2020:
2021: fnd_message.set_name('AR', 'HZ_API_OTHERS_EXCEP');
2022: fnd_message.set_token('ERROR' ,SQLERRM);
2023: fnd_msg_pub.add;

Line 2026: p_encoded => fnd_api.G_FALSE,

2022: fnd_message.set_token('ERROR' ,SQLERRM);
2023: fnd_msg_pub.add;
2024:
2025: fnd_msg_pub.Count_And_Get (
2026: p_encoded => fnd_api.G_FALSE,
2027: p_count => x_msg_count,
2028: p_data => x_msg_data
2029: );
2030:

Line 2063: * fnd_api.G_TRUE. Default is fnd_api.G_FALSE.

2059: *
2060: * ARGUMENTS
2061: * IN:
2062: * p_init_msg_list Initialize message stack if it is set to
2063: * fnd_api.G_TRUE. Default is fnd_api.G_FALSE.
2064: * p_party_usg_assignment_id Party usage assignment Id.
2065: * p_party_usg_assignment_rec Party usage assignment record.
2066: * IN/OUT:
2067: * OUT:

Line 2071: * be fnd_api.G_RET_STS_SUCCESS (success),

2067: * OUT:
2068: * x_usg_assignment_id_tbl Table of party usage assignment Id.
2069: * x_usg_assignment_rec_tbl Table of party usage assignment record.
2070: * x_return_status Return status after the call. The status can
2071: * be fnd_api.G_RET_STS_SUCCESS (success),
2072: * fnd_api.G_RET_STS_ERROR (error),
2073: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
2074: * x_msg_count Number of messages in message stack.
2075: * x_msg_data Message text if x_msg_count is 1.

Line 2072: * fnd_api.G_RET_STS_ERROR (error),

2068: * x_usg_assignment_id_tbl Table of party usage assignment Id.
2069: * x_usg_assignment_rec_tbl Table of party usage assignment record.
2070: * x_return_status Return status after the call. The status can
2071: * be fnd_api.G_RET_STS_SUCCESS (success),
2072: * fnd_api.G_RET_STS_ERROR (error),
2073: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
2074: * x_msg_count Number of messages in message stack.
2075: * x_msg_data Message text if x_msg_count is 1.
2076: *

Line 2073: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).

2069: * x_usg_assignment_rec_tbl Table of party usage assignment record.
2070: * x_return_status Return status after the call. The status can
2071: * be fnd_api.G_RET_STS_SUCCESS (success),
2072: * fnd_api.G_RET_STS_ERROR (error),
2073: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
2074: * x_msg_count Number of messages in message stack.
2075: * x_msg_data Message text if x_msg_count is 1.
2076: *
2077: * NOTES

Line 2120: fnd_api.to_Boolean(p_init_msg_list)

2116: END IF;
2117:
2118: -- initialize message list if p_init_msg_list is set to TRUE.
2119: IF p_init_msg_list IS NOT NULL AND
2120: fnd_api.to_Boolean(p_init_msg_list)
2121: THEN
2122: fnd_msg_pub.initialize;
2123: END IF;
2124:

Line 2126: x_return_status := fnd_api.G_RET_STS_SUCCESS;

2122: fnd_msg_pub.initialize;
2123: END IF;
2124:
2125: -- initialize API return status to success.
2126: x_return_status := fnd_api.G_RET_STS_SUCCESS;
2127:
2128: x_usg_assignment_id_tbl := NUMBER15_TBL();
2129: x_usg_assignment_rec_tbl := ASSIGNMENT_REC_TBL();
2130:

Line 2134: p_party_usg_assignment_id <> fnd_api.G_MISS_NUM

2130:
2131: -- check assignment id
2132: --
2133: IF p_party_usg_assignment_id IS NOT NULL AND
2134: p_party_usg_assignment_id <> fnd_api.G_MISS_NUM
2135: THEN
2136: l_search_by := 'ASSIGNMENT_ID';
2137: OPEN c_assignment FOR
2138: SELECT *

Line 2145: p_party_usg_assignment_rec.party_usage_code <> fnd_api.G_MISS_CHAR AND

2141: --
2142: -- check party_id, party_usage_code
2143: --
2144: ELSIF p_party_usg_assignment_rec.party_usage_code IS NOT NULL AND
2145: p_party_usg_assignment_rec.party_usage_code <> fnd_api.G_MISS_CHAR AND
2146: p_party_usg_assignment_rec.party_id IS NOT NULL AND
2147: p_party_usg_assignment_rec.party_id <> fnd_api.G_MISS_NUM
2148: THEN
2149: l_search_by := 'USAGE_CODE';

Line 2147: p_party_usg_assignment_rec.party_id <> fnd_api.G_MISS_NUM

2143: --
2144: ELSIF p_party_usg_assignment_rec.party_usage_code IS NOT NULL AND
2145: p_party_usg_assignment_rec.party_usage_code <> fnd_api.G_MISS_CHAR AND
2146: p_party_usg_assignment_rec.party_id IS NOT NULL AND
2147: p_party_usg_assignment_rec.party_id <> fnd_api.G_MISS_NUM
2148: THEN
2149: l_search_by := 'USAGE_CODE';
2150: OPEN c_assignment FOR
2151: SELECT *

Line 2161: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR AND

2157: --
2158: -- check owner_table_name, owner_table_id
2159: --
2160: ELSIF p_party_usg_assignment_rec.owner_table_name IS NOT NULL AND
2161: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR AND
2162: p_party_usg_assignment_rec.owner_table_id IS NOT NULL AND
2163: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM
2164: THEN
2165: l_search_by := 'OWNER_TABLE_NAME';

Line 2163: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM

2159: --
2160: ELSIF p_party_usg_assignment_rec.owner_table_name IS NOT NULL AND
2161: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR AND
2162: p_party_usg_assignment_rec.owner_table_id IS NOT NULL AND
2163: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM
2164: THEN
2165: l_search_by := 'OWNER_TABLE_NAME';
2166: OPEN c_assignment FOR
2167: SELECT *

Line 2176: RAISE fnd_api.G_EXC_ERROR;

2172: --
2173: ELSE
2174: fnd_message.set_name('AR', 'HZ_PU_MISSING_COLUMN');
2175: fnd_msg_pub.add;
2176: RAISE fnd_api.G_EXC_ERROR;
2177: END IF;
2178:
2179: l_counter := 0;
2180: LOOP

Line 2236: RAISE fnd_api.G_EXC_ERROR;

2232: l_search_by IN ('USAGE_CODE', 'ASSIGNMENT_ID')
2233: THEN
2234: fnd_message.set_name('AR', 'HZ_PU_MULTIPLE_ASSIGNMENT');
2235: fnd_msg_pub.add;
2236: RAISE fnd_api.G_EXC_ERROR;
2237: --
2238: -- no assignment exist
2239: --
2240: ELSIF l_counter = 0 THEN

Line 2243: RAISE fnd_api.G_EXC_ERROR;

2239: --
2240: ELSIF l_counter = 0 THEN
2241: fnd_message.set_name('AR', 'HZ_PU_INVALID_ASSIGNMENT');
2242: fnd_msg_pub.add;
2243: RAISE fnd_api.G_EXC_ERROR;
2244: END IF;
2245:
2246: -- standard call to get message count and if count is 1, get message info.
2247: fnd_msg_pub.Count_And_Get (

Line 2248: p_encoded => fnd_api.G_FALSE,

2244: END IF;
2245:
2246: -- standard call to get message count and if count is 1, get message info.
2247: fnd_msg_pub.Count_And_Get (
2248: p_encoded => fnd_api.G_FALSE,
2249: p_count => x_msg_count,
2250: p_data => x_msg_data);
2251:
2252: -- Debug info.

Line 2271: WHEN fnd_api.G_EXC_ERROR THEN

2267: );
2268: END IF;
2269:
2270: EXCEPTION
2271: WHEN fnd_api.G_EXC_ERROR THEN
2272: x_return_status := fnd_api.G_RET_STS_ERROR;
2273:
2274: fnd_msg_pub.Count_And_Get (
2275: p_encoded => fnd_api.G_FALSE,

Line 2272: x_return_status := fnd_api.G_RET_STS_ERROR;

2268: END IF;
2269:
2270: EXCEPTION
2271: WHEN fnd_api.G_EXC_ERROR THEN
2272: x_return_status := fnd_api.G_RET_STS_ERROR;
2273:
2274: fnd_msg_pub.Count_And_Get (
2275: p_encoded => fnd_api.G_FALSE,
2276: p_count => x_msg_count,

Line 2275: p_encoded => fnd_api.G_FALSE,

2271: WHEN fnd_api.G_EXC_ERROR THEN
2272: x_return_status := fnd_api.G_RET_STS_ERROR;
2273:
2274: fnd_msg_pub.Count_And_Get (
2275: p_encoded => fnd_api.G_FALSE,
2276: p_count => x_msg_count,
2277: p_data => x_msg_data
2278: );
2279:

Line 2298: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN

2294: p_msg_level => fnd_log.level_procedure
2295: );
2296: END IF;
2297:
2298: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2299: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2300: fnd_msg_pub.Count_And_Get (
2301: p_encoded => fnd_api.G_FALSE,
2302: p_count => x_msg_count,

Line 2299: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

2295: );
2296: END IF;
2297:
2298: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2299: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2300: fnd_msg_pub.Count_And_Get (
2301: p_encoded => fnd_api.G_FALSE,
2302: p_count => x_msg_count,
2303: p_data => x_msg_data

Line 2301: p_encoded => fnd_api.G_FALSE,

2297:
2298: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2299: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2300: fnd_msg_pub.Count_And_Get (
2301: p_encoded => fnd_api.G_FALSE,
2302: p_count => x_msg_count,
2303: p_data => x_msg_data
2304: );
2305:

Line 2325: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

2321: );
2322: END IF;
2323:
2324: WHEN OTHERS THEN
2325: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2326:
2327: fnd_message.set_name('AR', 'HZ_API_OTHERS_EXCEP');
2328: fnd_message.set_token('ERROR' ,SQLERRM);
2329: fnd_msg_pub.add;

Line 2332: p_encoded => fnd_api.G_FALSE,

2328: fnd_message.set_token('ERROR' ,SQLERRM);
2329: fnd_msg_pub.add;
2330:
2331: fnd_msg_pub.Count_And_Get (
2332: p_encoded => fnd_api.G_FALSE,
2333: p_count => x_msg_count,
2334: p_data => x_msg_data
2335: );
2336:

Line 2369: * fnd_api.G_TRUE. Default is fnd_api.G_FALSE.

2365: *
2366: * ARGUMENTS
2367: * IN:
2368: * p_init_msg_list Initialize message stack if it is set to
2369: * fnd_api.G_TRUE. Default is fnd_api.G_FALSE.
2370: * p_validation_level Validation level. Default is full validation.
2371: * p_party_usg_assignment_id Party usage assignment Id.
2372: * p_party_usg_assignment_rec Party usage assignment record.
2373: * IN/OUT:

Line 2376: * be fnd_api.G_RET_STS_SUCCESS (success),

2372: * p_party_usg_assignment_rec Party usage assignment record.
2373: * IN/OUT:
2374: * OUT:
2375: * x_return_status Return status after the call. The status can
2376: * be fnd_api.G_RET_STS_SUCCESS (success),
2377: * fnd_api.G_RET_STS_ERROR (error),
2378: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
2379: * x_msg_count Number of messages in message stack.
2380: * x_msg_data Message text if x_msg_count is 1.

Line 2377: * fnd_api.G_RET_STS_ERROR (error),

2373: * IN/OUT:
2374: * OUT:
2375: * x_return_status Return status after the call. The status can
2376: * be fnd_api.G_RET_STS_SUCCESS (success),
2377: * fnd_api.G_RET_STS_ERROR (error),
2378: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
2379: * x_msg_count Number of messages in message stack.
2380: * x_msg_data Message text if x_msg_count is 1.
2381: *

Line 2378: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).

2374: * OUT:
2375: * x_return_status Return status after the call. The status can
2376: * be fnd_api.G_RET_STS_SUCCESS (success),
2377: * fnd_api.G_RET_STS_ERROR (error),
2378: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
2379: * x_msg_count Number of messages in message stack.
2380: * x_msg_data Message text if x_msg_count is 1.
2381: *
2382: * NOTES

Line 2425: fnd_api.to_Boolean(p_init_msg_list)

2421: END IF;
2422:
2423: -- initialize message list if p_init_msg_list is set to TRUE.
2424: IF p_init_msg_list IS NOT NULL AND
2425: fnd_api.to_Boolean(p_init_msg_list)
2426: THEN
2427: fnd_msg_pub.initialize;
2428: END IF;
2429:

Line 2438: x_return_status := fnd_api.G_RET_STS_SUCCESS;

2434: l_validation_level := p_validation_level;
2435: END IF;
2436:
2437: -- initialize API return status to success.
2438: x_return_status := fnd_api.G_RET_STS_SUCCESS;
2439:
2440: -- get old assignment.
2441: get_usg_assignment(
2442: p_party_usg_assignment_id => p_party_usg_assignment_id,

Line 2451: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN

2447: x_msg_count => x_msg_count,
2448: x_msg_data => x_msg_data
2449: );
2450:
2451: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
2452: RAISE fnd_api.G_EXC_ERROR;
2453: END IF;
2454:
2455: -- call to business logic.

Line 2452: RAISE fnd_api.G_EXC_ERROR;

2448: x_msg_data => x_msg_data
2449: );
2450:
2451: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
2452: RAISE fnd_api.G_EXC_ERROR;
2453: END IF;
2454:
2455: -- call to business logic.
2456: l_party_usg_assignment_rec := p_party_usg_assignment_rec;

Line 2468: p_encoded => fnd_api.G_FALSE,

2464: );
2465:
2466: -- standard call to get message count and if count is 1, get message info.
2467: fnd_msg_pub.Count_And_Get (
2468: p_encoded => fnd_api.G_FALSE,
2469: p_count => x_msg_count,
2470: p_data => x_msg_data);
2471:
2472: -- Debug info.

Line 2491: WHEN fnd_api.G_EXC_ERROR THEN

2487: );
2488: END IF;
2489:
2490: EXCEPTION
2491: WHEN fnd_api.G_EXC_ERROR THEN
2492: ROLLBACK TO update_usg_assignment;
2493: x_return_status := fnd_api.G_RET_STS_ERROR;
2494:
2495: fnd_msg_pub.Count_And_Get (

Line 2493: x_return_status := fnd_api.G_RET_STS_ERROR;

2489:
2490: EXCEPTION
2491: WHEN fnd_api.G_EXC_ERROR THEN
2492: ROLLBACK TO update_usg_assignment;
2493: x_return_status := fnd_api.G_RET_STS_ERROR;
2494:
2495: fnd_msg_pub.Count_And_Get (
2496: p_encoded => fnd_api.G_FALSE,
2497: p_count => x_msg_count,

Line 2496: p_encoded => fnd_api.G_FALSE,

2492: ROLLBACK TO update_usg_assignment;
2493: x_return_status := fnd_api.G_RET_STS_ERROR;
2494:
2495: fnd_msg_pub.Count_And_Get (
2496: p_encoded => fnd_api.G_FALSE,
2497: p_count => x_msg_count,
2498: p_data => x_msg_data
2499: );
2500:

Line 2519: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN

2515: p_msg_level => fnd_log.level_procedure
2516: );
2517: END IF;
2518:
2519: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2520: ROLLBACK TO update_usg_assignment;
2521: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2522: fnd_msg_pub.Count_And_Get (
2523: p_encoded => fnd_api.G_FALSE,

Line 2521: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

2517: END IF;
2518:
2519: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2520: ROLLBACK TO update_usg_assignment;
2521: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2522: fnd_msg_pub.Count_And_Get (
2523: p_encoded => fnd_api.G_FALSE,
2524: p_count => x_msg_count,
2525: p_data => x_msg_data

Line 2523: p_encoded => fnd_api.G_FALSE,

2519: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2520: ROLLBACK TO update_usg_assignment;
2521: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2522: fnd_msg_pub.Count_And_Get (
2523: p_encoded => fnd_api.G_FALSE,
2524: p_count => x_msg_count,
2525: p_data => x_msg_data
2526: );
2527:

Line 2548: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

2544: END IF;
2545:
2546: WHEN OTHERS THEN
2547: ROLLBACK TO update_usg_assignment;
2548: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2549:
2550: fnd_message.set_name('AR', 'HZ_API_OTHERS_EXCEP');
2551: fnd_message.set_token('ERROR' ,SQLERRM);
2552: fnd_msg_pub.add;

Line 2555: p_encoded => fnd_api.G_FALSE,

2551: fnd_message.set_token('ERROR' ,SQLERRM);
2552: fnd_msg_pub.add;
2553:
2554: fnd_msg_pub.Count_And_Get (
2555: p_encoded => fnd_api.G_FALSE,
2556: p_count => x_msg_count,
2557: p_data => x_msg_data
2558: );
2559:

Line 2592: * fnd_api.G_TRUE. Default is fnd_api.G_FALSE.

2588: *
2589: * ARGUMENTS
2590: * IN:
2591: * p_init_msg_list Initialize message stack if it is set to
2592: * fnd_api.G_TRUE. Default is fnd_api.G_FALSE.
2593: * p_validation_level Validation level. Default is full validation.
2594: * p_party_id Party Id
2595: * p_party_usage_code Party usage code
2596: * IN/OUT:

Line 2599: * be fnd_api.G_RET_STS_SUCCESS (success),

2595: * p_party_usage_code Party usage code
2596: * IN/OUT:
2597: * OUT:
2598: * x_return_status Return status after the call. The status can
2599: * be fnd_api.G_RET_STS_SUCCESS (success),
2600: * fnd_api.G_RET_STS_ERROR (error),
2601: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
2602: * x_msg_count Number of messages in message stack.
2603: * x_msg_data Message text if x_msg_count is 1.

Line 2600: * fnd_api.G_RET_STS_ERROR (error),

2596: * IN/OUT:
2597: * OUT:
2598: * x_return_status Return status after the call. The status can
2599: * be fnd_api.G_RET_STS_SUCCESS (success),
2600: * fnd_api.G_RET_STS_ERROR (error),
2601: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
2602: * x_msg_count Number of messages in message stack.
2603: * x_msg_data Message text if x_msg_count is 1.
2604: *

Line 2601: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).

2597: * OUT:
2598: * x_return_status Return status after the call. The status can
2599: * be fnd_api.G_RET_STS_SUCCESS (success),
2600: * fnd_api.G_RET_STS_ERROR (error),
2601: * fnd_api.G_RET_STS_UNEXP_ERROR (unexpected error).
2602: * x_msg_count Number of messages in message stack.
2603: * x_msg_data Message text if x_msg_count is 1.
2604: *
2605: * NOTES

Line 2657: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN

2653: x_msg_data => x_msg_data
2654: );
2655:
2656: -- replace error message
2657: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
2658: fnd_message.set_name('AR', 'HZ_PU_WRONG_API');
2659: fnd_msg_pub.Set_Search_Name('AR', 'HZ_PU_MULTIPLE_ASSIGNMENT');
2660: l_success := fnd_msg_pub.Change_Msg;
2661:

Line 2665: p_encoded => fnd_api.G_FALSE,

2661:
2662: IF l_success = 'T' THEN
2663: -- standard call to get message count and if count is 1, get message info.
2664: fnd_msg_pub.Count_And_Get (
2665: p_encoded => fnd_api.G_FALSE,
2666: p_count => x_msg_count,
2667: p_data => x_msg_data);
2668: END IF;
2669: END IF;

Line 2794: fnd_api.to_Boolean(p_init_msg_list)

2790: END IF;
2791:
2792: -- initialize message list if p_init_msg_list is set to TRUE.
2793: IF p_init_msg_list IS NOT NULL AND
2794: fnd_api.to_Boolean(p_init_msg_list)
2795: THEN
2796: fnd_msg_pub.initialize;
2797: END IF;
2798:

Line 2883: p_encoded => fnd_api.G_FALSE,

2879: END IF; -- has rules defined.
2880:
2881: -- standard call to get message count and if count is 1, get message info.
2882: fnd_msg_pub.Count_And_Get (
2883: p_encoded => fnd_api.G_FALSE,
2884: p_count => x_msg_count,
2885: p_data => x_msg_data);
2886:
2887: -- Debug info.

Line 3037: x_return_status := fnd_api.g_ret_sts_error;

3033: FETCH c_party INTO l_dummy;
3034: IF c_party%FOUND THEN
3035: fnd_message.set_name('AR', 'HZ_NONUNIQUE_SUPPLIER_NAME');
3036: fnd_msg_pub.add;
3037: x_return_status := fnd_api.g_ret_sts_error;
3038: END IF;
3039: CLOSE c_party;
3040:
3041: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN