DBA Data[Home] [Help]

APPS.PA_HR_UPDATE_API dependencies on FND_API

Line 56: If v_return_status = FND_API.G_RET_STS_SUCCESS then

52: ,x_return_status => v_return_status
53: ,x_error_message_code => v_error_message_code
54: );
55:
56: If v_return_status = FND_API.G_RET_STS_SUCCESS then
57: return 'Y';
58: else
59: return 'N';
60: End if;

Line 96: if P_return_status <> FND_API.G_RET_STS_SUCCESS then

92: ) IS
93:
94: BEGIN
95:
96: if P_return_status <> FND_API.G_RET_STS_SUCCESS then
97: PA_UTILS.add_message(p_app_short_name => 'PA',
98: p_msg_name => P_error_message_code);
99: end if;
100:

Line 310: x_return_status := FND_API.G_RET_STS_SUCCESS;

306: BEGIN
307: -- Initialize the Error stack
308: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.check_exp_OU');
309: -- Initialize the error status
310: x_return_status := FND_API.G_RET_STS_SUCCESS;
311:
312: If p_org_id is NOT NULL then
313:
314: SELECT 'Y'

Line 334: x_return_status := FND_API.G_RET_STS_ERROR;

330: EXCEPTION
331:
332: WHEN NO_DATA_FOUND THEN
333: x_error_message_code := v_error_message_code;
334: x_return_status := FND_API.G_RET_STS_ERROR;
335:
336:
337: WHEN OTHERS THEN
338: -- Set the exception Message and the stack

Line 341: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

337: WHEN OTHERS THEN
338: -- Set the exception Message and the stack
339: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.check_exp_OU'
340: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
341: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
342: -- 4537865 : RESET x_error_message_code also
343: x_error_message_code := SQLCODE ;
344:
345: raise;

Line 376: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

372: v_msg_count NUMBER;
373: BEGIN
374: -- Initialize the Error stack
375: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.call_create_resoruce_denorm');
376: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
377: v_job_id_new := P_job_id_new;
378: v_job_level_new := P_job_level_new;
379: v_job_id_old := P_job_id_old;
380: v_job_level_old := 0;

Line 426: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

422:
423: -- Set the exception Message and the stack
424: FND_MSG_PUB.add_exc_msg( p_pkg_name => 'PA_HR_UPDATE_API.call_create_resource_denorm'
425: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
426: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
427: raise;
428:
429:
430:

Line 458: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

454:
455: BEGIN
456: -- Initialize the Error stack
457: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.update_job_level_res_denorm');
458: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
459:
460: l_job_id_new := P_job_id_new;
461: l_job_level_new := P_job_level_new;
462: l_job_id_old := P_job_id_old;

Line 500: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

496:
497: -- Set the exception Message and the stack
498: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.update_job_level_res_denorm'
499: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
500: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
501: raise;
502:
503: END update_job_level_res_denorm;
504:

Line 553: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

549: BEGIN
550:
551: -- Initialize the Error stack
552: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.update_all_jobs');
553: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
554:
555: l_job_id := P_job_id;
556:
557: -- just assign the value to the local variable because job_level can be

Line 604: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

600:
601: -- Set the exception Message and the stack
602: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.update_all_jobs'
603: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
604: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
605: raise;
606:
607: END update_all_jobs;
608:

Line 635: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

631:
632: BEGIN
633: -- Initialize the Error stack
634: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.pa_job_relation_job_id');
635: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
636:
637: IF P_DEBUG_MODE = 'Y' THEN
638: log_message('P_from_job_id_old = ' || P_from_job_id_old);
639: log_message('P_from_job_id_new = ' || P_from_job_id_new);

Line 911: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

907:
908: -- Set the exception Message and the stack
909: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.pa_job_relation_job_id'
910: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
911: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
912: raise;
913:
914:
915: END pa_job_relation_job_id;

Line 957: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

953: BEGIN
954:
955: -- Initialize the Error stack
956: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.perform_job_updates');
957: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
958: IF P_DEBUG_MODE = 'Y' THEN
959: log_message('**** Performing Job Level Updates ****');
960: END IF;
961:

Line 1031: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

1027: WHEN OTHERS THEN -- Included WHEN OTHERS Block for 4537865
1028: -- 4537865 : RESET x_msg_count and x_msg_data also
1029: x_msg_count := 1 ;
1030: x_msg_data := SUBSTRB(SQLERRM ,1,240);
1031: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1032: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API',
1033: p_procedure_name => 'perform_job_updates',
1034: p_error_text => x_msg_data );
1035: RAISE ;

Line 1063: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

1059: BEGIN
1060:
1061: -- Initialize the Error stack
1062: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.update_job_level_dff');
1063: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
1064:
1065: l_job_id := P_job_id;
1066: l_job_level_old := P_job_level_old;
1067: l_job_level_new := P_job_level_new;

Line 1144: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

1140: WHEN OTHERS THEN -- Included WHEN OTHERS Block for 4537865
1141: -- 4537865 : RESET x_msg_count and x_msg_data also
1142: x_msg_count := 1 ;
1143: x_msg_data := SUBSTRB(SQLERRM ,1,240);
1144: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1145: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API',
1146: p_procedure_name => 'update_job_level_dff',
1147: p_error_text => x_msg_data );
1148: RAISE ;

Line 1210: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

1206: BEGIN
1207:
1208: -- Initialize the Error stack
1209: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.per_valid_grades_job_id');
1210: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
1211:
1212: -- if the grade id changes then update all the jobs which are affected and
1213: -- call PA_RESOURCE_PVT.UPDATE_RESOURCE_DENORM API to update the resource_denorm_table
1214: OPEN get_job_ids(P_job_id) ;

Line 1253: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

1249: x_msg_data := SUBSTRB(SQLERRM ,1,240);
1250: -- Set the exception Message and the stack
1251: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.per_valid_grades_job_id'
1252: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
1253: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1254: raise;
1255:
1256:
1257: END per_valid_grades_job_id;

Line 1323: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

1319:
1320:
1321: -- Initialize the Error stack
1322: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.per_grades_job_id');
1323: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
1324:
1325: -- if the sequence is changes then update all the jobs which are affected due to
1326: -- call PA_RESOURCE_PVT.UPDATE_RESOURCE_DENORM API to update the resource_denorm_table
1327: OPEN get_job_ids(P_grade_id) ;

Line 1364: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

1360: x_msg_data := SUBSTRB(SQLERRM ,1,240);
1361: -- Set the exception Message and the stack
1362: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.per_grades_job_id'
1363: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
1364: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1365: raise;
1366:
1367:
1368:

Line 1412: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

1408:
1409: BEGIN
1410: -- Initialize the Error stack
1411: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Update_job_levels');
1412: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
1413:
1414: -- Code for if job mapping has changed
1415:
1416: If (P_from_job_group_id is NOT NULL and P_to_job_group_id is NOT NULL) and

