Friday 24 January 2014

Competencies and Jobs Assignments




1>     HR_COMPETENCES_API.CREATE_COMPETENCE – This API is used to create Competencies



2>     HR_COMPETENCE_ELEMENT_API.CREATE_COMPETENCE_ELEMENT – This API used for assigning competencies to Job/position

 

Test these API’s wth hard coding from back end.


--------------------------------------------------------------------------------------------------------

select * from  fnd_user where user_name like 'MOHAN'

1013795,25763,800

Select * from  FND_RESPONSIBILITY_TL WHERE RESPONSIBILITY_NAME like 'India%'

Rating scales


select * from  PER_RATING_SCALES_v where name like 'XX%'

select * from  PER_RATING_SCALES_v where rating_scale_id=4986

select * from  PER_RATING_LEVELS_V where rating_scale_id=4986


competencies

select * from  per_COMPETENCES WHERE TRUNC(CREATION_DATE)=TRUNC(SYSDATE)

select * from  per_competence_definitions WHERE TRUNC(CREATION_DATE)=TRUNC(SYSDATE)--where competence_definition_id=1793

select * from  fnd_id_flex_structures where id_flex_num=53071

select * from  fnd_id_flex_structures_tl where id_flex_num=53071

select * from   FND_FLEX_VALUES where flex_value_set_id=1016827


select * from  all_objects
where object_name like 'HR%COMPET%API%'
and object_type='PACKAGE BODY'



select * from  per_COMPETENCES WHERE BUSINESS_GROUP_ID=6786

Select * from  PER_JOBS WHERE NAME LIKE 'MGR100.Manager'

Select * from  PER_JOBS WHERE NAME LIKE 'SAL100.Sales Representative'

Select * from  PER_POSITIONS WHERE NAME LIKE 'Purchasing Manager' AND BUSINESS_GROUP_ID=6786

Select * from  ALL_TABLES WHERE TABLE_NAME LIKE 'PER%JOB%'


Select * from  PER_COMPETENCE_ELEMENTS WHERE TRUNC(CREATION_DATE)=TRUNC(SYSDATE)
DECLARE


v_competence_element_id     number;
v_object_version_number     number;
v_type                      varchar2(50):='REQUIREMENT';
v_business_group_id         number:=6786;
v_competence_id             number:=18521;
v_proficiency_level_id      number:=5569;
v_high_proficiency_level_id number:=5573;
v_effective_date_from       date:=sysdate;
v_job_id                    number;--:=25892;
v_position_id               number:=41470;                                                                 
v_effective_date            date:=sysdate;


BEGIN

fnd_global.apps_initialize(1013795,25763,800);


 HR_COMPETENCE_ELEMENT_API.CREATE_COMPETENCE_ELEMENT( p_validate=>FALSE,
                                                      p_competence_element_id=>v_competence_element_id,
                                                      p_object_version_number=>v_object_version_number,
                                                      p_type=>v_type,
                                                      p_business_group_id=>v_business_group_id,
                                                      p_competence_id=>v_competence_id,
                                                      p_proficiency_level_id=>v_proficiency_level_id ,
                                                      p_high_proficiency_level_id=>v_high_proficiency_level_id,
                                                      p_effective_date_from=>v_effective_date_from,
                                                      p_job_id=>v_job_id,
                                                      p_position_id=>v_position_id,
                                                      p_effective_date=> v_effective_date,
                                                      p_mandatory =>'N');

dbms_output.put_line('v_competence_element_id='||v_competence_element_id);

exception
when others then
     dbms_output.put_line('error : ' || sqlerrm);
END;                                                                 

No comments:

Post a Comment