343: l_template_name VARCHAR2(80);
344:
345: BEGIN
346: --
347: hr_utility.set_location('pay_ca_user_init_earn.get_template_id',1);
348: --
349: if p_calc_rule_code = 'FLT' then
350: l_template_name := 'Flat Amount Earning';
351: --l_template_name := 'Test Flat Amount Earnings';
356: l_template_name := 'Percent of Earnings Earning';
357: elsif p_calc_rule_code = 'NTG FLT' then
358: l_template_name := 'Net To Gross Earning';
359: else
360: hr_utility.set_location('pay_ca_user_init_earn.get_template_id',2);
361: hr_utility.set_message(801,'HR_XXXXX_INVALID_CALC_RULE_EARN');
362: hr_utility.raise_error;
363: end if;
364: --
357: elsif p_calc_rule_code = 'NTG FLT' then
358: l_template_name := 'Net To Gross Earning';
359: else
360: hr_utility.set_location('pay_ca_user_init_earn.get_template_id',2);
361: hr_utility.set_message(801,'HR_XXXXX_INVALID_CALC_RULE_EARN');
362: hr_utility.raise_error;
363: end if;
364: --
365: hr_utility.set_location('pay_ca_user_init_earn.get_template_id',3);
358: l_template_name := 'Net To Gross Earning';
359: else
360: hr_utility.set_location('pay_ca_user_init_earn.get_template_id',2);
361: hr_utility.set_message(801,'HR_XXXXX_INVALID_CALC_RULE_EARN');
362: hr_utility.raise_error;
363: end if;
364: --
365: hr_utility.set_location('pay_ca_user_init_earn.get_template_id',3);
366: hr_utility.trace('Template Name is :'||l_template_name||'****'||
361: hr_utility.set_message(801,'HR_XXXXX_INVALID_CALC_RULE_EARN');
362: hr_utility.raise_error;
363: end if;
364: --
365: hr_utility.set_location('pay_ca_user_init_earn.get_template_id',3);
366: hr_utility.trace('Template Name is :'||l_template_name||'****'||
367: 'Legislation is :'||p_legislation_code);
368: --
369: select template_id
362: hr_utility.raise_error;
363: end if;
364: --
365: hr_utility.set_location('pay_ca_user_init_earn.get_template_id',3);
366: hr_utility.trace('Template Name is :'||l_template_name||'****'||
367: 'Legislation is :'||p_legislation_code);
368: --
369: select template_id
370: into l_template_id
373: and legislation_code = p_legislation_code
374: and business_group_id is NULL
375: and template_type = 'T';
376: --
377: hr_utility.set_location('pay_ca_user_init_earn.get_template_id',4);
378: --
379: RETURN l_template_id;
380: --
381: END get_template_id;
390: l_installed VARCHAR2(1) := 'N';
391:
392: BEGIN
393: --
394: hr_utility.set_location('pay_ca_user_init_earn.chk_ca_pay_installed',1);
395: --
396: BEGIN
397: select 'Y'
398: into l_installed
404: l_installed := 'N';
405:
406: END;
407: --
408: hr_utility.set_location('pay_ca_user_init_earn.chk_ca_pay_installed',2);
409: --
410: RETURN (l_installed);
411: --
412: END chk_ca_pay_installed;
419:
420: BEGIN
421: --
422: --
423: --hr_utility.trace_on('y','ORACLE');
424:
425: --
426: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',1);
427: --
422: --
423: --hr_utility.trace_on('y','ORACLE');
424:
425: --
426: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',1);
427: --
428: -- Set session date
429: pay_db_pay_setup.set_session_date(nvl(p_ele_eff_start_date, sysdate));
430: --
430: --
431: g_eff_start_date := NVL(p_ele_eff_start_date, sysdate);
432: g_eff_end_date := NVL(p_ele_eff_end_date, c_end_of_time);
433: --
434: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',2);
435: --
436: ---------------------------- Check Element Name ---------------------------
437: --
438: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',25);
434: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',2);
435: --
436: ---------------------------- Check Element Name ---------------------------
437: --
438: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',25);
439: --
440: BEGIN
441: select 'Y'
442: into l_reserved
450:
451: END;
452: --
453: if l_reserved = 'Y' then
454: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',26);
455: hr_utility.set_message(801,'HR_7564_ALL_RES_WORDS');
456: hr_utility.raise_error;
457: end if;
458: --
451: END;
452: --
453: if l_reserved = 'Y' then
454: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',26);
455: hr_utility.set_message(801,'HR_7564_ALL_RES_WORDS');
456: hr_utility.raise_error;
457: end if;
458: --
459: ---------------------------- Get Source Template ID -----------------------
452: --
453: if l_reserved = 'Y' then
454: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',26);
455: hr_utility.set_message(801,'HR_7564_ALL_RES_WORDS');
456: hr_utility.raise_error;
457: end if;
458: --
459: ---------------------------- Get Source Template ID -----------------------
460: --
457: end if;
458: --
459: ---------------------------- Get Source Template ID -----------------------
460: --
461: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',3);
462: --
463: l_source_template_id := get_template_id(
464: p_legislation_code => g_template_leg_code,
465: p_calc_rule_code => p_ele_calc_rule_code);
465: p_calc_rule_code => p_ele_calc_rule_code);
466: --
467: --------------------- Set Separate Check Creation -------------------------
468: --
469: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',4);
470: --
471: if p_ele_classification = 'Supplemental Earnings' then
472: l_sep_check_create := 'Y';
473: l_skip_formula := 'SUPP_EARNINGS_SKIP';
477: end if;
478: --
479: ---------------------------- Create User Structure ------------------------
480: --
481: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',5);
482: --
483: -- The Configuration Flex segments are as follows:
484: -- Config 1 - exclusion rule - create Separate Check input value if 'Y'
485: -- Config 2 - input value default - update default value for Sep Check IV
513: ,p_object_version_number => l_object_version_number);
514: --
515: ---------------------- Get Element Type ID of new Template -----------------
516: --
517: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',6);
518: --
519: select element_type_id, object_version_number
520: into l_element_type_id, l_ele_obj_ver_number
521: from pay_shadow_element_types
542: end if;
543: --
544: ---------------------------- Update Shadow Structure ----------------------
545: --
546: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',7);
547: --
548: SELECT
549: DECODE(p_ele_classification,'Earnings','DE',
550: 'Supplemental Earnings','DE','Taxable Benefits','DE','')
595: --
596: -- Update user-specified Classification on Special Features Element.
597: -- Only for Non NTG elements.
598: --
599: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',8);
600: --
601: if p_ele_calc_rule_code <> 'NTG FLT' then
602: pay_shadow_element_api.update_shadow_element
603: (p_validate => false
614: --
615: -- Update user-specified Classification Special Inputs if it exists.
616: -- Only for Non NTG elements.
617: --
618: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',9);
619: --
620: if (p_ele_processing_type = 'R') and (p_ele_calc_rule_code <> 'NTG FLT') then
621: pay_shadow_element_api.update_shadow_element
622: (p_validate => false
628: end if;
629: --
630: ---------------------------- Generate Core Objects ------------------------
631: --
632: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',10);
633: --
634: if chk_ca_pay_installed = 'Y' then
635: l_hr_only := FALSE;
636: else
636: else
637: l_hr_only := TRUE;
638: end if;
639: --
640: hr_utility.trace('HR ONLY is :'||chk_ca_pay_installed);
641: --
642: pay_element_template_api.generate_part1
643: (p_validate => false
644: ,p_effective_date => p_ele_eff_start_date
645: ,p_hr_only => l_hr_only
646: ,p_hr_to_payroll => false
647: ,p_template_id => l_template_id);
648: --
649: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',11);
650: --
651: if l_hr_only = FALSE then
652: pay_element_template_api.generate_part2
653: (p_validate => false
653: (p_validate => false
654: ,p_effective_date => p_ele_eff_start_date
655: ,p_template_id => l_template_id);
656: --
657: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',12);
658: --
659: end if;
660: --
661: -------------------- Get Element Type ID of Base Element ------------------
659: end if;
660: --
661: -------------------- Get Element Type ID of Base Element ------------------
662: --
663: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',13);
664: --
665: select element_type_id
666: into l_base_element_type_id
667: from pay_element_types_f
677: fetch cur_processing_rule_exists INTO lv_proc_rule_id;
678: if cur_processing_rule_exists%found then
679: close cur_processing_rule_exists;
680: else
681: hr_utility.trace('Processing rule: '||p_ele_name|| ' does not exist');
682: end if;
683:
684: open cur_element_type_id(lv_element_name);
685: fetch cur_element_type_id into lv_element_type_id;
690: open cur_input_id(lv_element_name, lv_input_value_name);
691: fetch cur_input_id into lv_input_value_id;
692: close cur_input_id;
693:
694: hr_utility.trace(to_char(lv_element_type_id)||' '||to_char(lv_input_value_id));
695:
696: lv_formula_result_rule_id :=
697: pay_formula_results.ins_form_res_rule(
698: p_business_group_id => p_bg_id,
708: p_result_rule_type => 'I',
709: p_severity_level => NULL,
710: p_element_type_id => lv_element_type_id);
711:
712: hr_utility.trace('Creating Result Rule: '|| lv_result_name);
713:
714: lv_input_value_name := 'Hours';
715: lv_result_name := 'HOURS_PASSED';
716: open cur_input_id(lv_element_name, lv_input_value_name);
732: p_result_rule_type => 'I',
733: p_severity_level => NULL,
734: p_element_type_id => lv_element_type_id);
735:
736: hr_utility.trace('Creating Result Rule: '|| lv_result_name);
737:
738: lv_input_value_name := 'Rate';
739: lv_result_name := 'RATE_PASSED';
740: open cur_input_id(lv_element_name, lv_input_value_name);
756: p_result_rule_type => 'I',
757: p_severity_level => NULL,
758: p_element_type_id => lv_element_type_id);
759:
760: hr_utility.trace('Creating Result Rule: '|| lv_result_name);
761:
762: lv_input_value_name := 'Multiple';
763: lv_result_name := 'MULTIPLE_PASSED';
764: open cur_input_id(lv_element_name, lv_input_value_name);
802: p_result_rule_type => 'I',
803: p_severity_level => NULL,
804: p_element_type_id => lv_element_type_id);
805:
806: hr_utility.trace('Creating Result Rule: '|| lv_result_name);
807:
808: end if;
809: --
810: ------------------ Get Balance Type IDs to update Flex Info ---------------
808: end if;
809: --
810: ------------------ Get Balance Type IDs to update Flex Info ---------------
811: --
812: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',14);
813: --
814: BEGIN
815: select ptco.core_object_id
816: into l_pri_bal_id
836: NULL;
837: END IF;
838: END;
839: --
840: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',15);
841: --
842: BEGIN
843: select ptco.core_object_id
844: into l_hrs_bal_id
848: and psbt.balance_name = p_ele_name||' Hours'
849: and ptco.template_id = psbt.template_id
850: and ptco.shadow_object_id = psbt.balance_type_id;
851: --
852: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',16);
853: --
854: EXCEPTION WHEN NO_DATA_FOUND THEN NULL;
855: END;
856: --
853: --
854: EXCEPTION WHEN NO_DATA_FOUND THEN NULL;
855: END;
856: --
857: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',17);
858: --
859: if (p_sep_check_option = 'N' and p_ele_calc_rule_code <> 'NTG FLT') then
860: update pay_element_types_f
861: set element_information10 = l_pri_bal_id,
972: -- Creating element type usages for exclusion
973: --
974:
975: begin
976: --hr_utility.trace_on(null,'ELEMENT');
977: for etu in c_ele_tp_usg(p_bg_id, p_ele_name)
978: loop
979:
980: hr_utility.trace('etu.element_name : '||etu.element_name);
976: --hr_utility.trace_on(null,'ELEMENT');
977: for etu in c_ele_tp_usg(p_bg_id, p_ele_name)
978: loop
979:
980: hr_utility.trace('etu.element_name : '||etu.element_name);
981: hr_utility.trace('p_ele_name : '||p_ele_name);
982: hr_utility.trace('etu.element_information2 : '||etu.element_information2);
983: hr_utility.trace('etu.element_information4 : '||etu.element_information4);
984:
977: for etu in c_ele_tp_usg(p_bg_id, p_ele_name)
978: loop
979:
980: hr_utility.trace('etu.element_name : '||etu.element_name);
981: hr_utility.trace('p_ele_name : '||p_ele_name);
982: hr_utility.trace('etu.element_information2 : '||etu.element_information2);
983: hr_utility.trace('etu.element_information4 : '||etu.element_information4);
984:
985: if etu.element_name = p_ele_name then
978: loop
979:
980: hr_utility.trace('etu.element_name : '||etu.element_name);
981: hr_utility.trace('p_ele_name : '||p_ele_name);
982: hr_utility.trace('etu.element_information2 : '||etu.element_information2);
983: hr_utility.trace('etu.element_information4 : '||etu.element_information4);
984:
985: if etu.element_name = p_ele_name then
986:
979:
980: hr_utility.trace('etu.element_name : '||etu.element_name);
981: hr_utility.trace('p_ele_name : '||p_ele_name);
982: hr_utility.trace('etu.element_information2 : '||etu.element_information2);
983: hr_utility.trace('etu.element_information4 : '||etu.element_information4);
984:
985: if etu.element_name = p_ele_name then
986:
987: if p_ele_classification = 'Non-payroll Payments' then
1002: from dual;
1003: end if;
1004:
1005: end if;
1006: hr_utility.trace('ln_run_type_id : '||ln_run_type_id);
1007:
1008: for prt in c_run_tp
1009: loop
1010:
1042: begin
1043: /* Bugfix : 2851568. Feed Taxable Benefits for Quebec for all Taxable
1044: Benefits Element with Category PHSP */
1045:
1046: hr_utility.trace('1 element type id is '||to_char(l_element_type_id));
1047:
1048: select element_type_id
1049: into l_element_type_id
1050: from pay_element_types_f
1055: open cur_input_id2(l_base_element_type_id, lv_input_value_name);
1056: fetch cur_input_id2 into l_pay_value_iv_id;
1057: close cur_input_id2;
1058:
1059: hr_utility.trace('2');
1060: -- if p_ele_category = 'Private Health Services Plan' then
1061: if p_ele_category = 'PHSP' then
1062: hr_utility.trace('3 input value id ' || to_char(l_pay_value_iv_id));
1063:
1058:
1059: hr_utility.trace('2');
1060: -- if p_ele_category = 'Private Health Services Plan' then
1061: if p_ele_category = 'PHSP' then
1062: hr_utility.trace('3 input value id ' || to_char(l_pay_value_iv_id));
1063:
1064:
1065: select balance_type_id
1066: into l_balance_type_id
1077: l_pay_value_iv_id,
1078: '1',
1079: NULL);
1080:
1081: hr_utility.trace('4 input value id ' || to_char(l_balance_feed_id));
1082: end if;
1083: exception
1084: when others then
1085: hr_utility.trace('5');
1081: hr_utility.trace('4 input value id ' || to_char(l_balance_feed_id));
1082: end if;
1083: exception
1084: when others then
1085: hr_utility.trace('5');
1086: null;
1087: end;
1088: hr_utility.trace_off;
1089: --
1084: when others then
1085: hr_utility.trace('5');
1086: null;
1087: end;
1088: hr_utility.trace_off;
1089: --
1090: --
1091:
1092: ------------------ Conclude Create_User_Init_Earning Main -----------------
1090: --
1091:
1092: ------------------ Conclude Create_User_Init_Earning Main -----------------
1093: --
1094: hr_utility.set_location('pay_ca_user_init_earn.create_user_init_earning',18);
1095: --
1096: RETURN l_base_element_type_id;
1097: --
1098: END create_user_init_earning;
1122: l_del_val_end := nvl(p_del_val_end_date, c_end_of_time);
1123: l_del_val_start := nvl(p_del_val_start_date, sysdate);
1124: l_del_sess_date := nvl(p_del_sess_date, sysdate);
1125: --
1126: hr_utility.set_location('pay_ca_user_init_earn.delete_user_init_earning',1);
1127: --
1128: select template_id
1129: into l_template_id
1130: from pay_element_templates
1131: where base_name = p_ele_name
1132: and business_group_id = p_business_group_id
1133: and template_type = 'U';
1134: --
1135: hr_utility.set_location('pay_ca_user_init_earn.delete_user_init_earning',2);
1136: --
1137: begin
1138: delete from pay_element_type_usages_f
1139: where element_type_id in ( select element_type_id
1142: element_name =
1143: p_ele_name ||' Special Inputs' )
1144: and business_group_id = p_business_group_id );
1145: --
1146: hr_utility.set_location('pay_ca_user_init_earn.delete_user_init_earning',3);
1147: --
1148: exception
1149: when others then
1150: null;
1154: (p_validate => false
1155: ,p_drop_formula_packages => true
1156: ,p_template_id => l_template_id);
1157: --
1158: hr_utility.set_location('pay_ca_user_init_earn.delete_user_init_earning',4);
1159: --
1160: END delete_user_init_earning;
1161: ------------------------------------------------------------------------
1162: -- PROCEDURE UPDATE_JD_LEVEL_ON_BALANCE
1235: --
1236: OPEN c_iter_formula_id;
1237: FETCH c_iter_formula_id into l_iter_formula_id;
1238: IF c_iter_formula_id%NOTFOUND then
1239: hr_utility.set_location(l_proc,10);
1240: hr_utility.set_message(800,'ITERATIVE FORMULA NOT FOUND');
1241: hr_utility.raise_error;
1242: END IF;
1243: CLOSE c_iter_formula_id;
1236: OPEN c_iter_formula_id;
1237: FETCH c_iter_formula_id into l_iter_formula_id;
1238: IF c_iter_formula_id%NOTFOUND then
1239: hr_utility.set_location(l_proc,10);
1240: hr_utility.set_message(800,'ITERATIVE FORMULA NOT FOUND');
1241: hr_utility.raise_error;
1242: END IF;
1243: CLOSE c_iter_formula_id;
1244: -------------------------
1237: FETCH c_iter_formula_id into l_iter_formula_id;
1238: IF c_iter_formula_id%NOTFOUND then
1239: hr_utility.set_location(l_proc,10);
1240: hr_utility.set_message(800,'ITERATIVE FORMULA NOT FOUND');
1241: hr_utility.raise_error;
1242: END IF;
1243: CLOSE c_iter_formula_id;
1244: -------------------------
1245: -- Set iterative formula.
1250: grossup_flag = 'Y'
1251: WHERE element_type_id = p_base_element_type_id
1252: AND business_group_id + 0 = p_bg_id;
1253: --
1254: hr_utility.set_location(l_proc,20);
1255: --
1256: ---------------------------------
1257: -- Set iterative processing rules
1258: ---------------------------------
1288: l_iv_id := NULL;
1289: l_insert := 'Y';
1290: END IF;
1291: IF l_insert = 'Y' THEN
1292: hr_utility.set_location(l_proc,30);
1293: pay_iterative_rules_api.create_iterative_rule
1294: (
1295: p_effective_date => p_ele_eff_start_date
1296: ,p_element_type_id => p_base_element_type_id
1313: -- FED_GROSSUP_ADJUSTMENT input value of Amount.
1314: -- Thus need to get the element_type_id of the seeded element
1315: -- and input_value_id of the Amount from the seeded element.
1316: ------------------------------------------------------------------
1317: hr_utility.set_location(l_proc,40);
1318: --
1319: OPEN c_seeded_elmt_id;
1320: FETCH c_seeded_elmt_id into l_seeded_ele_type_id;
1321: IF c_seeded_elmt_id%NOTFOUND then
1318: --
1319: OPEN c_seeded_elmt_id;
1320: FETCH c_seeded_elmt_id into l_seeded_ele_type_id;
1321: IF c_seeded_elmt_id%NOTFOUND then
1322: hr_utility.set_location(l_proc,45);
1323: hr_utility.set_message(800,'FED_GROSSUP_ADJUSTMENT NOT FOUND');
1324: hr_utility.raise_error;
1325: END IF;
1326: CLOSE c_seeded_elmt_id;
1319: OPEN c_seeded_elmt_id;
1320: FETCH c_seeded_elmt_id into l_seeded_ele_type_id;
1321: IF c_seeded_elmt_id%NOTFOUND then
1322: hr_utility.set_location(l_proc,45);
1323: hr_utility.set_message(800,'FED_GROSSUP_ADJUSTMENT NOT FOUND');
1324: hr_utility.raise_error;
1325: END IF;
1326: CLOSE c_seeded_elmt_id;
1327: --
1320: FETCH c_seeded_elmt_id into l_seeded_ele_type_id;
1321: IF c_seeded_elmt_id%NOTFOUND then
1322: hr_utility.set_location(l_proc,45);
1323: hr_utility.set_message(800,'FED_GROSSUP_ADJUSTMENT NOT FOUND');
1324: hr_utility.raise_error;
1325: END IF;
1326: CLOSE c_seeded_elmt_id;
1327: --
1328: hr_utility.set_location(l_proc,41);
1324: hr_utility.raise_error;
1325: END IF;
1326: CLOSE c_seeded_elmt_id;
1327: --
1328: hr_utility.set_location(l_proc,41);
1329: --
1330: OPEN c_seeded_elmt_iv_id(l_seeded_ele_type_id);
1331: FETCH c_seeded_elmt_iv_id into l_seeded_input_val_id;
1332: IF c_seeded_elmt_iv_id%NOTFOUND then
1329: --
1330: OPEN c_seeded_elmt_iv_id(l_seeded_ele_type_id);
1331: FETCH c_seeded_elmt_iv_id into l_seeded_input_val_id;
1332: IF c_seeded_elmt_iv_id%NOTFOUND then
1333: hr_utility.set_location(l_proc,47);
1334: hr_utility.set_message(800,'INPUT VALUE NOT FOUND');
1335: hr_utility.raise_error;
1336: END IF;
1337: CLOSE c_seeded_elmt_iv_id;
1330: OPEN c_seeded_elmt_iv_id(l_seeded_ele_type_id);
1331: FETCH c_seeded_elmt_iv_id into l_seeded_input_val_id;
1332: IF c_seeded_elmt_iv_id%NOTFOUND then
1333: hr_utility.set_location(l_proc,47);
1334: hr_utility.set_message(800,'INPUT VALUE NOT FOUND');
1335: hr_utility.raise_error;
1336: END IF;
1337: CLOSE c_seeded_elmt_iv_id;
1338: --
1331: FETCH c_seeded_elmt_iv_id into l_seeded_input_val_id;
1332: IF c_seeded_elmt_iv_id%NOTFOUND then
1333: hr_utility.set_location(l_proc,47);
1334: hr_utility.set_message(800,'INPUT VALUE NOT FOUND');
1335: hr_utility.raise_error;
1336: END IF;
1337: CLOSE c_seeded_elmt_iv_id;
1338: --
1339: hr_utility.set_location(l_proc,42);
1335: hr_utility.raise_error;
1336: END IF;
1337: CLOSE c_seeded_elmt_iv_id;
1338: --
1339: hr_utility.set_location(l_proc,42);
1340: --
1341: SELECT pay_formula_result_rules_s.nextval
1342: INTO l_nextval
1343: FROM dual;
1341: SELECT pay_formula_result_rules_s.nextval
1342: INTO l_nextval
1343: FROM dual;
1344: --
1345: hr_utility.set_location(l_proc,43);
1346: --
1347: OPEN c_base_elmt_spr_id;
1348: FETCH c_base_elmt_spr_id into l_status_pro_rule_id;
1349: IF c_base_elmt_spr_id%NOTFOUND then
1346: --
1347: OPEN c_base_elmt_spr_id;
1348: FETCH c_base_elmt_spr_id into l_status_pro_rule_id;
1349: IF c_base_elmt_spr_id%NOTFOUND then
1350: hr_utility.set_location(l_proc,49);
1351: hr_utility.set_message(800,'STATUS PROC RULE NOT FOUND');
1352: hr_utility.raise_error;
1353: END IF;
1354: CLOSE c_base_elmt_spr_id;
1347: OPEN c_base_elmt_spr_id;
1348: FETCH c_base_elmt_spr_id into l_status_pro_rule_id;
1349: IF c_base_elmt_spr_id%NOTFOUND then
1350: hr_utility.set_location(l_proc,49);
1351: hr_utility.set_message(800,'STATUS PROC RULE NOT FOUND');
1352: hr_utility.raise_error;
1353: END IF;
1354: CLOSE c_base_elmt_spr_id;
1355: --
1348: FETCH c_base_elmt_spr_id into l_status_pro_rule_id;
1349: IF c_base_elmt_spr_id%NOTFOUND then
1350: hr_utility.set_location(l_proc,49);
1351: hr_utility.set_message(800,'STATUS PROC RULE NOT FOUND');
1352: hr_utility.raise_error;
1353: END IF;
1354: CLOSE c_base_elmt_spr_id;
1355: --
1356: hr_utility.set_location(l_proc,50);
1352: hr_utility.raise_error;
1353: END IF;
1354: CLOSE c_base_elmt_spr_id;
1355: --
1356: hr_utility.set_location(l_proc,50);
1357: --
1358: INSERT INTO PAY_FORMULA_RESULT_RULES_F
1359: (formula_result_rule_id,
1360: effective_start_date,