Line 1449: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

1445:
1446: -- Set the exception Message and the stack
1447: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Update_job_levels'
1448: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
1449: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1450: raise;
1451:
1452: END update_job_levels;
1453:

Line 1502: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

1498: --dbms_output.put_line('End date for OU:' || p_default_OU_new || 'end date:' || P_end_date_new);
1499:
1500: -- Initialize the Error stack
1501: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Update_OU_resource');
1502: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
1503:
1504: FOR rec IN res_denorm_recs LOOP
1505:
1506: v_resource_rec_old.resource_effective_start_date := rec.resource_effective_start_date;

Line 1547: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

1543: x_msg_count := 1 ;
1544: x_msg_data := SUBSTRB(SQLERRM ,1,240);
1545: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Update_OU_resource'
1546: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
1547: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1548: raise;
1549: END Update_OU_resource;
1550:
1551:

Line 1582: v_commit VARCHAR2(200) := FND_API.G_FALSE;

1578: v_assn_start_date Per_all_assignments_f.Effective_Start_Date%type;
1579: v_assn_end_date Per_all_assignments_f.Effective_End_Date%type;
1580: v_Person_id Per_all_assignments_f.person_id%type;
1581: v_Default_OU Hr_Organization_Information.Org_Information1%type;
1582: v_commit VARCHAR2(200) := FND_API.G_FALSE;
1583: -- set to false since the api is being called from trigger
1584: v_validate_only VARCHAR2(200) := FND_API.G_FALSE;
1585: v_internal VARCHAR2(1) := 'Y';
1586: v_individual VARCHAR2(1) := 'Y'; -- to process single resource in loop

Line 1584: v_validate_only VARCHAR2(200) := FND_API.G_FALSE;

1580: v_Person_id Per_all_assignments_f.person_id%type;
1581: v_Default_OU Hr_Organization_Information.Org_Information1%type;
1582: v_commit VARCHAR2(200) := FND_API.G_FALSE;
1583: -- set to false since the api is being called from trigger
1584: v_validate_only VARCHAR2(200) := FND_API.G_FALSE;
1585: v_internal VARCHAR2(1) := 'Y';
1586: v_individual VARCHAR2(1) := 'Y'; -- to process single resource in loop
1587: v_resource_type VARCHAR2(15):= 'EMPLOYEE';
1588: v_org_type VARCHAR2(15):= 'YES'; --'EXPENDITURES';

Line 1619: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

1615: BEGIN
1616:
1617: -- Initialize the Error stack
1618: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Default_OU_Change');
1619: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
1620: -- for each resource found for the default ou changes update
1621: -- pa resource ou entity with new default OU
1622:
1623: -- check whether the new OU is a valid exp OU or not

Line 1654: If v_return_status <> FND_API.G_RET_STS_SUCCESS then

1650: ,x_return_status => v_return_status
1651: ,x_error_message_code => v_error_message_code
1652: );
1653:
1654: If v_return_status <> FND_API.G_RET_STS_SUCCESS then
1655: X_RETURN_STATUS := FND_API.G_RET_STS_ERROR;
1656: x_msg_data := v_error_message_code;
1657: v_process_further := FALSE;
1658: PA_UTILS.add_message(p_app_short_name => 'PA',

Line 1655: X_RETURN_STATUS := FND_API.G_RET_STS_ERROR;

1651: ,x_error_message_code => v_error_message_code
1652: );
1653:
1654: If v_return_status <> FND_API.G_RET_STS_SUCCESS then
1655: X_RETURN_STATUS := FND_API.G_RET_STS_ERROR;
1656: x_msg_data := v_error_message_code;
1657: v_process_further := FALSE;
1658: PA_UTILS.add_message(p_app_short_name => 'PA',
1659: p_msg_name => v_error_message_code);

Line 1662: Elsif v_return_status = FND_API.G_RET_STS_SUCCESS then

1658: PA_UTILS.add_message(p_app_short_name => 'PA',
1659: p_msg_name => v_error_message_code);
1660: x_msg_count := fnd_msg_pub.count_msg;
1661:
1662: Elsif v_return_status = FND_API.G_RET_STS_SUCCESS then
1663:
1664: v_process_further := TRUE;
1665:
1666: End if;

Line 1721: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then

1717: ,x_msg_count => x_msg_count
1718: ,x_msg_data => x_msg_data
1719: ) ;
1720:
1721: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then
1722: COMMIT;
1723: else
1724: ROLLBACK;
1725: end if;

Line 1751: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then

1747:
1748: -- call this procedure to update the forecast data for
1749: -- assigned time ONLY for this resource
1750: -- this is called only if create_resource is a success
1751: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then
1752: PA_FORECASTITEM_PVT.Create_Forecast_Item
1753: ( p_person_id => v_person_id
1754: ,p_start_date => null
1755: ,p_end_date => null

Line 1762: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then

1758: ,x_msg_count => x_msg_count
1759: ,x_msg_data => x_msg_data
1760: ) ;
1761:
1762: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then
1763: COMMIT;
1764: else
1765: ROLLBACK;
1766: end if;

Line 1774: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN

1770:
1771: End if;
1772:
1773: /* cannot raise - because will be out from the loop and will not process other records
1774: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
1775: RAISE FND_API.G_EXC_ERROR;
1776: END IF;
1777: */
1778:

Line 1775: RAISE FND_API.G_EXC_ERROR;

1771: End if;
1772:
1773: /* cannot raise - because will be out from the loop and will not process other records
1774: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
1775: RAISE FND_API.G_EXC_ERROR;
1776: END IF;
1777: */
1778:
1779: Elsif P_calling_mode = 'INSERT' then

Line 1810: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then

1806: -- the assigned time for this person when he/she was with Org1
1807: -- So, call this procedure to update the forecast data for
1808: -- assigned time ONLY for this resource
1809: -- this is called only if create_resource is a success
1810: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then
1811: PA_FORECASTITEM_PVT.Create_Forecast_Item
1812: ( p_person_id => v_person_id
1813: ,p_start_date => null
1814: ,p_end_date => null

Line 1821: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then

1817: ,x_msg_count => x_msg_count
1818: ,x_msg_data => x_msg_data
1819: ) ;
1820:
1821: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then
1822: COMMIT;
1823: else
1824: ROLLBACK;
1825: end if;

Line 1832: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN

1828: end if;
1829:
1830:
1831: /* cannot raise - because will be out from the loop and will not process other records
1832: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
1833: RAISE FND_API.G_EXC_ERROR;
1834: END IF;
1835: */
1836:

Line 1833: RAISE FND_API.G_EXC_ERROR;

