719: end if;
720:
721: l_form := 'WNU ( WNU '||p_wnu_version||' )';
722:
723: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
724: fnd_file.put_line(fnd_file.output,' ');
725: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
726: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
727: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
720:
721: l_form := 'WNU ( WNU '||p_wnu_version||' )';
722:
723: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
724: fnd_file.put_line(fnd_file.output,' ');
725: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
726: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
727: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
728: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
721: l_form := 'WNU ( WNU '||p_wnu_version||' )';
722:
723: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
724: fnd_file.put_line(fnd_file.output,' ');
725: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
726: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
727: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
728: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
729: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
722:
723: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
724: fnd_file.put_line(fnd_file.output,' ');
725: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
726: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
727: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
728: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
729: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
730: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
723: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
724: fnd_file.put_line(fnd_file.output,' ');
725: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
726: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
727: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
728: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
729: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
730: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
731: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
724: fnd_file.put_line(fnd_file.output,' ');
725: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
726: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
727: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
728: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
729: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
730: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
731: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
732: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
725: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
726: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
727: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
728: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
729: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
730: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
731: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
732: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
733: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
726: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
727: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
728: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
729: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
730: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
731: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
732: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
733: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
734: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
727: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
728: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
729: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
730: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
731: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
732: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
733: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
734: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
735: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
728: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
729: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
730: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
731: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
732: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
733: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
734: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
735: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
736: if length(l_addr2) > 0 then
729: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
730: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
731: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
732: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
733: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
734: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
735: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
736: if length(l_addr2) > 0 then
737: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
730: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
731: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
732: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
733: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
734: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
735: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
736: if length(l_addr2) > 0 then
737: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
738: end if;
731: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
732: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
733: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
734: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
735: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
736: if length(l_addr2) > 0 then
737: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
738: end if;
739: if length(l_addr3) > 0 then
733: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
734: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
735: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
736: if length(l_addr2) > 0 then
737: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
738: end if;
739: if length(l_addr3) > 0 then
740: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr3);
741: end if;
736: if length(l_addr2) > 0 then
737: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
738: end if;
739: if length(l_addr3) > 0 then
740: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr3);
741: end if;
742: if length(l_addr4) > 0 then
743: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr4);
744: end if;
739: if length(l_addr3) > 0 then
740: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr3);
741: end if;
742: if length(l_addr4) > 0 then
743: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr4);
744: end if;
745: end write_header;
746:
747: procedure write_sub_header(p_type varchar2 , p_wnu_version VARCHAR2) is
746:
747: procedure write_sub_header(p_type varchar2 , p_wnu_version VARCHAR2) is
748:
749: begin
750: fnd_file.put_line(fnd_file.output,null);
751: if p_type = 'E' then
752: fnd_file.put_line(fnd_file.output,'The following assignments have completed with error');
753: else
754: fnd_file.put_line(fnd_file.output,'The following assignments have completed successfully');
748:
749: begin
750: fnd_file.put_line(fnd_file.output,null);
751: if p_type = 'E' then
752: fnd_file.put_line(fnd_file.output,'The following assignments have completed with error');
753: else
754: fnd_file.put_line(fnd_file.output,'The following assignments have completed successfully');
755: end if;
756: -- Bug 5398360
750: fnd_file.put_line(fnd_file.output,null);
751: if p_type = 'E' then
752: fnd_file.put_line(fnd_file.output,'The following assignments have completed with error');
753: else
754: fnd_file.put_line(fnd_file.output,'The following assignments have completed successfully');
755: end if;
756: -- Bug 5398360
757:
758: IF p_wnu_version = '1.0' THEN
755: end if;
756: -- Bug 5398360
757:
758: IF p_wnu_version = '1.0' THEN
759: fnd_file.put_line(fnd_file.output,rpad('Assignment Number',19) ||
760: rpad('NI Number',11) ||
761: rpad('Employee Name', 50));
762: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
763: rpad('-',10,'-') || ' ' ||
758: IF p_wnu_version = '1.0' THEN
759: fnd_file.put_line(fnd_file.output,rpad('Assignment Number',19) ||
760: rpad('NI Number',11) ||
761: rpad('Employee Name', 50));
762: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
763: rpad('-',10,'-') || ' ' ||
764: rpad('-',50,'-'));
765: ELSE
766: fnd_file.put_line(fnd_file.output,rpad('Works Number',19) ||
762: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
763: rpad('-',10,'-') || ' ' ||
764: rpad('-',50,'-'));
765: ELSE
766: fnd_file.put_line(fnd_file.output,rpad('Works Number',19) ||
767: rpad('NI Number',11) ||
768: rpad('Employee Name', 51)||
769: rpad('Old Works Number',18) ) ;
770: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
766: fnd_file.put_line(fnd_file.output,rpad('Works Number',19) ||
767: rpad('NI Number',11) ||
768: rpad('Employee Name', 51)||
769: rpad('Old Works Number',18) ) ;
770: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
771: rpad('-',10,'-') || ' ' ||
772: rpad('-',50,'-')|| ' ' ||
773: rpad('-',18,'-') );
774:
813: l_ni := asg_rec.ni_no;
814: if l_ni is null then
815: l_ni := '-MISSING-';
816: end if;
817: fnd_file.put_line(fnd_file.output,rpad(asg_rec.emp_no, 18) || ' ' ||
818: rpad(l_ni ,10) || ' ' ||
819: rpad(l_temp,50));
820: l_count := l_count + 1;
821: end loop;
826: l_ni := asg_rec.ni_no;
827: if l_ni is null then
828: l_ni := '-MISSING-';
829: end if;
830: fnd_file.put_line(fnd_file.output,rpad(asg_rec.emp_no, 18) || ' ' ||
831: rpad(l_ni ,10) || ' ' ||
832: rpad(l_temp,50) || ' ' ||
833: rpad(asg_rec.old_works_number,17)); -- 5398360
834: l_count := l_count + 1;
836: END IF;
837:
838:
839:
840: fnd_file.put_line(fnd_file.output,null);
841: if p_type = 'E' then
842: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed with error : ' || l_count);
843: else
844: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed successfully :' || l_count);
838:
839:
840: fnd_file.put_line(fnd_file.output,null);
841: if p_type = 'E' then
842: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed with error : ' || l_count);
843: else
844: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed successfully :' || l_count);
845: end if;
846: l_counter := l_counter + l_count;
840: fnd_file.put_line(fnd_file.output,null);
841: if p_type = 'E' then
842: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed with error : ' || l_count);
843: else
844: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed successfully :' || l_count);
845: end if;
846: l_counter := l_counter + l_count;
847: end write_body;
848:
847: end write_body;
848:
849: procedure write_footer is
850: begin
851: fnd_file.put_line(fnd_file.output,null);
852: fnd_file.put_line(fnd_file.output,'Total Number Of Records : ' || l_counter);
853: end write_footer;
854: BEGIN
855: hr_utility.set_location('Entering: '||l_proc,1);
848:
849: procedure write_footer is
850: begin
851: fnd_file.put_line(fnd_file.output,null);
852: fnd_file.put_line(fnd_file.output,'Total Number Of Records : ' || l_counter);
853: end write_footer;
854: BEGIN
855: hr_utility.set_location('Entering: '||l_proc,1);
856: l_counter := 0;