DBA Data[Home] [Help]

APPS.PER_CANCEL_HIRE_OR_APL_PKG dependencies on PER_PERSON_TYPE_USAGES_F

Line 31: from per_person_type_usages_f ptu, per_person_types ppt

27: -- Declare cursor
28: --
29: Cursor csr_person_types is
30: select ppt.system_person_type
31: from per_person_type_usages_f ptu, per_person_types ppt
32: where ptu.person_type_id = ppt.person_type_id
33: and person_id = p_person_id
34: and ppt.business_group_id = p_business_group_id
35: and ppt.system_person_type <> p_current_person_type

Line 41: from per_person_type_usages_f ptu, per_person_types ppt

37: and ppt.system_person_type in ('EMP','EX_EMP','APL','EX_APL','CWK','EX_CWK');
38:
39: Cursor csr_prev_person_types is
40: select ppt.system_person_type
41: from per_person_type_usages_f ptu, per_person_types ppt
42: where ptu.person_type_id = ppt.person_type_id
43: and person_id = p_person_id
44: and ppt.business_group_id = p_business_group_id
45: and ppt.system_person_type in ('EMP','EX_EMP','APL','EX_APL','CWK','EX_CWK')

Line 48: from per_person_type_usages_f ptu1, per_person_types ppt1

44: and ppt.business_group_id = p_business_group_id
45: and ppt.system_person_type in ('EMP','EX_EMP','APL','EX_APL','CWK','EX_CWK')
46: and ptu.effective_end_date =
47: (select effective_start_date - 1
48: from per_person_type_usages_f ptu1, per_person_types ppt1
49: where ptu1.person_type_id = ppt1.person_type_id
50: and ptu1.person_id = p_person_id
51: and ppt1.system_person_type = p_current_person_type
52: and p_effective_date between effective_start_date and effective_end_date)

Line 71: from per_person_type_usages_f ptu1, per_person_types ppt1