1829:
1830:
1831: /* cannot raise - because will be out from the loop and will not process other records
1832: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
1833: RAISE FND_API.G_EXC_ERROR;
1834: END IF;
1835: */
1836:
1837: End if;

Line 1842: x_return_status := FND_API.G_RET_STS_SUCCESS;

1838: END LOOP;
1839: close get_all_resource;
1840:
1841: --set the final return status to SUCCESS after loop
1842: x_return_status := FND_API.G_RET_STS_SUCCESS;
1843:
1844: End if;
1845:
1846: -- reset the Error stack

Line 1850: WHEN FND_API.G_EXC_ERROR THEN

1846: -- reset the Error stack
1847: PA_DEBUG.Reset_Err_Stack;
1848:
1849: EXCEPTION
1850: WHEN FND_API.G_EXC_ERROR THEN
1851: x_return_status := FND_API.G_RET_STS_ERROR;
1852: WHEN OTHERS THEN
1853: -- 4537865 : RESET x_msg_count and x_msg_data also
1854: x_msg_count := 1 ;

Line 1851: x_return_status := FND_API.G_RET_STS_ERROR;

1847: PA_DEBUG.Reset_Err_Stack;
1848:
1849: EXCEPTION
1850: WHEN FND_API.G_EXC_ERROR THEN
1851: x_return_status := FND_API.G_RET_STS_ERROR;
1852: WHEN OTHERS THEN
1853: -- 4537865 : RESET x_msg_count and x_msg_data also
1854: x_msg_count := 1 ;
1855: x_msg_data := SUBSTRB(SQLERRM ,1,240);

Line 1859: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

1855: x_msg_data := SUBSTRB(SQLERRM ,1,240);
1856: -- Set the exception Message and the stack
1857: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Default_OU_Change'
1858: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
1859: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
1860: raise;
1861:
1862: END Default_OU_Change;
1863:

Line 1902: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

1898: BEGIN
1899:
1900: -- Initialize the Error stack
1901: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Proj_Res_Job_Group_Change');
1902: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
1903:
1904: l_proj_job_group_old := TO_NUMBER(p_proj_job_group_old);
1905: l_proj_job_group_new := TO_NUMBER(p_proj_job_group_new);
1906:

Line 2033: WHEN FND_API.G_EXC_ERROR THEN

2029: -- reset the Error stack
2030: PA_DEBUG.Reset_Err_Stack;
2031:
2032: EXCEPTION
2033: WHEN FND_API.G_EXC_ERROR THEN
2034: x_return_status := FND_API.G_RET_STS_ERROR;
2035: WHEN OTHERS THEN
2036: -- 4537865 : RESET x_msg_count and x_msg_data also
2037: x_msg_count := 1 ;

Line 2034: x_return_status := FND_API.G_RET_STS_ERROR;

2030: PA_DEBUG.Reset_Err_Stack;
2031:
2032: EXCEPTION
2033: WHEN FND_API.G_EXC_ERROR THEN
2034: x_return_status := FND_API.G_RET_STS_ERROR;
2035: WHEN OTHERS THEN
2036: -- 4537865 : RESET x_msg_count and x_msg_data also
2037: x_msg_count := 1 ;
2038: x_msg_data := SUBSTRB(SQLERRM ,1,240);

Line 2042: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

2038: x_msg_data := SUBSTRB(SQLERRM ,1,240);
2039: -- Set the exception Message and the stack
2040: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Proj_Res_Job_Group_Change'
2041: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
2042: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
2043: raise;
2044:
2045: END Proj_Res_Job_Group_Change;
2046:

Line 2057: l_commit VARCHAR2(200) := FND_API.G_FALSE;

2053: ,x_msg_data OUT NOCOPY VARCHAR2 --File.Sql.39 bug 4440895
2054: ,x_msg_count OUT NOCOPY NUMBER ) --File.Sql.39 bug 4440895
2055: IS
2056: PRAGMA AUTONOMOUS_TRANSACTION;
2057: l_commit VARCHAR2(200) := FND_API.G_FALSE;
2058: -- set to false since the api is being called from trigger
2059: l_validate_only VARCHAR2(200) := FND_API.G_FALSE;
2060: l_internal VARCHAR2(1) := 'Y';
2061: l_individual VARCHAR2(1) := 'Y'; -- to process single resource in loop

Line 2059: l_validate_only VARCHAR2(200) := FND_API.G_FALSE;

2055: IS
2056: PRAGMA AUTONOMOUS_TRANSACTION;
2057: l_commit VARCHAR2(200) := FND_API.G_FALSE;
2058: -- set to false since the api is being called from trigger
2059: l_validate_only VARCHAR2(200) := FND_API.G_FALSE;
2060: l_internal VARCHAR2(1) := 'Y';
2061: l_individual VARCHAR2(1) := 'Y'; -- to process single resource in loop
2062: l_resource_type VARCHAR2(15):= 'EMPLOYEE';
2063: l_Person_id Per_all_assignments_f.person_id%type;

Line 2085: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

2081:
2082: BEGIN
2083: -- Initialize the Error stack
2084: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.pull_resources');
2085: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
2086:
2087: open get_all_resource(p_organization_id);
2088: LOOP
2089: fetch get_all_resource into

Line 2110: if (l_return_status = FND_API.G_RET_STS_SUCCESS) then

2106: -- call this procedure to update the forecast data for
2107: -- assigned time ONLY for this resource
2108: -- pass null to start date and end date
2109: -- this is called only if create_resource is a success
2110: if (l_return_status = FND_API.G_RET_STS_SUCCESS) then
2111: PA_FORECASTITEM_PVT.Create_Forecast_Item(
2112: p_person_id => l_person_id
2113: ,p_start_date => null
2114: ,p_end_date => null

Line 2121: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then

2117: ,x_msg_count => l_msg_count
2118: ,x_msg_data => l_msg_data
2119: ) ;
2120:
2121: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then
2122: COMMIT;
2123: else
2124: ROLLBACK;
2125: end if;

Line 2134: x_return_status := FND_API.G_RET_STS_SUCCESS;

2130: END LOOP;
2131: close get_all_resource;
2132:
2133: --set the final return status to SUCCESS after loop
2134: x_return_status := FND_API.G_RET_STS_SUCCESS;
2135:
2136: -- reset the Error stack
2137: PA_DEBUG.Reset_Err_Stack;
2138:

Line 2148: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

2144: -- Set the exception Message and the stack
2145: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.pull_resources'
2146: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
2147:
2148: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
2149: raise;
2150:
2151: END pull_resources;
2152:

Line 2289: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

