Find parent of any child item which is being used by the BOM of a Affected Item on a Pending Change Order
One of the constraints to deleting a Part is that it must not be on the BOM of another Part. If the Parent Part has been released, the Child Part’s Where Used table shows the Parent Part. However, if the Parent Part is on a Pending Change Order, and that Parent’s BOM has a Redline Add Part of the Child Part, it prevents the Child Part from being Deleted.
Is there any way in the API, given a Part, to see if it is the Child of any Part on a Pending Change Order? It works fine if the Change Order is Released, just not in Pending.
Part A (Introductory)
Build Change Order (123)
Part A (REV A)
Part B (Introductory)
If I have Part B, how do I figure out that it is being used by Part A’s BOM on a Pending Change Order?
Not from the API, that I am aware of. Since the change/assembly revision is not yet released, it is useless to show a component as being used because it might be removed before the assembly BOM is released.
A query in the database would be as follows :
select i.item_number ASSEMBLY, b.item_number COMPONENT
from bom b, item i
where b.item = i.id and b.change_in > 0
and exists (select null from change where id = b.change_in and statustype < 3)
and b.item_number = <item you are interesting in>;