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 725: x_return_status := fnd_api.G_RET_STS_ERROR;

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

Line 763: x_return_status := fnd_api.G_RET_STS_ERROR;

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

Line 831: x_return_status := fnd_api.G_RET_STS_ERROR;

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

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

936: --
937: -- check owner_table_name, owner_table_id
938: --
939: IF p_party_usg_assignment_rec.owner_table_name IS NOT NULL AND
940: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR AND
941: p_party_usg_assignment_rec.owner_table_id IS NOT NULL AND
942: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM
943: THEN
944: -- Debug info.

Line 942: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM

938: --
939: IF p_party_usg_assignment_rec.owner_table_name IS NOT NULL AND
940: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR AND
941: p_party_usg_assignment_rec.owner_table_id IS NOT NULL AND
942: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM
943: THEN
944: -- Debug info.
945: IF fnd_log.level_statement >= fnd_log.g_current_runtime_level THEN
946: hz_utility_v2pub.debug(

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

966: --
967: -- check party_id, party_usage_code, effective_start_date, effective_end_date
968: --
969: ELSIF p_party_usg_assignment_rec.party_id IS NOT NULL AND
970: p_party_usg_assignment_rec.party_id <> fnd_api.G_MISS_NUM AND
971: p_party_usg_assignment_rec.party_usage_code IS NOT NULL AND
972: p_party_usg_assignment_rec.party_usage_code <> fnd_api.G_MISS_CHAR
973: THEN
974: -- Debug info.

Line 972: p_party_usg_assignment_rec.party_usage_code <> fnd_api.G_MISS_CHAR

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

Line 1086: p_party_usg_assignment_rec.effective_start_date = fnd_api.G_MISS_DATE

1082: END IF;
1083:
1084: -- check dates.
1085: IF p_party_usg_assignment_rec.effective_start_date IS NULL OR
1086: p_party_usg_assignment_rec.effective_start_date = fnd_api.G_MISS_DATE
1087: THEN
1088: p_party_usg_assignment_rec.effective_start_date := trunc(sysdate);
1089: ELSE
1090: p_party_usg_assignment_rec.effective_start_date :=

Line 1095: p_party_usg_assignment_rec.effective_end_date = fnd_api.G_MISS_DATE

1091: trunc(p_party_usg_assignment_rec.effective_start_date);
1092: END IF;
1093:
1094: IF p_party_usg_assignment_rec.effective_end_date IS NULL OR
1095: p_party_usg_assignment_rec.effective_end_date = fnd_api.G_MISS_DATE
1096: THEN
1097: p_party_usg_assignment_rec.effective_end_date := D_FUTURE_DATE;
1098: ELSE
1099: p_party_usg_assignment_rec.effective_end_date :=

Line 1126: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN

1122: p_old_usg_assignment_rec => l_party_usg_assignment_rec,
1123: x_return_status => x_return_status
1124: );
1125:
1126: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
1127: RAISE fnd_api.G_EXC_ERROR;
1128: END IF;
1129: END IF;
1130:

Line 1127: RAISE fnd_api.G_EXC_ERROR;

1123: x_return_status => x_return_status
1124: );
1125:
1126: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
1127: RAISE fnd_api.G_EXC_ERROR;
1128: END IF;
1129: END IF;
1130:
1131: --

Line 1290: p_party_usg_assignment_rec.effective_start_date = fnd_api.G_MISS_DATE

1286: l_object_version_number1 := null;
1287:
1288: -- check dates.
1289: IF p_party_usg_assignment_rec.effective_start_date IS NULL OR
1290: p_party_usg_assignment_rec.effective_start_date = fnd_api.G_MISS_DATE
1291: THEN
1292: p_party_usg_assignment_rec.effective_start_date :=
1293: p_old_usg_assignment_rec_tbl(i).effective_start_date;
1294: ELSE

Line 1300: p_party_usg_assignment_rec.effective_end_date <> fnd_api.G_MISS_DATE

1296: trunc(p_party_usg_assignment_rec.effective_start_date);
1297: END IF;
1298:
1299: IF p_party_usg_assignment_rec.effective_end_date IS NOT NULL AND
1300: p_party_usg_assignment_rec.effective_end_date <> fnd_api.G_MISS_DATE
1301: THEN
1302: p_party_usg_assignment_rec.effective_end_date :=
1303: trunc(p_party_usg_assignment_rec.effective_end_date);
1304: ELSIF p_party_usg_assignment_rec.effective_end_date IS NULL THEN

Line 1334: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN

1330: p_old_usg_assignment_rec => p_old_usg_assignment_rec_tbl(i),
1331: x_return_status => x_return_status
1332: );
1333:
1334: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
1335: RAISE fnd_api.G_EXC_ERROR;
1336: END IF;
1337: END IF;
1338:

