384: if (l_upg_level = 'B') then
385: --
386: sqlstr := 'select distinct pet.element_type_id
387: from
388: pay_element_types_f pet,
389: pay_payroll_actions pa1
390: where pa1.payroll_action_id = :payroll_action_id
391: and pet.business_group_id = pa1.business_group_id
392: order by pet.element_type_id';
394: elsif (l_upg_level = 'L') then
395: --
396: sqlstr := 'select distinct pet.element_type_id
397: from
398: pay_element_types_f pet,
399: pay_payroll_actions pa1,
400: per_business_groups_perf pbg1,
401: per_business_groups_perf pbg
402: where pa1.payroll_action_id = :payroll_action_id
409: elsif (l_upg_level = 'G') then
410: --
411: sqlstr := 'select distinct pet.element_type_id
412: from
413: pay_element_types_f pet,
414: pay_payroll_actions pa1
415: where pa1.payroll_action_id = :payroll_action_id
416: order by pet.element_type_id';
417: --
571: cp_endetid number
572: ) is
573: select distinct pet.element_type_id
574: from
575: pay_element_types_f pet,
576: pay_payroll_actions ppa
577: where ppa.payroll_action_id = cp_pactid
578: and ppa.business_group_id = pet.business_group_id
579: and pet.element_type_id between cp_stetid and cp_endetid;
615: cp_endetid number
616: ) is
617: select distinct pet.element_type_id
618: from
619: pay_element_types_f pet,
620: pay_payroll_actions ppa,
621: per_business_groups_perf pbg,
622: per_business_groups_perf pbg1
623: where ppa.payroll_action_id = cp_pactid
650: cp_stetid number,
651: cp_endetid number
652: ) is
653: select distinct pet.element_type_id
654: from pay_element_types_f pet
655: where pet.element_type_id between cp_stetid and cp_endetid;
656: --
657: l_upg_def_id pay_upgrade_definitions.upgrade_definition_id%type;
658: l_upg_def_nm pay_upgrade_definitions.short_name%type;