DBA Data[Home] [Help]

APPS.BEN_BENBATCH_PERSONS dependencies on PER_ALL_ASSIGNMENTS_F

Line 397: ', per_all_assignments_f paf1' ||

393: ELSE
394: --
395: l_query_str :=
396: ' select ppf.person_id from per_all_people_f ppf' ||
397: ', per_all_assignments_f paf1' ||
398: ' where ppf.business_group_id = :business_group_id ' ||
399: ' and ppf.person_id = paf1.person_id(+) ' ||
400: ' and ppf.business_group_id = paf1.business_group_id(+) ' ||
401: ' and paf1.primary_flag(+) = ''Y'' ' ||

Line 405: ' from per_all_assignments_f paf2 ' ||

401: ' and paf1.primary_flag(+) = ''Y'' ' ||
402: ' and (paf1.assignment_id is null ' ||
403: ' or paf1.assignment_id = ' ||
404: ' ( select min(paf2.assignment_id) ' ||
405: ' from per_all_assignments_f paf2 ' ||
406: ' where paf2.person_id = paf1.person_id ' ||
407: ' and paf2.assignment_type <> ''C'''||
408: ' and paf1.business_group_id = paf2.business_group_id ' ||
409: ' and paf2.primary_flag = ''Y'' ' ||

Line 461: l_cwb_whclause := l_cwb_whclause || ' and exists ( select 1 from per_all_assignments_f asgn'

457: -- for cwb, person should have a valid assignment
458: --
459: if nvl(p_cwb_person_type,'AEXE') in ( 'AE' , 'AEXE' )
460: then
461: l_cwb_whclause := l_cwb_whclause || ' and exists ( select 1 from per_all_assignments_f asgn'
462: || ' where asgn.person_id = ppf.person_id '
463: || ' and asgn.PRIMARY_FLAG = ''Y'' '
464: || ' and :effective_date between asgn.effective_start_date '
465: || ' and asgn.effective_end_date '

Line 487: || ' and exists ( select 1 from per_all_assignments_f asgn'

483: --
484: if l_wth_start_date is not null
485: then
486: l_cwb_whclause := l_cwb_whclause
487: || ' and exists ( select 1 from per_all_assignments_f asgn'
488: || ' , per_assignment_status_types pat '
489: || ' where asgn.person_id = ppf.person_id '
490: || ' and pat.assignment_status_type_id = asgn.assignment_status_type_id '
491: || ' and pat.per_system_status = ''ACTIVE_ASSIGN'' '

Line 499: || ' and exists ( select 1 from per_all_assignments_f asgn'

495: || ' and asgn.effective_end_date >= :l_wth_start_date )' ;
496: --Bug 6718304
497: else
498: l_cwb_whclause := l_cwb_whclause
499: || ' and exists ( select 1 from per_all_assignments_f asgn'
500: || ' , per_assignment_status_types pat '
501: || ' where asgn.person_id = ppf.person_id '
502: || ' and pat.assignment_status_type_id = asgn.assignment_status_type_id '
503: || ' and pat.per_system_status = ''ACTIVE_ASSIGN'' '

Line 513: || ' and exists ( select 1 from per_all_assignments_f asgn'

509: -- Bug 6718304
510: end if;
511: else
512: l_cwb_whclause := l_cwb_whclause
513: || ' and exists ( select 1 from per_all_assignments_f asgn'
514: || ' , per_assignment_status_types pat '
515: || ' where asgn.person_id = ppf.person_id '
516: || ' and pat.assignment_status_type_id = asgn.assignment_status_type_id '
517: || ' and pat.per_system_status = ''ACTIVE_ASSIGN'' '

Line 658: ' from per_all_assignments_f paf' ||

654: l_location_id_bind := p_location_id;
655: l_location_id_date_bind := p_effective_date;
656: l_query_str :=
657: l_query_str || ' and exists (select null' ||
658: ' from per_all_assignments_f paf' ||
659: ' where paf.person_id = ppf.person_id' ||
660: ' and paf.assignment_type <> ''C'''||
661: ' and paf.primary_flag = ''Y''' ||
662: ' and paf.business_group_id = ppf.business_group_id' ||

Line 688: ' per_all_assignments_f paf' ||

684: l_legal_entity_id_bind := p_legal_entity_id;
685: l_query_str :=
686: l_query_str || ' and exists (select null' ||
687: ' from hr_soft_coding_keyflex hsc,' ||
688: ' per_all_assignments_f paf' ||
689: ' where paf.person_id = ppf.person_id' ||
690: ' and paf.assignment_type <> ''C'''||
691: ' and paf.primary_flag = ''Y''' ||
692: ' and paf.business_group_id = ppf.business_group_id' ||

Line 724: ' per_all_assignments_f paf' ||

