适用于锻件(第一级加工)
select
MSIB.SEGMENT1,
MSIB.DESCRIPTION,
comp.segment1,
comp.description,
comp.primary_unit_of_measure,
comp.component_quantity
from
(select
bbom.assembly_item_id,
msib.segment1,
msib.description,
msib.primary_unit_of_measure,
bic.component_quantity
from
bom_bill_of_materials bbom,
bom_inventory_components bic,
mtl_system_items_b msib
where
bbom.organization_id=103
and msib.organization_id=103
and bic.component_item_id=msib.inventory_item_id
and bbom.common_bill_sequence_id=bic.bill_sequence_id
) comp,
mtl_system_items_b msib
where
msib.organization_id=103
and msib.inventory_item_id=comp.assembly_item_id
and ( msib.segment1 like '%F%' OR msib.segment1 like '%ZG%' )
来自 “ ITPUB博客 ” ,链接:https://blog.itpub.net/209689/viewspace-587022/
,如需转载,请注明出处,否则将追究法律责任。