2285:
2286: BEGIN
2287: -- Initialize the Error stack
2288: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.make_resource_inactive');
2289: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
2290:
2291: --dbms_output.put_line('Inside make resource inactive');
2292: --dbms_output.put_line('Default OU:' || p_default_ou);
2293: /* bug 5330402

Line 2336: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then

2332: ,x_return_status => x_return_status
2333: ,x_msg_data => x_msg_data
2334: ,x_msg_count => x_msg_count );
2335:
2336: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then
2337: COMMIT;
2338: else
2339: ROLLBACK;
2340: end if;

Line 2352: x_return_status := FND_API.G_RET_STS_SUCCESS;

2348: close get_all_inactive_resource_org;
2349: end if;
2350:
2351: --set the final return status to SUCCESS after loop
2352: x_return_status := FND_API.G_RET_STS_SUCCESS;
2353:
2354: END IF;
2355:
2356: -- reset the Error stack

Line 2366: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

2362: x_msg_data := SUBSTRB(SQLERRM ,1,240);
2363: -- Set the exception Message and the stack
2364: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.make_resource_inactive'
2365: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
2366: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
2367: raise;
2368:
2369:
2370:

Line 2479: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

2475:
2476: BEGIN
2477: -- Initialize the Error stack
2478: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.call_forcast_api');
2479: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
2480:
2481: If (P_table_name = 'PER_JOB_EXTRA_INFO' or
2482: P_table_name = 'PER_VALID_GRADES' or
2483: P_table_name = 'PER_GRADES' or

Line 2507: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then

2503: ,x_msg_count => x_msg_count
2504: ,x_msg_data => x_msg_data
2505: ) ;
2506:
2507: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then
2508: COMMIT;
2509: else
2510: ROLLBACK;
2511: end if;

Line 2514: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN

2510: ROLLBACK;
2511: end if;
2512:
2513: /* cannot raise - because will be out from the loop and will not process other records
2514: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
2515: RAISE FND_API.G_EXC_ERROR;
2516: END IF;
2517: */
2518:

Line 2515: RAISE FND_API.G_EXC_ERROR;

2511: end if;
2512:
2513: /* cannot raise - because will be out from the loop and will not process other records
2514: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
2515: RAISE FND_API.G_EXC_ERROR;
2516: END IF;
2517: */
2518:
2519: END LOOP;

Line 2545: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then

2541: ,x_msg_count => x_msg_count
2542: ,x_msg_data => x_msg_data
2543: ) ;
2544:
2545: if (x_return_status = FND_API.G_RET_STS_SUCCESS) then
2546: COMMIT;
2547: else
2548: ROLLBACK;
2549: end if;

Line 2552: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN

2548: ROLLBACK;
2549: end if;
2550:
2551: /* cannot raise - because will be out from the loop and will not process other records
2552: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
2553: RAISE FND_API.G_EXC_ERROR;
2554: END IF;
2555: */
2556: END LOOP;

Line 2553: RAISE FND_API.G_EXC_ERROR;

2549: end if;
2550:
2551: /* cannot raise - because will be out from the loop and will not process other records
2552: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
2553: RAISE FND_API.G_EXC_ERROR;
2554: END IF;
2555: */
2556: END LOOP;
2557: CLOSE person_orgs;

Line 2562: x_return_status := FND_API.G_RET_STS_SUCCESS;

2558:
2559: End if;
2560:
2561: --set the final return status to SUCCESS after loop
2562: x_return_status := FND_API.G_RET_STS_SUCCESS;
2563:
2564: -- reset the Error stack
2565: PA_DEBUG.Reset_Err_Stack;
2566: EXCEPTION

Line 2567: WHEN FND_API.G_EXC_ERROR THEN

2563:
2564: -- reset the Error stack
2565: PA_DEBUG.Reset_Err_Stack;
2566: EXCEPTION
2567: WHEN FND_API.G_EXC_ERROR THEN
2568: x_return_status := FND_API.G_RET_STS_ERROR;
2569: WHEN OTHERS THEN
2570: -- 4537865 : RESET x_msg_count and x_msg_data also
2571: x_msg_count := 1 ;

Line 2568: x_return_status := FND_API.G_RET_STS_ERROR;

2564: -- reset the Error stack
2565: PA_DEBUG.Reset_Err_Stack;
2566: EXCEPTION
2567: WHEN FND_API.G_EXC_ERROR THEN
2568: x_return_status := FND_API.G_RET_STS_ERROR;
2569: WHEN OTHERS THEN
2570: -- 4537865 : RESET x_msg_count and x_msg_data also
2571: x_msg_count := 1 ;
2572: x_msg_data := SUBSTRB(SQLERRM ,1,240);

Line 2576: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

2572: x_msg_data := SUBSTRB(SQLERRM ,1,240);
2573: -- Set the exception Message and the stack
2574: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.call_forcast_api'
2575: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
2576: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
2577: raise;
2578:
2579:
2580:

Line 2618: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

2614: BEGIN
2615:
2616: -- Initialize the Error stack
2617: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.call_billable_resoruce_denorm');
2618: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
2619: v_job_id_new := P_job_id_new;
2620: v_job_id_old := P_job_id_old;
2621:
2622: If P_billable_flag_new is NOT NULL then

Line 2693: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

2689: x_msg_data := SUBSTRB(SQLERRM ,1,240);
2690: -- Set the exception Message and the stack
2691: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.call_billable_resoruce_denorm'
2692: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
2693: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
2694: raise;
2695:
2696: END call_billable_resoruce_denorm;
2697:

Line 2761: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

2757:
2758: BEGIN
2759: -- Initialize the Error stack
2760: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.per_job_extra_billability');
2761: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
2762:
2763: IF P_DEBUG_MODE = 'Y' THEN
2764: log_message('beginning of per_job_extra_billability, P_calling_mode:'|| P_calling_mode || ', job_id: '||P_job_id);
2765: END IF;

Line 2882: ,p_commit => FND_API.G_FALSE