Line 1335: RAISE fnd_api.G_EXC_ERROR;

1331: x_return_status => x_return_status
1332: );
1333:
1334: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
1335: RAISE fnd_api.G_EXC_ERROR;
1336: END IF;
1337: END IF;
1338:
1339: --

Line 1740: RAISE fnd_api.g_exc_error;

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

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

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

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

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

Line 1872: * fnd_api.G_RET_STS_ERROR (error),

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

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

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

Line 1917: fnd_api.To_Boolean(p_init_msg_list)

1913: END IF;
1914:
1915: -- initialize message list if p_init_msg_list is set to TRUE.
1916: IF p_init_msg_list IS NOT NULL AND
1917: fnd_api.To_Boolean(p_init_msg_list)
1918: THEN
1919: fnd_msg_pub.initialize;
1920: END IF;
1921:

Line 1930: x_return_status := fnd_api.G_RET_STS_SUCCESS;

1926: l_validation_level := p_validation_level;
1927: END IF;
1928:
1929: -- initialize API return status to success.
1930: x_return_status := fnd_api.G_RET_STS_SUCCESS;
1931:
1932: -- call to business logic.
1933: l_party_usg_assignment_rec := p_party_usg_assignment_rec;
1934:

Line 1943: p_encoded => fnd_api.G_FALSE,

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

Line 1966: WHEN fnd_api.G_EXC_ERROR THEN

