DBA Data[Home] [Help]

APPS.BEN_BENBATCH_PERSONS dependencies on PER_ALL_ASSIGNMENTS_F

Line 394: ', per_all_assignments_f paf1' ||

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

Line 402: ' from per_all_assignments_f paf2 ' ||

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

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

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

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

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

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

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

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

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

Line 655: ' from per_all_assignments_f paf' ||

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

Line 685: ' per_all_assignments_f paf' ||

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

Line 721: ' per_all_assignments_f paf' ||

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

Line 807: ' per_all_assignments_f paf' ||

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

Line 1159: ', per_all_assignments_f paf1' ||

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

Line 1167: ' from per_all_assignments_f paf2 ' ||

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

Line 1311: ' from per_all_assignments_f paf' ||

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

Line 1336: ' from per_all_assignments_f paf' ||

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

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

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

Line 1418: ' per_all_assignments_f paf' ||

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

Line 1445: ' per_all_assignments_f paf' ||

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

Line 1514: ' per_all_assignments_f paf' ||

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

Line 1569: ' , per_all_assignments_f paf' ||

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

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

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

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

1626: if l_def_flag ='Y' THEN
1627: l_query_str :=
1628: l_query_str ||
1629: ' and exists'||
1630: ' (select 1 from per_all_assignments_f paf'||
1631: ' where paf.person_id = ppf.person_id '||
1632: ' and paf.assignment_type <> ''C''' ||
1633: ' and paf.primary_flag = ''Y''' ||
1634: ' and paf.business_group_id = ppf.business_group_id' ||

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

1659:
1660: -- bug 3171229 -- changed the bind variable order in the sql
1661: l_query_str :=
1662: l_query_str || ' and exists('||
1663: ' select 1 from per_all_assignments_f paf' ||
1664: ' where paf.person_id = ppf.person_id' ||
1665: ' and paf.assignment_type <> ''C''' ||
1666: ' and paf.primary_flag = ''Y''' ||
1667: ' and paf.business_group_id = ppf.business_group_id' ||

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

1693: */
1694: l_query_str :=
1695: l_query_str || ' and -1 =:grade_ladder_id'||
1696: ' and exists'||
1697: ' (select 1 from per_all_assignments_f paf '||
1698: ' where paf.person_id = ppf.person_id '||
1699: ' and paf.assignment_type <> ''C''' ||
1700: ' and paf.primary_flag = ''Y''' ||
1701: ' and :grade_ladder_id_date2 between paf.effective_start_date and paf.effective_end_date ' ||

Line 1768: ' , per_all_assignments_f paf'||

1764: l_query_str :=
1765: l_query_str || ' and exists'||
1766: ' (select 1'||
1767: ' from per_spinal_point_placements_f spp'||
1768: ' , per_all_assignments_f paf'||
1769: ' where paf.person_id = ppf.person_id'||
1770: ' and :effective_date between paf.effective_start_date and paf.effective_end_date'||
1771: ' and paf.assignment_type <> ''C''' ||
1772: ' and paf.primary_flag = ''Y''' ||

Line 1891: ' , per_all_assignments_f paf'||

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