67: 'EX_EMP_APL',
68: 'OTHER')
69: and papf.effective_end_date =
70: (select effective_start_date - 1
71: from per_person_type_usages_f ptu1, per_person_types ppt1
72: where ptu1.person_type_id = ppt1.person_type_id
73: and ptu1.person_id = p_person_id
74: and ppt.business_group_id = p_business_group_id
75: and ppt1.system_person_type = p_current_person_type

Line 1021: per_person_type_usages_f ptu

1017: -- Start Bug 3285486
1018: CURSOR csr_get_ptu_id(p_system_person_type varchar2) IS
1019: SELECT ptu.person_type_usage_id
1020: FROM per_person_types pt,
1021: per_person_type_usages_f ptu
1022: WHERE pt.business_group_id = p_business_group_id
1023: AND pt.person_type_id = ptu.person_type_id
1024: AND p_primary_date BETWEEN ptu.effective_start_date
1025: AND ptu.effective_end_date

Line 1577: per_person_type_usages_f ptu

1573:
1574: CURSOR csr_get_ptu_id IS
1575: SELECT ptu.person_type_usage_id
1576: FROM per_person_types pt,
1577: per_person_type_usages_f ptu
1578: WHERE pt.business_group_id = p_business_group_id
1579: AND pt.person_type_id = ptu.person_type_id
1580: AND p_date_start BETWEEN ptu.effective_start_date
1581: AND ptu.effective_end_date

Line 2032: from per_person_type_usages_f ptu

2028: ,p_system_person_type in varchar2
2029: ) is
2030: select ptu.person_type_usage_id
2031: ,ptu.object_version_number
2032: from per_person_type_usages_f ptu
2033: where p_effective_date between ptu.effective_start_date and ptu.effective_end_date
2034: and ptu.person_id = p_person_id
2035: and ptu.person_type_id in
2036: (select ppt.person_type_id

Line 2058: update per_person_type_usages_f ptu

2054: if csr_upded_person_type_usages%found then
2055:
2056: hr_utility.set_location('Entering Upd_Person_Type_Usage_End_Date',492);
2057:
2058: update per_person_type_usages_f ptu
2059: set effective_end_date = l_effective_end_date
2060: where ptu.effective_end_date = p_effective_date
2061: and ptu.person_id = p_person_id
2062: and ptu.person_type_usage_id = l_csr_upd_per_type_usages.person_type_usage_id

Line 2312: from per_person_type_usages_f ptu

2308: -- 3194314
2309: --
2310: cursor csr_emp_ptu_id is
2311: select ptu.person_type_id
2312: from per_person_type_usages_f ptu
2313: ,per_person_types ppt
2314: where ptu.person_id = p_person_id
2315: and ptu.effective_start_date = p_date_start
2316: and ptu.person_type_id = ppt.person_type_id

Line 2326: from per_person_type_usages_f ptu

2322: --3848352 start
2323: --
2324: cursor csr_apl_ptu_id is
2325: select ptu.person_type_id
2326: from per_person_type_usages_f ptu
2327: ,per_person_types ppt
2328: where ptu.person_id = p_person_id
2329: and ptu.effective_end_date = p_date_start - 1
2330: and ptu.person_type_id = ppt.person_type_id

Line 2836: -- to be used in per_person_type_usages_f

2832: where rowid = p_rowid;
2833:
2834: -- code added for the bug 8504597 starts here
2835: -- reverting the person type to EX_EMP
2836: -- to be used in per_person_type_usages_f
2837: -- as in person_type_usages_f only ex_emp record has to be created
2838: -- as the applicant record is already existing
2839: -- if ths is not done then will hit the error
2840: -- PER_PERSON_TYPE_USAGES_F_FK2

Line 2840: -- PER_PERSON_TYPE_USAGES_F_FK2

2836: -- to be used in per_person_type_usages_f
2837: -- as in person_type_usages_f only ex_emp record has to be created
2838: -- as the applicant record is already existing
2839: -- if ths is not done then will hit the error
2840: -- PER_PERSON_TYPE_USAGES_F_FK2
2841: -- from per_ptu_bus.chk_person_type_id
2842:
2843: select person_type_id
2844: into l_person_type_id

Line 3227: --from per_person_type_usages_f ptu, per_person_types ppt

3223: -- person type usages cursor
3224: --
3225: --cursor person_type_usages2 is
3226: --select ptu.person_type_usage_id, ptu.object_version_number
3227: --from per_person_type_usages_f ptu, per_person_types ppt
3228: --where person_id = p_person_id
3229: --and ptu.person_type_id = ppt.person_type_id
3230: --and ppt.system_person_type = 'APL'
3231: --and ptu.effective_start_date = p_date_received;

Line 3314: from per_person_type_usages_f ptu

3310: --
3311: -- Bug 4095559: Cursor return whether B2B of EX_EMP/EX_CWK.APL
3312: cursor csr_b2b_apl is
3313: select count(ptu.person_type_id)
3314: from per_person_type_usages_f ptu
3315: ,per_person_types ppt
3316: where ptu.person_id = p_person_id
3317: and ptu.effective_start_date = p_date_received
3318: and ptu.person_type_id = ppt.person_type_id

Line 3341: from per_person_type_usages_f

3337: -- Bug 4095559: Cursor to get the latest person_type_id B2B of
3338: -- EX_EMP/EX_CWK.APL
3339: cursor latest_ptid is
3340: select person_type_id
3341: from per_person_type_usages_f
3342: where person_id = p_person_id
3343: order by EFFECTIVE_END_DATE desc, EFFECTIVE_START_DATE desc;
3344: --
3345: -- Cursor to re-evaluate the security.

Line 3358: from per_person_type_usages_f ptu

3354: -- start changes for bug 8405711
3355: -- cursor to evaluate whether the person became B2B Apl on the hire day
3356: cursor chk_prv_APL_exists is
3357: select person_type_id
3358: from per_person_type_usages_f ptu
3359: where ptu.person_id = p_person_id
3360: and ptu.effective_end_date = p_date_received - 1
3361: and exists (
3362: select ppt.person_type_id

Line 3368: from per_person_types ppt1, per_person_type_usages_f ptu1

3364: where ppt.system_person_type = 'APL'
3365: and ppt.business_group_id = p_business_group_id
3366: and ppt.person_type_id = ptu.person_type_id)
3367: and exists (select ppt1.person_type_id
3368: from per_person_types ppt1, per_person_type_usages_f ptu1
3369: where ptu1.person_type_id = ppt1.person_type_id
3370: and ppt1.business_group_id = p_business_group_id
3371: and ptu1.person_id = p_person_id
3372: and ppt1.system_person_type in ('EMP','CWK')

Line 3907: update per_person_type_usages_f ptu

3903: close chk_prv_APL_exists;
3904:
3905: -- When the person became B2B Applicant on his hired Day then
3906: -- system will convert the APL record to EX_APL type.
3907: update per_person_type_usages_f ptu
3908: set person_type_id = hr_person_type_usage_info.get_default_person_type_id
3909: (p_business_group_id, 'EX_APL')
3910: where ptu.person_id = p_person_id
3911: and ptu.effective_start_date = p_date_received

Line 3922: delete from per_person_type_usages_f ptu

3918: close chk_prv_APL_exists;
3919: -- end changes for bug 8405711
3920:
3921: -- updated for bug 8405711, to delete all the APL entries after the Application start date
3922: delete from per_person_type_usages_f ptu
3923: where ptu.person_id = p_person_id
3924: and ptu.effective_start_date >= p_date_received
3925: and ptu.person_type_id in (
3926: select ppt.person_type_id

Line 3932: update per_person_type_usages_f ptu

3928: where ppt.system_person_type = 'APL'
3929: and business_group_id = p_business_group_id);
3930:
3931: -- start changes for bug 8405711
3932: update per_person_type_usages_f ptu
3933: set effective_end_date = to_date('31/12/4712','dd/mm/yyyy')
3934: where ptu.person_id = p_person_id
3935: and ptu.person_type_id in (
3936: select ppt.person_type_id

Line 4131: per_person_type_usages_f ptu

4127: --
4128: CURSOR csr_get_ptu_id IS
4129: SELECT ptu.person_type_usage_id
4130: FROM per_person_types pt,
4131: per_person_type_usages_f ptu
4132: WHERE pt.business_group_id = p_business_group_id
4133: AND pt.person_type_id = ptu.person_type_id
4134: AND l_effective_date BETWEEN ptu.effective_start_date
4135: AND ptu.effective_end_date

Line 4494: l_person_type_usage_id per_person_type_usages_f.person_type_usage_id%TYPE;

4490: l_new_person_found BOOLEAN;
4491: l_person_rec_found BOOLEAN;
4492: l_effective_start_date DATE := NULL;
4493: l_effective_end_date DATE := NULL;
4494: l_person_type_usage_id per_person_type_usages_f.person_type_usage_id%TYPE;
4495: l_object_version_number per_person_type_usages_f.object_version_number%TYPE;
4496: c_effective_start_date date; --Added for the bug 6460093
4497: --l_ex_apl_person_type_id per_person_type_usages_f.person_type_usage_id%TYPE; --Added for the bug#13442055 -- Commented for the bug#13576986
4498: l_cur_sys_person_type per_person_types.system_person_type%TYPE; --Added for the bug#13576986

Line 4495: l_object_version_number per_person_type_usages_f.object_version_number%TYPE;

4491: l_person_rec_found BOOLEAN;
4492: l_effective_start_date DATE := NULL;
4493: l_effective_end_date DATE := NULL;
4494: l_person_type_usage_id per_person_type_usages_f.person_type_usage_id%TYPE;
4495: l_object_version_number per_person_type_usages_f.object_version_number%TYPE;
4496: c_effective_start_date date; --Added for the bug 6460093
4497: --l_ex_apl_person_type_id per_person_type_usages_f.person_type_usage_id%TYPE; --Added for the bug#13442055 -- Commented for the bug#13576986
4498: l_cur_sys_person_type per_person_types.system_person_type%TYPE; --Added for the bug#13576986
4499: l_npw_number per_people_f.npw_number%TYPE; --Added for the bug#13772471

Line 4497: --l_ex_apl_person_type_id per_person_type_usages_f.person_type_usage_id%TYPE; --Added for the bug#13442055 -- Commented for the bug#13576986

4493: l_effective_end_date DATE := NULL;
4494: l_person_type_usage_id per_person_type_usages_f.person_type_usage_id%TYPE;
4495: l_object_version_number per_person_type_usages_f.object_version_number%TYPE;
4496: c_effective_start_date date; --Added for the bug 6460093
4497: --l_ex_apl_person_type_id per_person_type_usages_f.person_type_usage_id%TYPE; --Added for the bug#13442055 -- Commented for the bug#13576986
4498: l_cur_sys_person_type per_person_types.system_person_type%TYPE; --Added for the bug#13576986
4499: l_npw_number per_people_f.npw_number%TYPE; --Added for the bug#13772471
4500: --
4501: -- events cursor

Line 4720: FROM per_person_types pt, per_person_type_usages_f ptu

4716: -- Changes start for the bug 7110731
4717:
4718: CURSOR csr_get_cwk_type (p_sys_person_type IN CHAR) IS
4719: SELECT pt.person_type_id
4720: FROM per_person_types pt, per_person_type_usages_f ptu
4721: WHERE pt.person_type_id = ptu.person_type_id
4722: AND pt.business_group_id = p_business_group_id
4723: AND pt.system_person_type = p_sys_person_type
4724: AND ptu.person_id = p_person_id

Line 4736: FROM per_person_type_usages_f ptu,

4732:
4733: CURSOR csr_get_ptu_details IS
4734: SELECT ptu.person_type_usage_id,
4735: ptu.object_version_number
4736: FROM per_person_type_usages_f ptu,
4737: per_person_types pt
4738: WHERE ptu.person_id = p_person_id
4739: AND pt.person_type_id = ptu.person_type_Id
4740: AND pt.system_person_type = 'CWK'

Line 4748: FROM per_person_type_usages_f ptu,

4744: -- Changes start for the bug 13576986
4745:
4746: CURSOR csr_is_apl_ex_apl IS
4747: SELECT pt.system_person_type
4748: FROM per_person_type_usages_f ptu,
4749: per_person_types pt
4750: WHERE ptu.person_id = p_person_id
4751: AND pt.person_type_id = ptu.person_type_Id
4752: AND pt.system_person_type in ('EX_APL','APL')

Line 4761: FROM per_person_type_usages_f ptu,

4757: -- Changes start for the bug 13442055
4758:
4759: /*CURSOR csr_is_ex_apl IS
4760: SELECT ptu.person_type_usage_id
4761: FROM per_person_type_usages_f ptu,
4762: per_person_types pt
4763: WHERE ptu.person_id = p_person_id
4764: AND pt.person_type_id = ptu.person_type_Id
4765: AND pt.system_person_type = 'EX_APL'

Line 5191: UPDATE per_person_type_usages_f

5187: OPEN csr_get_cwk_type (p_sys_person_type => 'CWK');
5188: FETCH csr_get_cwk_type INTO l_person_type_id1;
5189: CLOSE csr_get_cwk_type;
5190:
5191: UPDATE per_person_type_usages_f
5192: SET person_type_id = l_person_type_id
5193: WHERE person_id = p_person_id
5194: AND person_type_id= l_person_type_id1
5195: AND p_date_start BETWEEN effective_start_date

Line 5453: -- then delete the current CWK record from per_person_type_usages_f

5449:
5450: --Change for the bug 6460093 ends here
5451:
5452: -- If there are back to back records for period of service
5453: -- then delete the current CWK record from per_person_type_usages_f
5454: -- table.
5455: --
5456: -- bug fix 6992346
5457: -- If there are back to back records for period of service