39: * 05 Nov 1998 Hugh Dang 115.9 Change call to get_parameters.
40: * 01 Dec 1998 Hugh Dang 115.10 Remove p_mode_cd check.
41: * 02 Dec 1998 Hugh Dang 115.11 Change logic how to handle report/log,
42: * and common procedures/Function into
43: * ben_batch_utils package.
44: * 11 Dec 1998 S Tee 115.12 Added the per_in_ler_id to process
45: * common enrollment result procedure.
46: * 20-Dec-1998 Hdang 115.13 Added audit_log to turn audit log report
47: * on and off.
218:
219:
220: l_proc varchar2(80) := g_package||'.write_person_category';
221: l_actn varchar2(80);
222: l_cache ben_batch_utils.g_comp_obj_table := ben_batch_utils.g_cache_comp;
223: l_cache_cnt binary_integer := ben_batch_utils.g_cache_comp_cnt;
224: l_category varchar2(30):= 'DEFNOCHG';
225: l_detail varchar2(132) := 'Default election asigned -- no current elections changed' ;
226: l_OVN Number;
219:
220: l_proc varchar2(80) := g_package||'.write_person_category';
221: l_actn varchar2(80);
222: l_cache ben_batch_utils.g_comp_obj_table := ben_batch_utils.g_cache_comp;
223: l_cache_cnt binary_integer := ben_batch_utils.g_cache_comp_cnt;
224: l_category varchar2(30):= 'DEFNOCHG';
225: l_detail varchar2(132) := 'Default election asigned -- no current elections changed' ;
226: l_OVN Number;
227: l_id Number;
234: If (p_audit_log = 'Y') then
235: l_category := 'ERROR_C';
236: l_detail := 'Error occur while defaulting enrollment';
237: --
238: l_actn := 'Calling ben_batch_utils.write_rec (ERROR)...';
239: Ben_batch_utils.write_rec(p_typ_cd => l_category ,p_text => l_detail);
240: End if;
241: Else
242: For i in 1..l_cache_cnt Loop
235: l_category := 'ERROR_C';
236: l_detail := 'Error occur while defaulting enrollment';
237: --
238: l_actn := 'Calling ben_batch_utils.write_rec (ERROR)...';
239: Ben_batch_utils.write_rec(p_typ_cd => l_category ,p_text => l_detail);
240: End if;
241: Else
242: For i in 1..l_cache_cnt Loop
243: If (l_cache(i).upd_flag or l_cache(i).ins_flag or l_cache(i).del_flag) then
246: exit;
247: End if;
248: End loop;
249: --
250: l_actn := 'Calling ben_batch_utils.write_rec (DEFAULT)...';
251: Ben_batch_utils.write_rec(p_typ_cd => l_category,p_text => l_detail);
252: End if;
253: If (p_audit_log = 'Y') then
254: For i in 1..l_cache_cnt Loop
247: End if;
248: End loop;
249: --
250: l_actn := 'Calling ben_batch_utils.write_rec (DEFAULT)...';
251: Ben_batch_utils.write_rec(p_typ_cd => l_category,p_text => l_detail);
252: End if;
253: If (p_audit_log = 'Y') then
254: For i in 1..l_cache_cnt Loop
255: If (l_cache(i).del_flag) then
327: End if;
328: hr_utility.set_location ('Leaving '||l_proc,10);
329: Exception
330: When others then
331: ben_batch_utils.rpt_error(p_proc => l_proc
332: ,p_last_actn => l_actn
333: ,p_rpt_flag => TRUE
334: );
335: raise;
335: raise;
336: End write_person_category;
337: --
338: -- ===========================================================================
339: -- << Procedure: ben_batch_utils.batch_report >>
340: -- ===========================================================================
341: --
342: Procedure Submit_all_reports
343: (p_rpt_flag in Boolean default FALSE
348: l_request_id number;
349: Begin
350: hr_utility.set_location ('Entering '||l_proc,05);
351: If fnd_global.conc_request_id <> -1 then
352: l_actn := 'Calling ben_batch_utils.batch_report (BENDFAUD)...';
353: If (p_audit_log = 'Y') then
354: ben_batch_utils.batch_report
355: (p_concurrent_request_id => fnd_global.conc_request_id
356: ,p_program_name => 'BENDFAUD'
350: hr_utility.set_location ('Entering '||l_proc,05);
351: If fnd_global.conc_request_id <> -1 then
352: l_actn := 'Calling ben_batch_utils.batch_report (BENDFAUD)...';
353: If (p_audit_log = 'Y') then
354: ben_batch_utils.batch_report
355: (p_concurrent_request_id => fnd_global.conc_request_id
356: ,p_program_name => 'BENDFAUD'
357: ,p_request_id => l_request_id
358: );
356: ,p_program_name => 'BENDFAUD'
357: ,p_request_id => l_request_id
358: );
359: End if;
360: l_actn := 'Calling ben_batch_utils.batch_report (BENDFSUM)...';
361: ben_batch_utils.batch_report
362: (p_concurrent_request_id => fnd_global.conc_request_id
363: ,p_program_name => 'BENDFSUM'
364: ,p_request_id => l_request_id
357: ,p_request_id => l_request_id
358: );
359: End if;
360: l_actn := 'Calling ben_batch_utils.batch_report (BENDFSUM)...';
361: ben_batch_utils.batch_report
362: (p_concurrent_request_id => fnd_global.conc_request_id
363: ,p_program_name => 'BENDFSUM'
364: ,p_request_id => l_request_id
365: );
362: (p_concurrent_request_id => fnd_global.conc_request_id
363: ,p_program_name => 'BENDFSUM'
364: ,p_request_id => l_request_id
365: );
366: l_actn := 'Calling ben_batch_utils.batch_report (BENERTYP)...';
367: ben_batch_utils.batch_report
368: (p_concurrent_request_id => fnd_global.conc_request_id
369: ,p_program_name => 'BENERTYP'
370: ,p_request_id => l_request_id
363: ,p_program_name => 'BENDFSUM'
364: ,p_request_id => l_request_id
365: );
366: l_actn := 'Calling ben_batch_utils.batch_report (BENERTYP)...';
367: ben_batch_utils.batch_report
368: (p_concurrent_request_id => fnd_global.conc_request_id
369: ,p_program_name => 'BENERTYP'
370: ,p_request_id => l_request_id
371: ,p_subtitle =>
370: ,p_request_id => l_request_id
371: ,p_subtitle =>
372: 'ERROR DETAIL BY ERROR TYPE'
373: );
374: l_actn := 'Calling ben_batch_utils.batch_report (BENERPER)...';
375: ben_batch_utils.batch_report
376: (p_concurrent_request_id => fnd_global.conc_request_id
377: ,p_program_name => 'BENERPER'
378: ,p_request_id => l_request_id
371: ,p_subtitle =>
372: 'ERROR DETAIL BY ERROR TYPE'
373: );
374: l_actn := 'Calling ben_batch_utils.batch_report (BENERPER)...';
375: ben_batch_utils.batch_report
376: (p_concurrent_request_id => fnd_global.conc_request_id
377: ,p_program_name => 'BENERPER'
378: ,p_request_id => l_request_id
379: ,p_subtitle =>
382: End if;
383: hr_utility.set_location ('Leaving '||l_proc,10);
384: Exception
385: When others then
386: ben_batch_utils.rpt_error(p_proc => l_proc
387: ,p_last_actn => l_actn
388: ,p_rpt_flag => p_rpt_flag
389: );
390: raise;
483: p_threads => l_threads,
484: p_max_errors => g_max_errors_allowed,
485: p_benefit_action_id => p_benefit_action_id);
486: --
487: l_actn := 'Calling ben_batch_utils.ini...';
488: ben_batch_utils.ini;
489: --
490: -- Copy benefit action id to global in benutils package
491: --
484: p_max_errors => g_max_errors_allowed,
485: p_benefit_action_id => p_benefit_action_id);
486: --
487: l_actn := 'Calling ben_batch_utils.ini...';
488: ben_batch_utils.ini;
489: --
490: -- Copy benefit action id to global in benutils package
491: --
492: benutils.g_benefit_action_id := p_benefit_action_id;
496: open c_parameter;
497: fetch c_parameter into l_parm;
498: close c_parameter;
499: --
500: l_actn := 'Calling ben_batch_utils.print_parameters...';
501: --
502: ben_batch_utils.print_parameters
503: (p_thread_id => p_thread_id
504: ,p_benefit_action_id => p_benefit_action_id
498: close c_parameter;
499: --
500: l_actn := 'Calling ben_batch_utils.print_parameters...';
501: --
502: ben_batch_utils.print_parameters
503: (p_thread_id => p_thread_id
504: ,p_benefit_action_id => p_benefit_action_id
505: ,p_validate => p_validate
506: ,p_business_group_id => p_business_group_id
603: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
604: commit;
605: --
606: l_actn := 'Calling Log_beneadeb_statistics...';
607: ben_batch_utils.write_logfile(p_num_pers_processed => g_persons_procd
608: ,p_num_pers_errored => g_persons_errored
609: );
610: hr_utility.set_location ('Leaving '||l_proc,70);
611: Exception
609: );
610: hr_utility.set_location ('Leaving '||l_proc,70);
611: Exception
612: When others then
613: ben_batch_utils.rpt_error(p_proc => l_proc
614: ,p_last_actn => l_actn
615: ,p_rpt_flag => TRUE
616: );
617: ben_batch_utils.write_logfile(p_num_pers_processed => g_persons_procd
613: ben_batch_utils.rpt_error(p_proc => l_proc
614: ,p_last_actn => l_actn
615: ,p_rpt_flag => TRUE
616: );
617: ben_batch_utils.write_logfile(p_num_pers_processed => g_persons_procd
618: ,p_num_pers_errored => g_persons_errored
619: );
620: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
621: commit;
674: l_actn := 'Getting parameter data...';
675: open c_parameters;
676: fetch c_parameters into l_parameters;
677: If c_parameters%notfound then
678: ben_batch_utils.rpt_error(p_proc => l_proc
679: ,p_last_actn => l_actn
680: ,p_rpt_flag => TRUE
681: );
682: fnd_message.set_name('BEN','BEN_91710_RESTRT_PARMS_NOT_FND');
708: );
709: hr_utility.set_location ('Leaving '||l_proc,70);
710: Exception
711: when others then
712: ben_batch_utils.rpt_error(p_proc => l_proc
713: ,p_last_actn => l_actn
714: ,p_rpt_flag => TRUE
715: );
716: raise;
894: --
895: hr_utility.set_location ('Entering '||l_proc,10);
896: -- Bug 5857493
897: if p_audit_log ='Y' then
898: ben_batch_utils.g_audit_flag := true;
899: else
900: ben_batch_utils.g_audit_flag := false;
901: end if;
902: --
896: -- Bug 5857493
897: if p_audit_log ='Y' then
898: ben_batch_utils.g_audit_flag := true;
899: else
900: ben_batch_utils.g_audit_flag := false;
901: end if;
902: --
903: l_effective_date := fnd_date.canonical_to_date(p_effective_date);
904: --
907: dt_fndate.change_ses_date
908: (p_ses_date => l_effective_date,
909: p_commit => l_commit);
910: --
911: l_actn := 'Initialize the ben_batch_utils cache...';
912: --
913: ben_batch_utils.ini(p_actn_cd => 'PROC_INFO');
914: --
915: -- Get chunk_size and Thread values for multi-thread process, and check to
909: p_commit => l_commit);
910: --
911: l_actn := 'Initialize the ben_batch_utils cache...';
912: --
913: ben_batch_utils.ini(p_actn_cd => 'PROC_INFO');
914: --
915: -- Get chunk_size and Thread values for multi-thread process, and check to
916: --
917: l_actn := 'Calling benutils.get_parameter...';
985: l_skip := FALSE;
986: --
987: if p_person_selection_rule_id is not null then
988: --
989: l_actn := 'Calling Ben_batch_utils.person_selection_rule...';
990: l_rule_value :=
991: ben_batch_utils.person_selection_rule
992: (p_person_id => l_person_id_out
993: ,p_business_group_id => p_business_group_id
987: if p_person_selection_rule_id is not null then
988: --
989: l_actn := 'Calling Ben_batch_utils.person_selection_rule...';
990: l_rule_value :=
991: ben_batch_utils.person_selection_rule
992: (p_person_id => l_person_id_out
993: ,p_business_group_id => p_business_group_id
994: ,p_person_selection_rule_id=> p_person_selection_rule_id
995: ,p_effective_date => l_effective_date);
1158: --
1159: Else
1160: --
1161: l_benefit_action_id := p_benefit_action_id;
1162: l_actn := 'Calling Ben_batch_utils.create_restart_person_actions...';
1163: --
1164: Ben_batch_utils.create_restart_person_actions
1165: (p_benefit_action_id => p_benefit_action_id
1166: ,p_effective_date => l_effective_date
1160: --
1161: l_benefit_action_id := p_benefit_action_id;
1162: l_actn := 'Calling Ben_batch_utils.create_restart_person_actions...';
1163: --
1164: Ben_batch_utils.create_restart_person_actions
1165: (p_benefit_action_id => p_benefit_action_id
1166: ,p_effective_date => l_effective_date
1167: ,p_chunk_size => l_chunk_size
1168: ,p_threads => l_threads
1193: ,argument6 => p_audit_log);
1194: --
1195: -- Store the request id of the concurrent request
1196: --
1197: ben_batch_utils.g_num_processes := ben_batch_utils.g_num_processes + 1;
1198: ben_batch_utils.g_processes_tbl(ben_batch_utils.g_num_processes)
1199: := l_request_id;
1200: --
1201: commit;
1194: --
1195: -- Store the request id of the concurrent request
1196: --
1197: ben_batch_utils.g_num_processes := ben_batch_utils.g_num_processes + 1;
1198: ben_batch_utils.g_processes_tbl(ben_batch_utils.g_num_processes)
1199: := l_request_id;
1200: --
1201: commit;
1202: --
1203: End loop;
1204: --
1205: Elsif (l_num_ranges = 0 ) then
1206: --
1207: l_actn := 'Calling Ben_batch_utils.print_parameters...';
1208: --
1209: Ben_batch_utils.print_parameters
1210: (p_thread_id => 99
1211: ,p_benefit_action_id => l_benefit_action_id
1205: Elsif (l_num_ranges = 0 ) then
1206: --
1207: l_actn := 'Calling Ben_batch_utils.print_parameters...';
1208: --
1209: Ben_batch_utils.print_parameters
1210: (p_thread_id => 99
1211: ,p_benefit_action_id => l_benefit_action_id
1212: ,p_validate => p_validate
1213: ,p_business_group_id => p_business_group_id
1223: ,p_legal_entity_id => p_legal_entity_id
1224: ,p_payroll_id => p_payroll_id
1225: ,p_audit_log => p_audit_log);
1226: --
1227: Ben_batch_utils.write(p_text =>
1228: '<< No Person got selected with above selection criteria >>' );
1229: fnd_message.set_name('BEN','BEN_91769_NOONE_TO_PROCESS');
1230: fnd_message.set_token('PROC',l_proc);
1231: raise l_silent_error;
1242: ,p_effective_date => p_effective_date
1243: ,p_business_group_id => p_business_group_id
1244: ,p_audit_log => p_audit_log);
1245: --
1246: l_actn := 'Calling ben_batch_utils.check_all_slaves_finished...';
1247: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1248: --
1249: l_actn := 'Calling ben_batch_utils.End_process...';
1250: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1243: ,p_business_group_id => p_business_group_id
1244: ,p_audit_log => p_audit_log);
1245: --
1246: l_actn := 'Calling ben_batch_utils.check_all_slaves_finished...';
1247: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1248: --
1249: l_actn := 'Calling ben_batch_utils.End_process...';
1250: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1251: ,p_person_selected => l_num_persons
1245: --
1246: l_actn := 'Calling ben_batch_utils.check_all_slaves_finished...';
1247: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1248: --
1249: l_actn := 'Calling ben_batch_utils.End_process...';
1250: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1251: ,p_person_selected => l_num_persons
1252: ,p_business_group_id => p_business_group_id);
1253: --
1246: l_actn := 'Calling ben_batch_utils.check_all_slaves_finished...';
1247: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1248: --
1249: l_actn := 'Calling ben_batch_utils.End_process...';
1250: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1251: ,p_person_selected => l_num_persons
1252: ,p_business_group_id => p_business_group_id);
1253: --
1254: l_actn := 'Calling submit_all_reports...';
1258: --
1259: Exception
1260: --
1261: when l_silent_error then
1262: ben_batch_utils.write(p_text => fnd_message.get);
1263: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
1264: If (l_num_ranges > 0) then
1265: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1266: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1261: when l_silent_error then
1262: ben_batch_utils.write(p_text => fnd_message.get);
1263: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
1264: If (l_num_ranges > 0) then
1265: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1266: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1267: ,p_person_selected => l_num_persons
1268: ,p_business_group_id => p_business_group_id);
1269: submit_all_reports(p_audit_log => p_audit_log);
1262: ben_batch_utils.write(p_text => fnd_message.get);
1263: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
1264: If (l_num_ranges > 0) then
1265: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1266: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1267: ,p_person_selected => l_num_persons
1268: ,p_business_group_id => p_business_group_id);
1269: submit_all_reports(p_audit_log => p_audit_log);
1270: End if;
1269: submit_all_reports(p_audit_log => p_audit_log);
1270: End if;
1271: --
1272: when others then
1273: ben_batch_utils.rpt_error(p_proc => l_proc
1274: ,p_last_actn => l_actn
1275: ,p_rpt_flag => TRUE );
1276: ben_batch_utils.write(p_text => fnd_message.get);
1277: ben_batch_utils.write(p_text => sqlerrm);
1272: when others then
1273: ben_batch_utils.rpt_error(p_proc => l_proc
1274: ,p_last_actn => l_actn
1275: ,p_rpt_flag => TRUE );
1276: ben_batch_utils.write(p_text => fnd_message.get);
1277: ben_batch_utils.write(p_text => sqlerrm);
1278: ben_batch_utils.write(p_text => 'Big Error Occured');
1279: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
1280: If (l_num_ranges > 0) then
1273: ben_batch_utils.rpt_error(p_proc => l_proc
1274: ,p_last_actn => l_actn
1275: ,p_rpt_flag => TRUE );
1276: ben_batch_utils.write(p_text => fnd_message.get);
1277: ben_batch_utils.write(p_text => sqlerrm);
1278: ben_batch_utils.write(p_text => 'Big Error Occured');
1279: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
1280: If (l_num_ranges > 0) then
1281: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1274: ,p_last_actn => l_actn
1275: ,p_rpt_flag => TRUE );
1276: ben_batch_utils.write(p_text => fnd_message.get);
1277: ben_batch_utils.write(p_text => sqlerrm);
1278: ben_batch_utils.write(p_text => 'Big Error Occured');
1279: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
1280: If (l_num_ranges > 0) then
1281: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1282: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1277: ben_batch_utils.write(p_text => sqlerrm);
1278: ben_batch_utils.write(p_text => 'Big Error Occured');
1279: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
1280: If (l_num_ranges > 0) then
1281: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1282: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1283: ,p_person_selected => l_num_persons
1284: ,p_business_group_id => p_business_group_id);
1285: submit_all_reports(p_audit_log => p_audit_log);
1278: ben_batch_utils.write(p_text => 'Big Error Occured');
1279: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
1280: If (l_num_ranges > 0) then
1281: ben_batch_utils.check_all_slaves_finished(p_rpt_flag => TRUE);
1282: ben_batch_utils.end_process(p_benefit_action_id => l_benefit_action_id
1283: ,p_person_selected => l_num_persons
1284: ,p_business_group_id => p_business_group_id);
1285: submit_all_reports(p_audit_log => p_audit_log);
1286: End if;
1737: --
1738: End if;
1739: If (p_batch_flag) then
1740: --
1741: l_actn := 'Calling Ben_batch_utils.cache_comp_obj...';
1742: Ben_batch_utils.cache_comp_obj
1743: (p_prtt_enrt_rslt_id => l_epe(i).prtt_enrt_rslt_id
1744: ,p_effective_date => p_effective_date
1745: ,p_actn_cd => l_epe(i).actn_cd
1738: End if;
1739: If (p_batch_flag) then
1740: --
1741: l_actn := 'Calling Ben_batch_utils.cache_comp_obj...';
1742: Ben_batch_utils.cache_comp_obj
1743: (p_prtt_enrt_rslt_id => l_epe(i).prtt_enrt_rslt_id
1744: ,p_effective_date => p_effective_date
1745: ,p_actn_cd => l_epe(i).actn_cd
1746: ,p_suspended => l_epe(i).suspended);
1825: if p_batch_flag then
1826: --
1827: -- Update person action to errored as record has an error
1828: --
1829: -- ben_batch_utils.write(p_text => fnd_message.get);
1830: ben_batch_utils.write(p_text => sqlerrm);
1831: ben_batch_utils.rpt_error(p_proc => l_proc
1832: ,p_last_actn => l_actn
1833: ,p_rpt_flag => p_batch_flag
1826: --
1827: -- Update person action to errored as record has an error
1828: --
1829: -- ben_batch_utils.write(p_text => fnd_message.get);
1830: ben_batch_utils.write(p_text => sqlerrm);
1831: ben_batch_utils.rpt_error(p_proc => l_proc
1832: ,p_last_actn => l_actn
1833: ,p_rpt_flag => p_batch_flag
1834: );
1827: -- Update person action to errored as record has an error
1828: --
1829: -- ben_batch_utils.write(p_text => fnd_message.get);
1830: ben_batch_utils.write(p_text => sqlerrm);
1831: ben_batch_utils.rpt_error(p_proc => l_proc
1832: ,p_last_actn => l_actn
1833: ,p_rpt_flag => p_batch_flag
1834: );
1835: raise ben_batch_utils.g_record_error ;
1831: ben_batch_utils.rpt_error(p_proc => l_proc
1832: ,p_last_actn => l_actn
1833: ,p_rpt_flag => p_batch_flag
1834: );
1835: raise ben_batch_utils.g_record_error ;
1836: -- Added for Bug 2370264
1837: else
1838: hr_utility.set_location ('Error in Default_Comp_obj : '|| sqlerrm , 87);
1839: fnd_message.set_name('PER','FFU10_GENERAL_ORACLE_ERROR');
1929: Savepoint process_default_enrt_savepoint;
1930: --
1931: -- Cache person data and write personal data into cache.
1932: --
1933: l_actn := 'Calling ben_batch_utils.person_header...';
1934: ben_batch_utils.person_header
1935: (p_person_id => p_person_id
1936: ,p_business_group_id => p_business_group_id
1937: ,p_effective_date => p_effective_date
1930: --
1931: -- Cache person data and write personal data into cache.
1932: --
1933: l_actn := 'Calling ben_batch_utils.person_header...';
1934: ben_batch_utils.person_header
1935: (p_person_id => p_person_id
1936: ,p_business_group_id => p_business_group_id
1937: ,p_effective_date => p_effective_date
1938: );
1936: ,p_business_group_id => p_business_group_id
1937: ,p_effective_date => p_effective_date
1938: );
1939: --
1940: l_actn := 'Calling ben_batch_utils.ini(COMP_OBJ)...';
1941: ben_batch_utils.ini('COMP_OBJ');
1942: For l_rec in c_pel loop
1943: l_pel_cnt := l_pel_cnt + 1;
1944: l_per_in_ler_id:=l_rec.per_in_ler_id;
1937: ,p_effective_date => p_effective_date
1938: );
1939: --
1940: l_actn := 'Calling ben_batch_utils.ini(COMP_OBJ)...';
1941: ben_batch_utils.ini('COMP_OBJ');
1942: For l_rec in c_pel loop
1943: l_pel_cnt := l_pel_cnt + 1;
1944: l_per_in_ler_id:=l_rec.per_in_ler_id;
1945: l_ler_id := l_rec.ler_id;
2007: ,p_uneai_effective_date => p_effective_date
2008: );
2009: end if;
2010: --
2011: l_actn := 'Calling Ben_batch_utils.write_comp...';
2012: Ben_batch_utils.write_comp(p_business_group_id => p_business_group_id
2013: ,p_effective_date => p_effective_date
2014: );
2015: If (p_validate = 'Y') then
2008: );
2009: end if;
2010: --
2011: l_actn := 'Calling Ben_batch_utils.write_comp...';
2012: Ben_batch_utils.write_comp(p_business_group_id => p_business_group_id
2013: ,p_effective_date => p_effective_date
2014: );
2015: If (p_validate = 'Y') then
2016: Rollback to process_default_enrt_savepoint;
2060: Exception
2061: When others then
2062: rollback to process_default_enrt_savepoint;
2063: g_persons_errored := g_persons_errored + 1;
2064: ben_batch_utils.write_error_rec;
2065: ben_batch_utils.write(p_text => fnd_message.get);
2066: ben_batch_utils.write(p_text => sqlerrm);
2067: ben_batch_utils.rpt_error(p_proc => l_proc
2068: ,p_last_actn => l_actn
2061: When others then
2062: rollback to process_default_enrt_savepoint;
2063: g_persons_errored := g_persons_errored + 1;
2064: ben_batch_utils.write_error_rec;
2065: ben_batch_utils.write(p_text => fnd_message.get);
2066: ben_batch_utils.write(p_text => sqlerrm);
2067: ben_batch_utils.rpt_error(p_proc => l_proc
2068: ,p_last_actn => l_actn
2069: ,p_rpt_flag => TRUE);
2062: rollback to process_default_enrt_savepoint;
2063: g_persons_errored := g_persons_errored + 1;
2064: ben_batch_utils.write_error_rec;
2065: ben_batch_utils.write(p_text => fnd_message.get);
2066: ben_batch_utils.write(p_text => sqlerrm);
2067: ben_batch_utils.rpt_error(p_proc => l_proc
2068: ,p_last_actn => l_actn
2069: ,p_rpt_flag => TRUE);
2070: Ben_batch_utils.write_comp(p_business_group_id => p_business_group_id
2063: g_persons_errored := g_persons_errored + 1;
2064: ben_batch_utils.write_error_rec;
2065: ben_batch_utils.write(p_text => fnd_message.get);
2066: ben_batch_utils.write(p_text => sqlerrm);
2067: ben_batch_utils.rpt_error(p_proc => l_proc
2068: ,p_last_actn => l_actn
2069: ,p_rpt_flag => TRUE);
2070: Ben_batch_utils.write_comp(p_business_group_id => p_business_group_id
2071: ,p_effective_date => p_effective_date
2066: ben_batch_utils.write(p_text => sqlerrm);
2067: ben_batch_utils.rpt_error(p_proc => l_proc
2068: ,p_last_actn => l_actn
2069: ,p_rpt_flag => TRUE);
2070: Ben_batch_utils.write_comp(p_business_group_id => p_business_group_id
2071: ,p_effective_date => p_effective_date
2072: );
2073: If p_person_action_id is not null then
2074: ben_person_actions_api.update_person_actions
2084: ,p_business_group_id => p_business_group_id
2085: ,p_effective_date => p_effective_date
2086: );
2087: benutils.write_table_and_file(p_table => TRUE, p_file => TRUE);
2088: raise ben_batch_utils.g_record_error;
2089: end process_default_enrt;
2090:
2091: -- ============================================================================
2092: -- << Procedure: Default_comp_obj_w >>