596: EXCEPTION
597: WHEN OTHERS THEN
598: o_error_code := 2;
599: o_error_msg := SQLERRM;
600: eni_dbi_util_pkg.log('An error prevented the initial part count collection from completing successfully');
601: eni_dbi_util_pkg.log(o_error_code||':'||o_error_msg);
602: ROLLBACK;
603: END part_count_collect_worker;
604:
597: WHEN OTHERS THEN
598: o_error_code := 2;
599: o_error_msg := SQLERRM;
600: eni_dbi_util_pkg.log('An error prevented the initial part count collection from completing successfully');
601: eni_dbi_util_pkg.log(o_error_code||':'||o_error_msg);
602: ROLLBACK;
603: END part_count_collect_worker;
604:
605: -- This is the procedure to collect the bills assigned to the worker p_worker_id into Part Count Fact.
665: WHERE bbom.assembly_item_id = l_inventory_item_id
666: AND bbom.organization_id = l_org_id
667: AND bbom.alternate_bom_designator IS NULL
668: AND bbom.bill_sequence_id = bbom.common_bill_sequence_id;
669: ENI_DBI_UTIL_PKG.LOG('Error occured during the explosion of Item-Org ' || l_inventory_item_id || '-' || l_org_id ||' of Bill_Sequence_id' || l_bill_sequence_id);
670: ENI_DBI_UTIL_PKG.LOG(l_error_code||':'||l_error_msg);
671:
672: IF (l_error_msg <> 'BOM_MAX_LEVELS') THEN -- Modified as part of the fix for the Bug # 3140363
673: l_error_code := 2; -- Modified as part of the fix for the Bug # 3127260
666: AND bbom.organization_id = l_org_id
667: AND bbom.alternate_bom_designator IS NULL
668: AND bbom.bill_sequence_id = bbom.common_bill_sequence_id;
669: ENI_DBI_UTIL_PKG.LOG('Error occured during the explosion of Item-Org ' || l_inventory_item_id || '-' || l_org_id ||' of Bill_Sequence_id' || l_bill_sequence_id);
670: ENI_DBI_UTIL_PKG.LOG(l_error_code||':'||l_error_msg);
671:
672: IF (l_error_msg <> 'BOM_MAX_LEVELS') THEN -- Modified as part of the fix for the Bug # 3140363
673: l_error_code := 2; -- Modified as part of the fix for the Bug # 3127260
674: o_error_occured := 2;
682: COMMIT;
683: EXECUTE IMMEDIATE 'truncate table '||g_eni_schema||'.eni_dbi_part_count_f';
684: RETURN; -- Returning with out collecting remaining bills due to error
685: ELSE
686: ENI_DBI_UTIL_PKG.LOG('Increase the MAX_BOM_LEVEL value in the profile of the Organization ' || l_org_id);
687: ENI_DBI_UTIL_PKG.LOG('If the MAX_BOM_LEVEL value is 59, then this is max number of levels possible for explosion.');
688: l_error_code := 1; -- Warning
689: o_error_occured := 1;
690: END IF; -- BOM_MAX_LEVELS check end
683: EXECUTE IMMEDIATE 'truncate table '||g_eni_schema||'.eni_dbi_part_count_f';
684: RETURN; -- Returning with out collecting remaining bills due to error
685: ELSE
686: ENI_DBI_UTIL_PKG.LOG('Increase the MAX_BOM_LEVEL value in the profile of the Organization ' || l_org_id);
687: ENI_DBI_UTIL_PKG.LOG('If the MAX_BOM_LEVEL value is 59, then this is max number of levels possible for explosion.');
688: l_error_code := 1; -- Warning
689: o_error_occured := 1;
690: END IF; -- BOM_MAX_LEVELS check end
691:
787: l_error_msg := SQLERRM;
788: l_error_code := 2;
789: -- Modified as part of the fix for the Bug # 3127260
790: FND_FILE.PUT_LINE(FND_FILE.LOG,'The following error has occured while inserting into the Part Count fact table');
791: ENI_DBI_UTIL_PKG.LOG(l_error_code||':'||l_error_msg);
792: ENI_DBI_UTIL_PKG.LOG('An error prevented the INCREMENTAL part count collection from completing successfully');
793: EXECUTE IMMEDIATE 'truncate table '||g_eni_schema||'.eni_dbi_part_count_f';
794: RETURN; -- Return from the for loop after the explosion.
795: END;
788: l_error_code := 2;
789: -- Modified as part of the fix for the Bug # 3127260
790: FND_FILE.PUT_LINE(FND_FILE.LOG,'The following error has occured while inserting into the Part Count fact table');
791: ENI_DBI_UTIL_PKG.LOG(l_error_code||':'||l_error_msg);
792: ENI_DBI_UTIL_PKG.LOG('An error prevented the INCREMENTAL part count collection from completing successfully');
793: EXECUTE IMMEDIATE 'truncate table '||g_eni_schema||'.eni_dbi_part_count_f';
794: RETURN; -- Return from the for loop after the explosion.
795: END;
796: END LOOP;
798: EXCEPTION
799: WHEN OTHERS THEN
800: l_error_code := 2;
801: l_error_msg := SQLERRM;
802: ENI_DBI_UTIL_PKG.LOG('An error prevented the initial part count collection from completing successfully');
803: ENI_DBI_UTIL_PKG.LOG(l_error_code||':'||l_error_msg);
804:
805: END PART_COUNT_COLLECT; -- End of the procedure definition
806:
799: WHEN OTHERS THEN
800: l_error_code := 2;
801: l_error_msg := SQLERRM;
802: ENI_DBI_UTIL_PKG.LOG('An error prevented the initial part count collection from completing successfully');
803: ENI_DBI_UTIL_PKG.LOG(l_error_code||':'||l_error_msg);
804:
805: END PART_COUNT_COLLECT; -- End of the procedure definition
806:
807: END ENI_DBI_PCO_LOAD_PKG;