720: l_payroll_id_date2_bind := p_effective_date;
721: --
722: l_query_str :=
723: l_query_str || ' and exists (select null' || ' from pay_payrolls_f pay,' ||
724: ' per_all_assignments_f paf' ||
725: ' where paf.person_id = ppf.person_id ' ||
726: ' and paf.assignment_type <> ''C'''||
727: ' and paf.primary_flag = ''Y''' ||
728: ' and paf.business_group_id = ppf.business_group_id' ||

Line 810: ' per_all_assignments_f paf' ||

806: --
807: l_query_str :=
808: l_query_str || ' and exists (select null' ||
809: ' from hr_organization_units org,' ||
810: ' per_all_assignments_f paf' ||
811: ' where paf.person_id = ppf.person_id' ||
812: ' and paf.assignment_type <> ''C'''||
813: ' and paf.primary_flag = ''Y''' ||
814: ' and paf.business_group_id = ppf.business_group_id' ||

Line 1162: ', per_all_assignments_f paf1' ||

1158: else
1159: --
1160: l_query_str :=
1161: ' select ppf.person_id from per_all_people_f ppf' ||
1162: ', per_all_assignments_f paf1' ||
1163: ' where ppf.business_group_id = :bus_grp_id' ||
1164: ' and ppf.person_id = paf1.person_id(+) ' ||
1165: ' and ppf.business_group_id = paf1.business_group_id(+) ' ||
1166: ' and paf1.primary_flag(+) = ''Y'' ' ||

Line 1170: ' from per_all_assignments_f paf2 ' ||

1166: ' and paf1.primary_flag(+) = ''Y'' ' ||
1167: ' and (paf1.assignment_id is null ' ||
1168: ' or paf1.assignment_id = ' ||
1169: ' ( select min(paf2.assignment_id) ' ||
1170: ' from per_all_assignments_f paf2 ' ||
1171: ' where paf2.person_id = paf1.person_id ' ||
1172: ' and paf2.assignment_type <> ''C'''||
1173: ' and paf1.business_group_id = paf2.business_group_id ' ||
1174: ' and paf2.primary_flag = ''Y'' ' ||

Line 1314: ' from per_all_assignments_f paf' ||

1310: l_location_id_bind := p_location_id;
1311: l_location_id_date_bind := p_effective_date;
1312: l_query_str :=
1313: l_query_str || ' and exists (select null' ||
1314: ' from per_all_assignments_f paf' ||
1315: ' where paf.person_id = ppf.person_id' ||
1316: ' and paf.assignment_type <> ''C'''||
1317: ' and paf.primary_flag = ''Y''' ||
1318: ' and paf.business_group_id = ppf.business_group_id' ||

Line 1339: ' from per_all_assignments_f paf' ||

1335: l_cagr_id_bind := p_cagr_id;
1336: l_cagr_id_date_bind := p_effective_date;
1337: l_query_str :=
1338: l_query_str || ' and exists (select null' ||
1339: ' from per_all_assignments_f paf' ||
1340: ' where paf.person_id = ppf.person_id' ||
1341: ' and paf.assignment_type <> ''C'''||
1342: ' and paf.primary_flag = ''Y''' ||
1343: ' and paf.business_group_id = ppf.business_group_id' ||

Line 1388: ' per_person_types ppt, per_all_assignments_f apl_ass '||

1384: -- if its iREC pick up only applicants
1385: IF p_mode = 'I' THEN
1386: l_assignment_id_bind := ben_manage_life_events.g_irec_ass_rec.assignment_id;
1387: l_irec_whclause := ' and exists ( select ''x'' from per_person_type_usages_f ptu, '||
1388: ' per_person_types ppt, per_all_assignments_f apl_ass '||
1389: ' where ppt.person_type_id = ptu.person_type_id '||
1390: ' and ppt.system_person_type in( ''APL'', ''APL_EX_APL'',''EMP_APL'', ''EX_EMP_APL'')'||
1391: ' and ppt.business_group_id = ppf.business_group_id '||
1392: ' and ptu.person_id = ppf.person_id '||

Line 1421: ' per_all_assignments_f paf' ||

1417: l_legal_entity_id_bind := p_legal_entity_id;
1418: l_query_str :=
1419: l_query_str || ' and exists (select null' ||
1420: ' from hr_soft_coding_keyflex hsc,' ||
1421: ' per_all_assignments_f paf' ||
1422: ' where paf.person_id = ppf.person_id' ||
1423: ' and paf.assignment_type <> ''C''' ||
1424: ' and paf.primary_flag = ''Y''' ||
1425: ' and paf.business_group_id = ppf.business_group_id' ||

Line 1448: ' per_all_assignments_f paf' ||