2878: END IF;
2879:
2880: PA_R_PROJECT_RESOURCES_PUB.CREATE_RESOURCE (
2881: p_api_version => 1.0
2882: ,p_commit => FND_API.G_FALSE
2883: ,p_validate_only => FND_API.G_FALSE
2884: ,p_internal => 'Y'
2885: ,p_person_id => rec.person_id
2886: ,p_individual => 'Y'

Line 2883: ,p_validate_only => FND_API.G_FALSE

2879:
2880: PA_R_PROJECT_RESOURCES_PUB.CREATE_RESOURCE (
2881: p_api_version => 1.0
2882: ,p_commit => FND_API.G_FALSE
2883: ,p_validate_only => FND_API.G_FALSE
2884: ,p_internal => 'Y'
2885: ,p_person_id => rec.person_id
2886: ,p_individual => 'Y'
2887: ,p_resource_type => 'EMPLOYEE'

Line 2896: IF (x_return_status = FND_API.G_RET_STS_SUCCESS) then

2892:
2893: IF P_DEBUG_MODE = 'Y' THEN
2894: log_message('Return status from CREATE_RESOURCE = ' || x_return_status);
2895: END IF;
2896: IF (x_return_status = FND_API.G_RET_STS_SUCCESS) then
2897: COMMIT;
2898: ELSE
2899: ROLLBACK;
2900: END IF;

Line 2907: p_encoded => FND_API.G_FALSE,

2903: -- whenever an expected error is raised from this API
2904: -- will need to continue for the next record
2905: WHEN OTHERS THEN
2906: FND_MSG_PUB.get (
2907: p_encoded => FND_API.G_FALSE,
2908: p_msg_index => 1,
2909: p_data => x_msg_data,
2910: p_msg_index_out => x_msg_count );
2911: IF P_DEBUG_MODE = 'Y' THEN

Line 2945: IF (x_return_status = FND_API.G_RET_STS_SUCCESS) then

2941:
2942: IF P_DEBUG_MODE = 'Y' THEN
2943: log_message('Return status from Update_EndDate = ' || x_return_status);
2944: END IF;
2945: IF (x_return_status = FND_API.G_RET_STS_SUCCESS) then
2946: COMMIT;
2947: ELSE
2948: ROLLBACK;
2949: END IF;

Line 2959: p_encoded => FND_API.G_FALSE,

2955: log_message('error occured');
2956: END IF;
2957: ROLLBACK;
2958: FND_MSG_PUB.get (
2959: p_encoded => FND_API.G_FALSE,
2960: p_msg_index => 1,
2961: p_data => x_msg_data,
2962: p_msg_index_out => x_msg_count );
2963: IF P_DEBUG_MODE = 'Y' THEN

Line 2984: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN

2980: IF P_DEBUG_MODE = 'Y' THEN
2981: log_message('After calling call_forcast_api, x_return_status: '||x_return_status);
2982: END IF;
2983:
2984: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
2985: IF P_DEBUG_MODE = 'Y' THEN
2986: log_message('It will raise exception');
2987: END IF;
2988: RAISE FND_API.G_EXC_ERROR;

Line 2988: RAISE FND_API.G_EXC_ERROR;

2984: IF x_return_status <> FND_API.G_RET_STS_SUCCESS THEN
2985: IF P_DEBUG_MODE = 'Y' THEN
2986: log_message('It will raise exception');
2987: END IF;
2988: RAISE FND_API.G_EXC_ERROR;
2989: ELSIF x_return_status = FND_API.G_RET_STS_SUCCESS THEN
2990: IF P_DEBUG_MODE = 'Y' THEN
2991: log_message('will commit');
2992: END IF;

Line 2989: ELSIF x_return_status = FND_API.G_RET_STS_SUCCESS THEN

2985: IF P_DEBUG_MODE = 'Y' THEN
2986: log_message('It will raise exception');
2987: END IF;
2988: RAISE FND_API.G_EXC_ERROR;
2989: ELSIF x_return_status = FND_API.G_RET_STS_SUCCESS THEN
2990: IF P_DEBUG_MODE = 'Y' THEN
2991: log_message('will commit');
2992: END IF;
2993: COMMIT;

Line 3003: WHEN FND_API.G_EXC_ERROR THEN

2999: log_message('after Reset_Err_Stack');
3000: END IF;
3001:
3002: EXCEPTION
3003: WHEN FND_API.G_EXC_ERROR THEN
3004: ROLLBACK;
3005: x_return_status := FND_API.G_RET_STS_ERROR;
3006: WHEN NO_DATA_FOUND THEN
3007: NULL;

Line 3005: x_return_status := FND_API.G_RET_STS_ERROR;

3001:
3002: EXCEPTION
3003: WHEN FND_API.G_EXC_ERROR THEN
3004: ROLLBACK;
3005: x_return_status := FND_API.G_RET_STS_ERROR;
3006: WHEN NO_DATA_FOUND THEN
3007: NULL;
3008: WHEN OTHERS THEN
3009: IF P_DEBUG_MODE = 'Y' THEN

Line 3018: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

3014: x_msg_data := SUBSTRB(SQLERRM ,1,240);
3015: -- Set the exception Message and the stack
3016: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.per_job_extra_billability'
3017: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
3018: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
3019: RAISE;
3020: END per_job_extra_billability;
3021:
3022:

Line 3067: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

3063: BEGIN
3064:
3065: -- Initialize the Error stack
3066: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.withdraw_cand_nominations');
3067: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
3068:
3069: l_resource_id := PA_RESOURCE_UTILS.get_resource_id(p_person_id);
3070:
3071: IF (l_resource_id <> -999) THEN

Line 3099: p_validate_status => FND_API.G_FALSE,

3095: p_status_code => l_status_code,
3096: p_ranking => null,
3097: p_change_reason_code => null,
3098: p_record_version_number => rec.record_version_number,
3099: p_validate_status => FND_API.G_FALSE,
3100: p_init_msg_list => FND_API.G_FALSE,
3101: x_record_version_number => l_rec_ver_num,
3102: x_return_status => x_return_status,
3103: x_msg_count => x_msg_count,

Line 3100: p_init_msg_list => FND_API.G_FALSE,

3096: p_ranking => null,
3097: p_change_reason_code => null,
3098: p_record_version_number => rec.record_version_number,
3099: p_validate_status => FND_API.G_FALSE,
3100: p_init_msg_list => FND_API.G_FALSE,
3101: x_record_version_number => l_rec_ver_num,
3102: x_return_status => x_return_status,
3103: x_msg_count => x_msg_count,
3104: x_msg_data => x_msg_data);

Line 3113: WHEN FND_API.G_EXC_ERROR THEN

3109:
3110: EXCEPTION
3111: -- whenever an expected error is raised from this API
3112: -- will need to continue for the next record
3113: WHEN FND_API.G_EXC_ERROR THEN
3114: ROLLBACK TO save_candidate;
3115: FND_MSG_PUB.get (
3116: p_encoded => FND_API.G_FALSE,
3117: p_msg_index => 1,

Line 3116: p_encoded => FND_API.G_FALSE,

3112: -- will need to continue for the next record
3113: WHEN FND_API.G_EXC_ERROR THEN
3114: ROLLBACK TO save_candidate;
3115: FND_MSG_PUB.get (
3116: p_encoded => FND_API.G_FALSE,
3117: p_msg_index => 1,
3118: p_data => x_msg_data,
3119: p_msg_index_out => x_msg_count );
3120: IF P_DEBUG_MODE = 'Y' THEN

Line 3128: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

3124: END;
3125:
3126: END LOOP;
3127:
3128: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
3129:
3130: ELSE
3131: -- person does not exist in pa_resource_txn_attributes
3132: X_RETURN_STATUS := FND_API.G_RET_STS_ERROR;

Line 3132: X_RETURN_STATUS := FND_API.G_RET_STS_ERROR;

3128: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
3129:
3130: ELSE
3131: -- person does not exist in pa_resource_txn_attributes
3132: X_RETURN_STATUS := FND_API.G_RET_STS_ERROR;
3133: END IF;
3134:
3135: -- reset the Error stack
3136: PA_DEBUG.Reset_Err_Stack;

Line 3147: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

3143: x_msg_data := SUBSTRB(SQLERRM ,1,240);
3144: -- Set the exception Message and the stack
3145: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.withdraw_cand_nominations'
3146: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
3147: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
3148: raise;
3149: END withdraw_cand_nominations;
3150:
3151:

Line 3197: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

3193: --dbms_output.put_line('New End Date:' || p_new_end_date);
3194:
3195: -- Initialize the Error stack
3196: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Update_EndDate');
3197: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
3198:
3199: l_count := 0; -- bug 7147575 : None records in pa_resources_denorm so far.
3200:
3201: FOR rec IN res_denorm_recs LOOP

Line 3237: IF l_return_status = FND_API.G_RET_STS_ERROR THEN

3233: ,x_return_status => l_return_status
3234: ,x_msg_data => x_msg_data
3235: ,x_msg_count => x_msg_count);
3236:
3237: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3238: x_return_status := FND_API.G_RET_STS_ERROR ;
3239: END IF;
3240:
3241: ELSIF p_new_end_date < rec.resource_effective_start_date THEN

Line 3238: x_return_status := FND_API.G_RET_STS_ERROR ;

3234: ,x_msg_data => x_msg_data
3235: ,x_msg_count => x_msg_count);
3236:
3237: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3238: x_return_status := FND_API.G_RET_STS_ERROR ;
3239: END IF;
3240:
3241: ELSIF p_new_end_date < rec.resource_effective_start_date THEN
3242:

Line 3251: IF l_return_status = FND_API.G_RET_STS_ERROR THEN

3247: ,x_return_status => l_return_status
3248: ,x_msg_data => x_msg_data
3249: ,x_msg_count => x_msg_count);
3250:
3251: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3252: x_return_status := FND_API.G_RET_STS_ERROR ;
3253: END IF;
3254:
3255: END IF;

Line 3252: x_return_status := FND_API.G_RET_STS_ERROR ;

3248: ,x_msg_data => x_msg_data
3249: ,x_msg_count => x_msg_count);
3250:
3251: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3252: x_return_status := FND_API.G_RET_STS_ERROR ;
3253: END IF;
3254:
3255: END IF;
3256:

Line 3268: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN

3264: x_return_status => l_return_status,
3265: x_msg_data => x_msg_data,
3266: x_msg_count => x_msg_count);
3267:
3268: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3269: x_return_status := FND_API.G_RET_STS_ERROR ;
3270: END IF ;
3271:
3272: /*if block added for bug 5683340*/

Line 3269: x_return_status := FND_API.G_RET_STS_ERROR ;

3265: x_msg_data => x_msg_data,
3266: x_msg_count => x_msg_count);
3267:
3268: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3269: x_return_status := FND_API.G_RET_STS_ERROR ;
3270: END IF ;
3271:
3272: /*if block added for bug 5683340*/
3273: IF ((l_invol_term = 'N') AND (l_return_status = FND_API.G_RET_STS_SUCCESS)) THEN

Line 3273: IF ((l_invol_term = 'N') AND (l_return_status = FND_API.G_RET_STS_SUCCESS)) THEN

3269: x_return_status := FND_API.G_RET_STS_ERROR ;
3270: END IF ;
3271:
3272: /*if block added for bug 5683340*/
3273: IF ((l_invol_term = 'N') AND (l_return_status = FND_API.G_RET_STS_SUCCESS)) THEN
3274:
3275: --Call Forecast Item regeneration API
3276: --to fix forecast data after resource was end_dated
3277: --start_date passed is the date when it changes

Line 3288: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN

3284: x_return_status => l_return_status,
3285: x_msg_count => x_msg_count,
3286: x_msg_data => x_msg_data) ;
3287:
3288: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3289: x_return_status := FND_API.G_RET_STS_ERROR ;
3290: END IF;
3291:
3292:

Line 3289: x_return_status := FND_API.G_RET_STS_ERROR ;

3285: x_msg_count => x_msg_count,
3286: x_msg_data => x_msg_data) ;
3287:
3288: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3289: x_return_status := FND_API.G_RET_STS_ERROR ;
3290: END IF;
3291:
3292:
3293: -- Call this procedure to withdraw any active candidacy of this

Line 3305: END IF ; --((l_invol_term = 'N') AND (l_return_status = FND_API.G_RET_STS_SUCCESS)) bug 5683340

3301: x_msg_data => x_msg_data);
3302:
3303: -- reset the Error stack
3304:
3305: END IF ; --((l_invol_term = 'N') AND (l_return_status = FND_API.G_RET_STS_SUCCESS)) bug 5683340
3306:
3307: END IF ; -- bug 7147575 : IF (l_count > 0 )
3308:
3309: PA_DEBUG.Reset_Err_Stack;

Line 3314: x_return_status := FND_API.G_RET_STS_ERROR ;

3310:
3311: EXCEPTION
3312:
3313: WHEN NO_DATA_FOUND THEN
3314: x_return_status := FND_API.G_RET_STS_ERROR ;
3315:
3316: WHEN OTHERS THEN
3317: -- 4537865 : RESET x_msg_count and x_msg_data also
3318: x_msg_count := 1 ;

Line 3323: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

3319: x_msg_data := SUBSTRB(SQLERRM ,1,240);
3320: -- Set the exception Message and the stack
3321: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Update_EndDate'
3322: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
3323: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
3324: raise;
3325: END Update_EndDate;
3326:
3327: /* Procedure Update_Org calls Update_Resource_Denorm and Create_Forecast_Item to update the organization and org_id for the resources in pa_resources_denorm table and regenerate forecast items for the resource respectively.

Line 3377: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

3373:
3374: -- Initialize the Error stack
3375: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Update_Org');
3376:
3377: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
3378:
3379: /* Check if new organization belongs to an expenditure
3380: organization, if yes then get default ou for old and new organization
3381: and update pa_resource_ou.organization.*/

Line 3394: ,p_commit => FND_API.G_FALSE

