276: paf.location_id,
277: hscf.segment18
278: FROM pay_us_states pus,
279: pay_us_states pus1,
280: hr_locations hl,
281: hr_locations hl1,
282: hr_soft_coding_keyflex hscf,
283: per_assignments_f paf
284: WHERE paf.assignment_id = p_assignment_id
277: hscf.segment18
278: FROM pay_us_states pus,
279: pay_us_states pus1,
280: hr_locations hl,
281: hr_locations hl1,
282: hr_soft_coding_keyflex hscf,
283: per_assignments_f paf
284: WHERE paf.assignment_id = p_assignment_id
285: AND p_session_date BETWEEN paf.effective_start_date
301: FROM pay_us_states pus,
302: pay_us_states pus1,
303: pay_us_counties puc,
304: pay_us_counties puc1,
305: hr_locations hl,
306: hr_locations hl1,
307: hr_soft_coding_keyflex hscf,
308: per_assignments_f paf
309: WHERE paf.assignment_id = p_assignment_id
302: pay_us_states pus1,
303: pay_us_counties puc,
304: pay_us_counties puc1,
305: hr_locations hl,
306: hr_locations hl1,
307: hr_soft_coding_keyflex hscf,
308: per_assignments_f paf
309: WHERE paf.assignment_id = p_assignment_id
310: AND p_session_date BETWEEN paf.effective_start_date
334: pay_us_counties puc,
335: pay_us_counties puc1,
336: pay_us_city_names pucy,
337: pay_us_city_names pucy1,
338: hr_locations hl,
339: hr_locations hl1,
340: hr_soft_coding_keyflex hscf,
341: per_assignments_f paf
342: WHERE paf.assignment_id = p_assignment_id
335: pay_us_counties puc1,
336: pay_us_city_names pucy,
337: pay_us_city_names pucy1,
338: hr_locations hl,
339: hr_locations hl1,
340: hr_soft_coding_keyflex hscf,
341: per_assignments_f paf
342: WHERE paf.assignment_id = p_assignment_id
343: AND p_session_date BETWEEN paf.effective_start_date
563:
564: cursor c_get_state_code(p_location_id in number) is
565: select pus.state_code
566: from pay_us_states pus,
567: hr_locations hl
568: where hl.location_id = p_location_id
569: and pus.state_abbrev = nvl(loc_information17,region_2);
570:
571:
750: /* created three new cursors to check taxation location jurisdictions */
751:
752: CURSOR csr_check_state is
753: select 1
754: from HR_LOCATIONS hrl,
755: PER_ASSIGNMENTS_F paf
756: where paf.assignment_id = p_assignment_id
757: and hrl.location_id = paf.location_id
758: and exists (select null
761: and pus.state_code = p_state_code);
762:
763: CURSOR csr_check_ovrd_state is
764: select 1
765: from HR_LOCATIONS hrl,
766: HR_SOFT_CODING_KEYFLEX hscf,
767: PER_ASSIGNMENTS_F paf
768: where paf.assignment_id = p_assignment_id
769: and hscf.soft_coding_keyflex_id = paf.soft_coding_keyflex_id
777: location of the assignment. */
778:
779: CURSOR csr_check_county is
780: select 1
781: from HR_LOCATIONS hrl,
782: PER_ASSIGNMENTS_F paf
783: where paf.assignment_id = p_assignment_id
784: and hrl.location_id = paf.location_id
785: and exists (select null
795: and puc.county_code = p_county_code);
796:
797: CURSOR csr_check_ovrd_county is
798: select 1
799: from HR_LOCATIONS hrl,
800: HR_SOFT_CODING_KEYFleX hscf,
801: PER_ASSIGNMENTS_F paf
802: where paf.assignment_id = p_assignment_id
803: and hscf.soft_coding_keyflex_id = paf.soft_coding_keyflex_id
818: location of the assignment. */
819:
820: CURSOR csr_check_city is
821: select 1
822: from HR_LOCATIONS hrl,
823: PER_ASSIGNMENTS_F paf
824: where paf.assignment_id = p_assignment_id
825: and hrl.location_id = paf.location_id
826: and exists (select null
842: and puci.city_code = p_city_code);
843:
844: CURSOR csr_check_ovrd_city is
845: select 1
846: from HR_LOCATIONS hrl,
847: HR_SOFT_CODING_KEYFLEX hscf,
848: PER_ASSIGNMENTS_F paf
849: where paf.assignment_id = p_assignment_id
850: and hscf.soft_coding_keyflex_id = paf.soft_coding_keyflex_id
1704: puci.city_name
1705: from PAY_US_CITY_NAMES puci,
1706: PAY_US_COUNTIES puc,
1707: PAY_US_STATES pus,
1708: HR_LOCATIONS hrl,
1709: HR_SOFT_CODING_KEYFLEX hscf,
1710: PER_ASSIGNMENTS_F paf
1711: where paf.assignment_id = p_assignment_id
1712: and p_session_date between paf.effective_start_date and
2067: puci.city_name
2068: from PAY_US_CITY_NAMES puci,
2069: PAY_US_COUNTIES puc,
2070: PAY_US_STATES pus,
2071: HR_LOCATIONS hrl
2072: where hrl.location_id = cp_location_id
2073: and pus.state_abbrev = hrl.region_2
2074: and puc.state_code = pus.state_code
2075: and puc.county_name = hrl.region_1
2086: puci.city_name
2087: from PAY_US_CITY_NAMES puci,
2088: PAY_US_COUNTIES puc,
2089: PAY_US_STATES pus,
2090: HR_LOCATIONS hrl
2091: where hrl.location_id = cp_location_id
2092: and pus.state_abbrev = hrl.loc_information17
2093: and puc.state_code = pus.state_code
2094: and puc.county_name = hrl.loc_information19