375: + ln_w2_uncoll_ss_tax_tips;
376:
377: ln_941_box5a := NVL(ln_ss_er_taxable,0) * 0.124;
378: IF ln_941_box5a < 0 THEN
379: hr_utility.trace('001.'||'Tax Unit ID: '||TO_CHAR(p_tax_unit_id)||
380: ' has negative B5A Total Taxable SS Wages. Please check.');
381: END IF;
382:
383: ln_941_box5b := NVL(ln_ss_tips,0) * 0.124;
381: END IF;
382:
383: ln_941_box5b := NVL(ln_ss_tips,0) * 0.124;
384: IF ln_941_box5b < 0 THEN
385: hr_utility.trace('001.'||'Tax Unit ID: '||TO_CHAR(p_tax_unit_id)||
386: ' has negative B5B Total Taxable SS Wages. Please check.');
387: END IF;
388:
389: ln_941_box5c := NVL(ln_medicare_er_taxable,0) * 0.029;
387: END IF;
388:
389: ln_941_box5c := NVL(ln_medicare_er_taxable,0) * 0.029;
390: IF ln_941_box5c < 0 THEN
391: hr_utility.trace('001.'||'Tax Unit ID: '||TO_CHAR(p_tax_unit_id)||
392: ' has negative B5C Taxable Medicare Wages. Please check.');
393: END IF;
394:
395: ln_941_box5d := NVL(ln_941_box5a,0) +
395: ln_941_box5d := NVL(ln_941_box5a,0) +
396: NVL(ln_941_box5c,0) +
397: NVL(ln_941_box5b,0);
398: IF ln_941_box5d < 0 THEN
399: hr_utility.trace('001.'||'Tax Unit ID: '||TO_CHAR(p_tax_unit_id)||
400: ' has negative B5D Total SS Medicare Taxes. Please check.');
401: END IF;
402:
403: ln_941_box6 := ln_fit_withheld + ln_941_box5d;
597: PROCEDURE WritetoCLOB (p_XML OUT NOCOPY CLOB)
598: IS
599: l_xfdf_string CLOB;
600: BEGIN
601: hr_utility.set_location('Entered Procedure Write to clob ',100);
602: dbms_lob.createtemporary(l_xfdf_string,FALSE,DBMS_LOB.CALL);
603: dbms_lob.open(l_xfdf_string,dbms_lob.lob_readwrite);
604: -- if vXMLTable.count > 0 then
605: FOR ctr_table IN vXMLTable.FIRST .. vXMLTable.LAST
610: END LOOP;
611: p_XML := l_xfdf_string;
612: EXCEPTION
613: WHEN OTHERS THEN
614: HR_UTILITY.TRACE('sqleerm ' || SQLERRM);
615: HR_UTILITY.RAISE_ERROR;
616: END WritetoCLOB;
617:
618:
611: p_XML := l_xfdf_string;
612: EXCEPTION
613: WHEN OTHERS THEN
614: HR_UTILITY.TRACE('sqleerm ' || SQLERRM);
615: HR_UTILITY.RAISE_ERROR;
616: END WritetoCLOB;
617:
618:
619: PROCEDURE gen_941_report(p_business_group_id IN NUMBER,
666:
667: BEGIN
668:
669: l_procedure_name := '.pay_us_941_report_wrapper';
670: hr_utility.set_location('Entering '|| g_package || l_procedure_name, 10);
671:
672: /* Generate the xml output */
673: gen_941_report(p_business_group_id => p_business_group_id,
674: p_tax_unit_id => p_tax_unit_id,
715: END IF;
716:
717: EXCEPTION
718: WHEN others THEN
719: hr_utility.raise_error;
720:
721: hr_utility.set_location('Leaving '|| g_package || l_procedure_name, 20);
722:
723: End pay_us_941_report_wrapper ;
717: EXCEPTION
718: WHEN others THEN
719: hr_utility.raise_error;
720:
721: hr_utility.set_location('Leaving '|| g_package || l_procedure_name, 20);
722:
723: End pay_us_941_report_wrapper ;
724:
725: END pay_us_941_report;