3390:
3391: pa_r_project_resources_pub.create_resource (
3392: p_api_version => 1.0
3393: ,p_init_msg_list => NULL
3394: ,p_commit => FND_API.G_FALSE
3395: ,p_validate_only => NULL
3396: ,p_max_msg_count => NULL
3397: ,p_internal => 'Y'
3398: ,p_person_id => p_person_id

Line 3442: X_RETURN_STATUS := FND_API.G_RET_STS_ERROR;

3438: p_app_short_name => 'PA'
3439: ,p_msg_name => 'PA_RS_DEF_OU_NULL');
3440:
3441: x_msg_data := 'PA_RS_DEF_OU_NULL';
3442: X_RETURN_STATUS := FND_API.G_RET_STS_ERROR;
3443: RETURN;
3444: -- ELSE
3445: -- l_default_ou_new := NULL;
3446: -- END IF;

Line 3476: IF l_return_status = FND_API.G_RET_STS_ERROR THEN

3472: ,x_return_status => l_return_status
3473: ,x_msg_data => x_msg_data
3474: ,x_msg_count => x_msg_count);
3475:
3476: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3477: x_return_status := FND_API.G_RET_STS_ERROR ;
3478: END IF;
3479:
3480: END LOOP; --end FOR

Line 3477: x_return_status := FND_API.G_RET_STS_ERROR ;

3473: ,x_msg_data => x_msg_data
3474: ,x_msg_count => x_msg_count);
3475:
3476: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3477: x_return_status := FND_API.G_RET_STS_ERROR ;
3478: END IF;
3479:
3480: END LOOP; --end FOR
3481:

Line 3495: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN

3491: x_msg_data => x_msg_data) ;
3492:
3493: END IF;
3494:
3495: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3496: x_return_status := FND_API.G_RET_STS_ERROR ;
3497: END IF;
3498:
3499: ELSE

Line 3496: x_return_status := FND_API.G_RET_STS_ERROR ;

