736: end if;
737:
738: l_form := 'WNU ( WNU '||p_wnu_version||' )';
739:
740: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
741: fnd_file.put_line(fnd_file.output,' ');
742: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
743: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
744: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
737:
738: l_form := 'WNU ( WNU '||p_wnu_version||' )';
739:
740: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
741: fnd_file.put_line(fnd_file.output,' ');
742: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
743: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
744: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
745: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
738: l_form := 'WNU ( WNU '||p_wnu_version||' )';
739:
740: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
741: fnd_file.put_line(fnd_file.output,' ');
742: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
743: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
744: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
745: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
746: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
739:
740: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
741: fnd_file.put_line(fnd_file.output,' ');
742: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
743: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
744: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
745: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
746: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
747: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
740: fnd_file.put_line(fnd_file.output,'EDI Transmission Report:');
741: fnd_file.put_line(fnd_file.output,' ');
742: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
743: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
744: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
745: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
746: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
747: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
748: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
741: fnd_file.put_line(fnd_file.output,' ');
742: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
743: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
744: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
745: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
746: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
747: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
748: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
749: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
742: fnd_file.put_line(fnd_file.output,rpad('Form Type : ',32) || l_form );
743: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
744: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
745: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
746: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
747: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
748: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
749: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
750: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
743: fnd_file.put_line(fnd_file.output,rpad('Sender : ',32) || l_det.sender_id);
744: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
745: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
746: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
747: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
748: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
749: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
750: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
751: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
744: fnd_file.put_line(fnd_file.output,rpad('Date : ',32) || to_char(sysdate, 'DD/MM/YYYY HH24:MI:SS'));
745: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
746: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
747: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
748: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
749: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
750: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
751: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
752: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
745: fnd_file.put_line(fnd_file.output,rpad('Interchange Control Reference : ',32) || l_param.control_id);
746: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
747: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
748: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
749: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
750: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
751: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
752: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
753: if length(l_addr2) > 0 then
746: fnd_file.put_line(fnd_file.output,rpad('Test Transmission : ',32) || l_test);
747: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
748: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
749: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
750: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
751: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
752: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
753: if length(l_addr2) > 0 then
754: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
747: fnd_file.put_line(fnd_file.output,rpad('Urgent : ',32) || l_urgent);
748: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
749: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
750: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
751: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
752: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
753: if length(l_addr2) > 0 then
754: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
755: end if;
748: fnd_file.put_line(fnd_file.output,rpad('-',80,'-'));
749: fnd_file.put_line(fnd_file.output,rpad('Employers PAYE Reference : ',32) || l_tax_ref);
750: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
751: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
752: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
753: if length(l_addr2) > 0 then
754: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
755: end if;
756: if length(l_addr3) > 0 then
750: fnd_file.put_line(fnd_file.output,rpad('HRMC Office : ',32) || l_det.hrmc_office);
751: fnd_file.put_line(fnd_file.output,rpad('Employer Name : ',32) || l_det.er_name);
752: fnd_file.put_line(fnd_file.output,rpad('Employer Address : ',32) || l_addr1);
753: if length(l_addr2) > 0 then
754: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
755: end if;
756: if length(l_addr3) > 0 then
757: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr3);
758: end if;
753: if length(l_addr2) > 0 then
754: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr2);
755: end if;
756: if length(l_addr3) > 0 then
757: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr3);
758: end if;
759: if length(l_addr4) > 0 then
760: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr4);
761: end if;
756: if length(l_addr3) > 0 then
757: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr3);
758: end if;
759: if length(l_addr4) > 0 then
760: fnd_file.put_line(fnd_file.output,rpad(' ',32) || l_addr4);
761: end if;
762: end write_header;
763:
764: procedure write_sub_header(p_type varchar2 , p_wnu_version VARCHAR2) is
763:
764: procedure write_sub_header(p_type varchar2 , p_wnu_version VARCHAR2) is
765:
766: begin
767: fnd_file.put_line(fnd_file.output,null);
768: if p_type = 'E' then
769: fnd_file.put_line(fnd_file.output,'The following assignments have completed with error');
770: else
771: fnd_file.put_line(fnd_file.output,'The following assignments have completed successfully');
765:
766: begin
767: fnd_file.put_line(fnd_file.output,null);
768: if p_type = 'E' then
769: fnd_file.put_line(fnd_file.output,'The following assignments have completed with error');
770: else
771: fnd_file.put_line(fnd_file.output,'The following assignments have completed successfully');
772: end if;
773: -- Bug 5398360
767: fnd_file.put_line(fnd_file.output,null);
768: if p_type = 'E' then
769: fnd_file.put_line(fnd_file.output,'The following assignments have completed with error');
770: else
771: fnd_file.put_line(fnd_file.output,'The following assignments have completed successfully');
772: end if;
773: -- Bug 5398360
774:
775: IF p_wnu_version = '1.0' THEN
772: end if;
773: -- Bug 5398360
774:
775: IF p_wnu_version = '1.0' THEN
776: fnd_file.put_line(fnd_file.output,rpad('Assignment Number',19) ||
777: rpad('NI Number',11) ||
778: rpad('Employee Name', 50));
779: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
780: rpad('-',10,'-') || ' ' ||
775: IF p_wnu_version = '1.0' THEN
776: fnd_file.put_line(fnd_file.output,rpad('Assignment Number',19) ||
777: rpad('NI Number',11) ||
778: rpad('Employee Name', 50));
779: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
780: rpad('-',10,'-') || ' ' ||
781: rpad('-',50,'-'));
782: ELSE
783: fnd_file.put_line(fnd_file.output,rpad('Works Number',19) ||
779: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
780: rpad('-',10,'-') || ' ' ||
781: rpad('-',50,'-'));
782: ELSE
783: fnd_file.put_line(fnd_file.output,rpad('Works Number',19) ||
784: rpad('NI Number',11) ||
785: rpad('Employee Name', 51)||
786: rpad('Old Works Number',18) ) ;
787: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
783: fnd_file.put_line(fnd_file.output,rpad('Works Number',19) ||
784: rpad('NI Number',11) ||
785: rpad('Employee Name', 51)||
786: rpad('Old Works Number',18) ) ;
787: fnd_file.put_line(fnd_file.output,rpad('-',18,'-') || ' ' ||
788: rpad('-',10,'-') || ' ' ||
789: rpad('-',50,'-')|| ' ' ||
790: rpad('-',18,'-') );
791:
830: l_ni := asg_rec.ni_no;
831: if l_ni is null then
832: l_ni := '-MISSING-';
833: end if;
834: fnd_file.put_line(fnd_file.output,rpad(asg_rec.emp_no, 18) || ' ' ||
835: rpad(l_ni ,10) || ' ' ||
836: rpad(l_temp,50));
837: l_count := l_count + 1;
838: end loop;
843: l_ni := asg_rec.ni_no;
844: if l_ni is null then
845: l_ni := '-MISSING-';
846: end if;
847: fnd_file.put_line(fnd_file.output,rpad(asg_rec.emp_no, 18) || ' ' ||
848: rpad(l_ni ,10) || ' ' ||
849: rpad(l_temp,50) || ' ' ||
850: rpad(asg_rec.old_works_number,17)); -- 5398360
851: l_count := l_count + 1;
853: END IF;
854:
855:
856:
857: fnd_file.put_line(fnd_file.output,null);
858: if p_type = 'E' then
859: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed with error : ' || l_count);
860: else
861: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed successfully :' || l_count);
855:
856:
857: fnd_file.put_line(fnd_file.output,null);
858: if p_type = 'E' then
859: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed with error : ' || l_count);
860: else
861: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed successfully :' || l_count);
862: end if;
863: l_counter := l_counter + l_count;
857: fnd_file.put_line(fnd_file.output,null);
858: if p_type = 'E' then
859: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed with error : ' || l_count);
860: else
861: fnd_file.put_line(fnd_file.output,'Total Number of assignments completed successfully :' || l_count);
862: end if;
863: l_counter := l_counter + l_count;
864: end write_body;
865:
864: end write_body;
865:
866: procedure write_footer is
867: begin
868: fnd_file.put_line(fnd_file.output,null);
869: fnd_file.put_line(fnd_file.output,'Total Number Of Records : ' || l_counter);
870: end write_footer;
871: BEGIN
872: hr_utility.set_location('Entering: '||l_proc,1);
865:
866: procedure write_footer is
867: begin
868: fnd_file.put_line(fnd_file.output,null);
869: fnd_file.put_line(fnd_file.output,'Total Number Of Records : ' || l_counter);
870: end write_footer;
871: BEGIN
872: hr_utility.set_location('Entering: '||l_proc,1);
873: l_counter := 0;