1962: );
1963: END IF;
1964:
1965: EXCEPTION
1966: WHEN fnd_api.G_EXC_ERROR THEN
1967: ROLLBACK TO assign_party_usage;
1968: x_return_status := fnd_api.G_RET_STS_ERROR;
1969:
1970: fnd_msg_pub.Count_And_Get (

Line 1968: x_return_status := fnd_api.G_RET_STS_ERROR;

1964:
1965: EXCEPTION
1966: WHEN fnd_api.G_EXC_ERROR THEN
1967: ROLLBACK TO assign_party_usage;
1968: x_return_status := fnd_api.G_RET_STS_ERROR;
1969:
1970: fnd_msg_pub.Count_And_Get (
1971: p_encoded => fnd_api.G_FALSE,
1972: p_count => x_msg_count,

Line 1971: p_encoded => fnd_api.G_FALSE,

1967: ROLLBACK TO assign_party_usage;
1968: x_return_status := fnd_api.G_RET_STS_ERROR;
1969:
1970: fnd_msg_pub.Count_And_Get (
1971: p_encoded => fnd_api.G_FALSE,
1972: p_count => x_msg_count,
1973: p_data => x_msg_data
1974: );
1975:

Line 1994: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN

1990: p_msg_level => fnd_log.level_procedure
1991: );
1992: END IF;
1993:
1994: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
1995: ROLLBACK TO assign_party_usage;
1996: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
1997: fnd_msg_pub.Count_And_Get (
1998: p_encoded => fnd_api.G_FALSE,

Line 1996: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

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

Line 1998: p_encoded => fnd_api.G_FALSE,

1994: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
1995: ROLLBACK TO assign_party_usage;
1996: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
1997: fnd_msg_pub.Count_And_Get (
1998: p_encoded => fnd_api.G_FALSE,
1999: p_count => x_msg_count,
2000: p_data => x_msg_data
2001: );
2002:

Line 2023: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

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

Line 2030: p_encoded => fnd_api.G_FALSE,

2026: fnd_message.set_token('ERROR' ,SQLERRM);
2027: fnd_msg_pub.add;
2028:
2029: fnd_msg_pub.Count_And_Get (
2030: p_encoded => fnd_api.G_FALSE,
2031: p_count => x_msg_count,
2032: p_data => x_msg_data
2033: );
2034:

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

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

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

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

Line 2076: * fnd_api.G_RET_STS_ERROR (error),

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

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

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

Line 2124: fnd_api.to_Boolean(p_init_msg_list)

2120: END IF;
2121:
2122: -- initialize message list if p_init_msg_list is set to TRUE.
2123: IF p_init_msg_list IS NOT NULL AND
2124: fnd_api.to_Boolean(p_init_msg_list)
2125: THEN
2126: fnd_msg_pub.initialize;
2127: END IF;
2128:

Line 2130: x_return_status := fnd_api.G_RET_STS_SUCCESS;

2126: fnd_msg_pub.initialize;
2127: END IF;
2128:
2129: -- initialize API return status to success.
2130: x_return_status := fnd_api.G_RET_STS_SUCCESS;
2131:
2132: x_usg_assignment_id_tbl := NUMBER15_TBL();
2133: x_usg_assignment_rec_tbl := ASSIGNMENT_REC_TBL();
2134:

Line 2138: p_party_usg_assignment_id <> fnd_api.G_MISS_NUM

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

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

2145: --
2146: -- check party_id, party_usage_code
2147: --
2148: ELSIF p_party_usg_assignment_rec.party_usage_code IS NOT NULL AND
2149: p_party_usg_assignment_rec.party_usage_code <> fnd_api.G_MISS_CHAR AND
2150: p_party_usg_assignment_rec.party_id IS NOT NULL AND
2151: p_party_usg_assignment_rec.party_id <> fnd_api.G_MISS_NUM
2152: THEN
2153: l_search_by := 'USAGE_CODE';

Line 2151: p_party_usg_assignment_rec.party_id <> fnd_api.G_MISS_NUM

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

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

2161: --
2162: -- check owner_table_name, owner_table_id
2163: --
2164: ELSIF p_party_usg_assignment_rec.owner_table_name IS NOT NULL AND
2165: p_party_usg_assignment_rec.owner_table_name <> fnd_api.G_MISS_CHAR AND
2166: p_party_usg_assignment_rec.owner_table_id IS NOT NULL AND
2167: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM
2168: THEN
2169: l_search_by := 'OWNER_TABLE_NAME';

Line 2167: p_party_usg_assignment_rec.owner_table_id <> fnd_api.G_MISS_NUM

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

Line 2180: RAISE fnd_api.G_EXC_ERROR;

2176: --
2177: ELSE
2178: fnd_message.set_name('AR', 'HZ_PU_MISSING_COLUMN');
2179: fnd_msg_pub.add;
2180: RAISE fnd_api.G_EXC_ERROR;
2181: END IF;
2182:
2183: l_counter := 0;
2184: LOOP

Line 2240: RAISE fnd_api.G_EXC_ERROR;

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

Line 2247: RAISE fnd_api.G_EXC_ERROR;

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

Line 2252: p_encoded => fnd_api.G_FALSE,

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

Line 2275: WHEN fnd_api.G_EXC_ERROR THEN

2271: );
2272: END IF;
2273:
2274: EXCEPTION
2275: WHEN fnd_api.G_EXC_ERROR THEN
2276: x_return_status := fnd_api.G_RET_STS_ERROR;
2277:
2278: fnd_msg_pub.Count_And_Get (
2279: p_encoded => fnd_api.G_FALSE,

Line 2276: x_return_status := fnd_api.G_RET_STS_ERROR;

2272: END IF;
2273:
2274: EXCEPTION
2275: WHEN fnd_api.G_EXC_ERROR THEN
2276: x_return_status := fnd_api.G_RET_STS_ERROR;
2277:
2278: fnd_msg_pub.Count_And_Get (
2279: p_encoded => fnd_api.G_FALSE,
2280: p_count => x_msg_count,

Line 2279: p_encoded => fnd_api.G_FALSE,

2275: WHEN fnd_api.G_EXC_ERROR THEN
2276: x_return_status := fnd_api.G_RET_STS_ERROR;
2277:
2278: fnd_msg_pub.Count_And_Get (
2279: p_encoded => fnd_api.G_FALSE,
2280: p_count => x_msg_count,
2281: p_data => x_msg_data
2282: );
2283:

Line 2302: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN

2298: p_msg_level => fnd_log.level_procedure
2299: );
2300: END IF;
2301:
2302: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2303: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2304: fnd_msg_pub.Count_And_Get (
2305: p_encoded => fnd_api.G_FALSE,
2306: p_count => x_msg_count,

Line 2303: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

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

Line 2305: p_encoded => fnd_api.G_FALSE,

2301:
2302: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2303: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2304: fnd_msg_pub.Count_And_Get (
2305: p_encoded => fnd_api.G_FALSE,
2306: p_count => x_msg_count,
2307: p_data => x_msg_data
2308: );
2309:

Line 2329: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

2325: );
2326: END IF;
2327:
2328: WHEN OTHERS THEN
2329: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2330:
2331: fnd_message.set_name('AR', 'HZ_API_OTHERS_EXCEP');
2332: fnd_message.set_token('ERROR' ,SQLERRM);
2333: fnd_msg_pub.add;

Line 2336: p_encoded => fnd_api.G_FALSE,

2332: fnd_message.set_token('ERROR' ,SQLERRM);
2333: fnd_msg_pub.add;
2334:
2335: fnd_msg_pub.Count_And_Get (
2336: p_encoded => fnd_api.G_FALSE,
2337: p_count => x_msg_count,
2338: p_data => x_msg_data
2339: );
2340:

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

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

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

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

Line 2381: * fnd_api.G_RET_STS_ERROR (error),

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

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

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

Line 2429: fnd_api.to_Boolean(p_init_msg_list)

2425: END IF;
2426:
2427: -- initialize message list if p_init_msg_list is set to TRUE.
2428: IF p_init_msg_list IS NOT NULL AND
2429: fnd_api.to_Boolean(p_init_msg_list)
2430: THEN
2431: fnd_msg_pub.initialize;
2432: END IF;
2433:

Line 2442: x_return_status := fnd_api.G_RET_STS_SUCCESS;

2438: l_validation_level := p_validation_level;
2439: END IF;
2440:
2441: -- initialize API return status to success.
2442: x_return_status := fnd_api.G_RET_STS_SUCCESS;
2443:
2444: -- get old assignment.
2445: get_usg_assignment(
2446: p_party_usg_assignment_id => p_party_usg_assignment_id,

Line 2455: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN

2451: x_msg_count => x_msg_count,
2452: x_msg_data => x_msg_data
2453: );
2454:
2455: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
2456: RAISE fnd_api.G_EXC_ERROR;
2457: END IF;
2458:
2459: -- call to business logic.

Line 2456: RAISE fnd_api.G_EXC_ERROR;

2452: x_msg_data => x_msg_data
2453: );
2454:
2455: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN
2456: RAISE fnd_api.G_EXC_ERROR;
2457: END IF;
2458:
2459: -- call to business logic.
2460: l_party_usg_assignment_rec := p_party_usg_assignment_rec;

Line 2472: p_encoded => fnd_api.G_FALSE,

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

Line 2495: WHEN fnd_api.G_EXC_ERROR THEN

2491: );
2492: END IF;
2493:
2494: EXCEPTION
2495: WHEN fnd_api.G_EXC_ERROR THEN
2496: ROLLBACK TO update_usg_assignment;
2497: x_return_status := fnd_api.G_RET_STS_ERROR;
2498:
2499: fnd_msg_pub.Count_And_Get (

Line 2497: x_return_status := fnd_api.G_RET_STS_ERROR;

2493:
2494: EXCEPTION
2495: WHEN fnd_api.G_EXC_ERROR THEN
2496: ROLLBACK TO update_usg_assignment;
2497: x_return_status := fnd_api.G_RET_STS_ERROR;
2498:
2499: fnd_msg_pub.Count_And_Get (
2500: p_encoded => fnd_api.G_FALSE,
2501: p_count => x_msg_count,

Line 2500: p_encoded => fnd_api.G_FALSE,

2496: ROLLBACK TO update_usg_assignment;
2497: x_return_status := fnd_api.G_RET_STS_ERROR;
2498:
2499: fnd_msg_pub.Count_And_Get (
2500: p_encoded => fnd_api.G_FALSE,
2501: p_count => x_msg_count,
2502: p_data => x_msg_data
2503: );
2504:

Line 2523: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN

2519: p_msg_level => fnd_log.level_procedure
2520: );
2521: END IF;
2522:
2523: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2524: ROLLBACK TO update_usg_assignment;
2525: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2526: fnd_msg_pub.Count_And_Get (
2527: p_encoded => fnd_api.G_FALSE,

Line 2525: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

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

Line 2527: p_encoded => fnd_api.G_FALSE,

2523: WHEN fnd_api.G_EXC_UNEXPECTED_ERROR THEN
2524: ROLLBACK TO update_usg_assignment;
2525: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;
2526: fnd_msg_pub.Count_And_Get (
2527: p_encoded => fnd_api.G_FALSE,
2528: p_count => x_msg_count,
2529: p_data => x_msg_data
2530: );
2531:

Line 2552: x_return_status := fnd_api.G_RET_STS_UNEXP_ERROR;

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

Line 2559: p_encoded => fnd_api.G_FALSE,

2555: fnd_message.set_token('ERROR' ,SQLERRM);
2556: fnd_msg_pub.add;
2557:
2558: fnd_msg_pub.Count_And_Get (
2559: p_encoded => fnd_api.G_FALSE,
2560: p_count => x_msg_count,
2561: p_data => x_msg_data
2562: );
2563:

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

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

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

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

Line 2604: * fnd_api.G_RET_STS_ERROR (error),

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

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

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

Line 2661: IF x_return_status <> fnd_api.G_RET_STS_SUCCESS THEN

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

Line 2669: p_encoded => fnd_api.G_FALSE,

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

Line 2798: fnd_api.to_Boolean(p_init_msg_list)

2794: END IF;
2795:
2796: -- initialize message list if p_init_msg_list is set to TRUE.
2797: IF p_init_msg_list IS NOT NULL AND
2798: fnd_api.to_Boolean(p_init_msg_list)
2799: THEN
2800: fnd_msg_pub.initialize;
2801: END IF;
2802:

Line 2887: p_encoded => fnd_api.G_FALSE,

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

Line 3041: x_return_status := fnd_api.g_ret_sts_error;

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