1444: l_payroll_id_bind := p_payroll_id;
1445: l_payroll_id_date2_bind := p_effective_date;
1446: l_query_str :=
1447: l_query_str || ' and exists (select null' || ' from pay_payrolls_f pay,' ||
1448: ' per_all_assignments_f paf' ||
1449: ' where paf.person_id = ppf.person_id' ||
1450: ' and paf.assignment_type <> ''C''' ||
1451: ' and paf.primary_flag = ''Y''' ||
1452: ' and paf.business_group_id = ppf.business_group_id' ||

Line 1517: ' per_all_assignments_f paf' ||

1513: l_organization_id_date3_bind := p_effective_date;
1514: l_query_str :=
1515: l_query_str || ' and exists (select null' ||
1516: ' from hr_organization_units org,' ||
1517: ' per_all_assignments_f paf' ||
1518: ' where paf.person_id = ppf.person_id' ||
1519: ' and paf.assignment_type <> ''C''' ||
1520: ' and paf.primary_flag = ''Y''' ||
1521: ' and paf.business_group_id = ppf.business_group_id' ||

Line 1572: ' , per_all_assignments_f paf' ||

1568:
1569: l_query_str :=
1570: l_query_str ||' and exists'||
1571: ' (select 1 from per_org_structure_elements ose'||
1572: ' , per_all_assignments_f paf' ||
1573: ' where paf.person_id = ppf.person_id' ||
1574: ' and paf.assignment_type <> ''C''' ||
1575: ' and paf.primary_flag = ''Y''' ||
1576: ' and paf.business_group_id = ppf.business_group_id' ||

Line 1588: ' select 1 from per_all_assignments_f paf' ||

1584: ' and ose.org_structure_version_id = :org_hierarchy'||
1585: ' start with ose.organization_id_parent = :org_starting_node_id'||
1586: ' and ose.org_structure_version_id = :org_hierarchy'||
1587: ' union all'||
1588: ' select 1 from per_all_assignments_f paf' ||
1589: ' where paf.person_id = ppf.person_id' ||
1590: ' and paf.assignment_type <> ''C''' ||
1591: ' and paf.primary_flag = ''Y''' ||
1592: ' and paf.business_group_id = ppf.business_group_id' ||

Line 1633: ' (select 1 from per_all_assignments_f paf'||

1629: if l_def_flag ='Y' THEN
1630: l_query_str :=
1631: l_query_str ||
1632: ' and exists'||
1633: ' (select 1 from per_all_assignments_f paf'||
1634: ' where paf.person_id = ppf.person_id '||
1635: -- ' and paf.assignment_type <> ''C''' ||
1636: ' and paf.assignment_type = ''E''' || /* Bug 7307975 Assumption is that GSP is run only for Employees */
1637: ' and paf.primary_flag = ''Y''' ||

Line 1667: ' select 1 from per_all_assignments_f paf' ||

1663:
1664: -- bug 3171229 -- changed the bind variable order in the sql
1665: l_query_str :=
1666: l_query_str || ' and exists('||
1667: ' select 1 from per_all_assignments_f paf' ||
1668: ' where paf.person_id = ppf.person_id' ||
1669: -- ' and paf.assignment_type <> ''C''' ||
1670: ' and paf.assignment_type = ''E''' || /* Bug 7307975 Assumption is that GSP is run only for Employees */
1671: ' and paf.primary_flag = ''Y''' ||

Line 1702: ' (select 1 from per_all_assignments_f paf '||

1698: */
1699: l_query_str :=
1700: l_query_str || ' and -1 =:grade_ladder_id'||
1701: ' and exists'||
1702: ' (select 1 from per_all_assignments_f paf '||
1703: ' where paf.person_id = ppf.person_id '||
1704: ' and paf.assignment_type <> ''C''' ||
1705: ' and paf.primary_flag = ''Y''' ||
1706: ' and :grade_ladder_id_date2 between paf.effective_start_date and paf.effective_end_date ' ||

Line 1773: ' , per_all_assignments_f paf'||

1769: l_query_str :=
1770: l_query_str || ' and exists'||
1771: ' (select 1'||
1772: ' from per_spinal_point_placements_f spp'||
1773: ' , per_all_assignments_f paf'||
1774: ' where paf.person_id = ppf.person_id'||
1775: ' and :effective_date between paf.effective_start_date and paf.effective_end_date'||
1776: ' and paf.assignment_type <> ''C''' ||
1777: ' and paf.primary_flag = ''Y''' ||

Line 1896: ' , per_all_assignments_f paf'||

1892: -- append the common portion of the query
1893: l_query_str :=
1894: l_query_str || ' and exists ('||
1895: ' select 1 from pay_people_groups ppg'||
1896: ' , per_all_assignments_f paf'||
1897: ' where paf.people_group_id = ppg.people_group_id'||
1898: ' and paf.person_id = ppf.person_id'||
1899: ' and :effective_date between paf.effective_start_date and paf.effective_end_date'||
1900: ' and paf.assignment_type <> ''C''' ||