Join the OracleApps88 Telegram group @OracleApps88to get more information on Oracle EBS R12/Oracle Fusion applications.

If you are facing any issues while copying the Code/Script or any issues with Posts, Please send a mail to OracleApp88@Yahoo.com or message me at @apps88 or +91 905 957 4321 in telegram.

Monday, July 23, 2012

Getting the Position Name and Supervisor Id by Oracle User Login Name

SELECT
pos.name  position_name,
pa.position_id,                                               
fnd.user_name,
PA.SUPERVISOR_ID
FROM
PER_ALL_ASSIGNMENTS_F pa,
per_positions pos,
per_jobs job,
fnd_user fnd
WHERE 1=1
and pa.POSITION_ID =  pos.POSITION_ID
and pa.job_ID = job.job_id
and sysdate between pa.EFFECTIVE_START_DATE
and pa.EFFECTIVE_END_DATE
and pa.primary_flag = 'Y'
and pa.assignment_type = 'E'
and pa.person_id = fnd.employee_id
and pa.PERSON_ID = (
                                      select employee_id
                                      from fnd_user
                                      where user_name = :USERNAME
             )

No comments:

Post a Comment

If you are facing any issues while copying the Code/Script or any issues with Posts, Please send a mail to OracleApp88@Yahoo.com or message me at @apps88 or +91 905 957 4321 in telegram.
Best Blogger TipsGet Flower Effect