3492:
3493: END IF;
3494:
3495: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3496: x_return_status := FND_API.G_RET_STS_ERROR ;
3497: END IF;
3498:
3499: ELSE
3500: /* In case the organization does not belong to expenditure

Line 3513: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN

3509: x_return_status => l_return_status,
3510: x_msg_data => x_msg_data,
3511: x_msg_count => x_msg_count);
3512:
3513: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3514: x_return_status := FND_API.G_RET_STS_ERROR ;
3515: END IF;
3516:
3517: END IF;

Line 3514: x_return_status := FND_API.G_RET_STS_ERROR ;

3510: x_msg_data => x_msg_data,
3511: x_msg_count => x_msg_count);
3512:
3513: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3514: x_return_status := FND_API.G_RET_STS_ERROR ;
3515: END IF;
3516:
3517: END IF;
3518:

Line 3525: X_RETURN_STATUS := fnd_api.g_ret_sts_error;

3521: PA_DEBUG.Reset_Err_Stack;
3522:
3523: EXCEPTION
3524: WHEN NO_DATA_FOUND THEN
3525: X_RETURN_STATUS := fnd_api.g_ret_sts_error;
3526:
3527: WHEN OTHERS THEN
3528: -- 4537865 : RESET x_msg_count and x_msg_data also
3529: x_msg_count := 1 ;

Line 3534: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

3530: x_msg_data := SUBSTRB(SQLERRM ,1,240);
3531: -- Set the exception Message and the stack
3532: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Update_Org'
3533: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
3534: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
3535: raise;
3536: END Update_Org;
3537:
3538: -- Start Bug : 4656855

Line 3695: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

3691:
3692: BEGIN
3693: -- Initialize the Error stack
3694: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Update_Job');
3695: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
3696: IF P_DEBUG_MODE = 'Y' THEN
3697: log_message('beginning of Update_Job');
3698: END IF;
3699:

Line 3735: ,p_commit => FND_API.G_FALSE

3731: END IF;
3732:
3733: PA_R_PROJECT_RESOURCES_PUB.CREATE_RESOURCE (
3734: p_api_version => 1.0
3735: ,p_commit => FND_API.G_FALSE
3736: ,p_validate_only => FND_API.G_FALSE
3737: ,p_internal => 'Y'
3738: ,p_person_id => p_person_id
3739: ,p_individual => 'Y'

Line 3736: ,p_validate_only => FND_API.G_FALSE

3732:
3733: PA_R_PROJECT_RESOURCES_PUB.CREATE_RESOURCE (
3734: p_api_version => 1.0
3735: ,p_commit => FND_API.G_FALSE
3736: ,p_validate_only => FND_API.G_FALSE
3737: ,p_internal => 'Y'
3738: ,p_person_id => p_person_id
3739: ,p_individual => 'Y'
3740: ,p_resource_type => 'EMPLOYEE'

Line 3808: IF l_return_status = FND_API.G_RET_STS_ERROR THEN

3804: ,x_return_status => l_return_status
3805: ,x_msg_data => x_msg_data
3806: ,x_msg_count => x_msg_count);
3807:
3808: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3809: x_return_status := FND_API.G_RET_STS_ERROR ;
3810: END IF;
3811: END LOOP;
3812:

Line 3809: x_return_status := FND_API.G_RET_STS_ERROR ;

3805: ,x_msg_data => x_msg_data
3806: ,x_msg_count => x_msg_count);
3807:
3808: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3809: x_return_status := FND_API.G_RET_STS_ERROR ;
3810: END IF;
3811: END LOOP;
3812:
3813: END IF;

Line 3831: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN

3827:
3828: IF P_DEBUG_MODE = 'Y' THEN
3829: log_message('after calling Create_Forecast_Item, l_return_status:'||l_return_status);
3830: END IF;
3831: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3832: x_return_status := FND_API.G_RET_STS_ERROR ;
3833: END IF;
3834:
3835: -- reset the Error stack

Line 3832: x_return_status := FND_API.G_RET_STS_ERROR ;

3828: IF P_DEBUG_MODE = 'Y' THEN
3829: log_message('after calling Create_Forecast_Item, l_return_status:'||l_return_status);
3830: END IF;
3831: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3832: x_return_status := FND_API.G_RET_STS_ERROR ;
3833: END IF;
3834:
3835: -- reset the Error stack
3836: PA_DEBUG.Reset_Err_Stack;

Line 3849: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

3845: x_msg_data := SUBSTRB(SQLERRM ,1,240);
3846: -- Set the exception Message and the stack
3847: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Update_Job'
3848: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
3849: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
3850: RAISE;
3851: END Update_Job;
3852:
3853: /* Procedure Update_Supervisor calls Update_Resource_Denorm to update

Line 3892: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

3888: BEGIN
3889:
3890: -- Initialize the Error stack
3891: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Update_Supervisor');
3892: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
3893:
3894: --Set the values for the Resources Denorm Record Type
3895: l_resource_rec_old.person_id := p_person_id;
3896: l_resource_rec_new.person_id := p_person_id;

Line 3918: IF l_return_status = FND_API.G_RET_STS_ERROR THEN

3914: ,x_return_status => l_return_status
3915: ,x_msg_data => x_msg_data
3916: ,x_msg_count => x_msg_count);
3917:
3918: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3919: x_return_status := FND_API.G_RET_STS_ERROR ;
3920: END IF;
3921:
3922: END LOOP;--end FOR

Line 3919: x_return_status := FND_API.G_RET_STS_ERROR ;

3915: ,x_msg_data => x_msg_data
3916: ,x_msg_count => x_msg_count);
3917:
3918: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
3919: x_return_status := FND_API.G_RET_STS_ERROR ;
3920: END IF;
3921:
3922: END LOOP;--end FOR
3923:

Line 3935: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

3931: x_msg_data := SUBSTRB(SQLERRM ,1,240);
3932: -- Set the exception Message and the stack
3933: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Update_Supervisor'
3934: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
3935: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
3936: raise;
3937: END Update_Supervisor;
3938:
3939: /* Procedure Update_PrimaryFlag calls Update_EndDate to end date the

Line 3959: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

3955:
3956: BEGIN
3957: -- Initialize the Error stack
3958: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Update_PrimaryFlag');
3959: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
3960:
3961: --Call Update_EndDate to end date the resource_ou record.
3962: -- Commented the end date change in PA as this is not required
3963: -- Solves bug 1608837

Line 3984: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN

3980: x_return_status => l_return_status,
3981: x_msg_count => x_msg_count,
3982: x_msg_data => x_msg_data) ;
3983:
3984: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3985: x_return_status := FND_API.G_RET_STS_ERROR ;
3986: END IF;
3987:
3988: -- reset the Error stack

Line 3985: x_return_status := FND_API.G_RET_STS_ERROR ;

3981: x_msg_count => x_msg_count,
3982: x_msg_data => x_msg_data) ;
3983:
3984: IF l_return_status <> FND_API.G_RET_STS_SUCCESS THEN
3985: x_return_status := FND_API.G_RET_STS_ERROR ;
3986: END IF;
3987:
3988: -- reset the Error stack
3989: PA_DEBUG.Reset_Err_Stack;

Line 3999: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

3995: x_msg_data := SUBSTRB(SQLERRM ,1,240);
3996: -- Set the exception Message and the stack
3997: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Update_PrimaryFlag'
3998: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
3999: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
4000: raise;
4001: END Update_PrimaryFlag;
4002:
4003: /* Procedure Update_Name calls updates the resource's name in pa_resources.

Line 4022: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

4018: BEGIN
4019:
4020: --Initialize the Error stack
4021: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Update_Name');
4022: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
4023:
4024: --Get resource_id for person_id
4025: l_resource_id := pa_resource_utils.get_resource_id(p_person_id);
4026:

Line 4028: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

4024: --Get resource_id for person_id
4025: l_resource_id := pa_resource_utils.get_resource_id(p_person_id);
4026:
4027: IF (l_resource_id = -999) THEN
4028: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
4029: return;
4030: END IF;
4031:
4032: UPDATE pa_resources

Line 4051: IF l_return_status = FND_API.G_RET_STS_ERROR THEN

4047: ,x_return_status => l_return_status
4048: ,x_msg_data => x_msg_data
4049: ,x_msg_count => x_msg_count);
4050:
4051: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
4052: x_return_status := FND_API.G_RET_STS_ERROR ;
4053: END IF;
4054:
4055: --Reset the Error stack

Line 4052: x_return_status := FND_API.G_RET_STS_ERROR ;

4048: ,x_msg_data => x_msg_data
4049: ,x_msg_count => x_msg_count);
4050:
4051: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
4052: x_return_status := FND_API.G_RET_STS_ERROR ;
4053: END IF;
4054:
4055: --Reset the Error stack
4056: PA_DEBUG.Reset_Err_Stack;

Line 4066: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

4062: x_msg_data := SUBSTRB(SQLERRM ,1,240);
4063: -- Set the exception Message and the stack
4064: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Update_Name'
4065: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
4066: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
4067: raise;
4068: END Update_Name;
4069:
4070:

Line 4099: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

4095:
4096: BEGIN
4097:
4098:
4099: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
4100:
4101: IF p_addr_prim_flag_new = 'Y' THEN
4102:
4103: --dbms_output.put_line('Inside address Update for person id:' || p_person_id);

Line 4108: ,p_commit => FND_API.G_FALSE

4104:
4105: pa_r_project_resources_pub.create_resource (
4106: p_api_version => 1.0
4107: ,p_init_msg_list => NULL
4108: ,p_commit => FND_API.G_FALSE
4109: ,p_validate_only => NULL
4110: ,p_max_msg_count => NULL
4111: ,p_internal => 'Y'
4112: ,p_person_id => p_person_id

Line 4124: IF l_return_status = FND_API.G_RET_STS_ERROR THEN

4120: END IF;
4121:
4122: --dbms_output.put_line('After address Update');
4123:
4124: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
4125: x_return_status := FND_API.G_RET_STS_ERROR ;
4126: END IF;
4127:
4128: EXCEPTION

Line 4125: x_return_status := FND_API.G_RET_STS_ERROR ;

4121:
4122: --dbms_output.put_line('After address Update');
4123:
4124: IF l_return_status = FND_API.G_RET_STS_ERROR THEN
4125: x_return_status := FND_API.G_RET_STS_ERROR ;
4126: END IF;
4127:
4128: EXCEPTION
4129: when others then

Line 4245: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;

4241:
4242: BEGIN
4243: -- Initialize the Error stack
4244: PA_DEBUG.init_err_stack('PA_HR_UPDATE_API.Delete_PA_Resource_Denorm');
4245: X_RETURN_STATUS := FND_API.G_RET_STS_SUCCESS;
4246:
4247: FOR rec IN res_denorm_recs LOOP
4248: --Delete the record
4249: DELETE FROM PA_RESOURCES_DENORM

Line 4261: x_return_status := FND_API.G_RET_STS_ERROR ;

4257:
4258: EXCEPTION
4259:
4260: WHEN NO_DATA_FOUND THEN
4261: x_return_status := FND_API.G_RET_STS_ERROR ;
4262:
4263: WHEN OTHERS THEN
4264: -- 4537865 : RESET x_msg_count and x_msg_data also
4265: x_msg_count := 1 ;

Line 4270: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;

4266: x_msg_data := SUBSTRB(SQLERRM ,1,240);
4267: -- Set the exception Message and the stack
4268: FND_MSG_PUB.add_exc_msg(p_pkg_name => 'PA_HR_UPDATE_API.Delete_PA_Resource_Denorm'
4269: ,p_procedure_name => PA_DEBUG.G_Err_Stack );
4270: x_return_status := FND_API.G_RET_STS_UNEXP_ERROR ;
4271: raise;
4272: END Delete_PA_Resource_Denorm;
4273:
4274: END PA_HR_UPDATE_API;