Skip to main content
1-Visitor
July 23, 2015
Question

SQL Query to find out BOM

  • July 23, 2015
  • 2 replies
  • 9023 views

Dear community,

I need to find out what database tables store the information about the bill of material of the products. Need to find out the top level nodes and all linked epm documents or parts.

What we try to do is get the files of all products so we can Export all products from windchill.

Any help is appreciated.

Thanks.

2 replies

1-Visitor
July 23, 2015

Stefan,

WTPart-to-WTPart Parent-Child links that build a WTPart BOM are stored in the WTPARTUSAGELINK table.

WTPart-to-EPMDocument owner links are stored in the EPMBUILDRULE table.

There are more tables needed to query if you're looking to pull EVERYTHING related to a specific WTPart or EPMDocument.  Let me know if there's any way I can help you with an extraction.

srohde1-VisitorAuthor
1-Visitor
September 9, 2015

In which columns are those 2 Parts stored? I can only see the IDA3A5 column which holds 1 Part Info. where is the Parent and the Child Part stored?

12-Amethyst
September 9, 2015

Hi Stefan,

IDA3A5 id the Object ID of parent IDA3B5 is object ID of child (PartMaster). If you want number you have lo include Part master in you query. Let me know if you need any info.

regards

Sudhakar

1-Visitor
July 27, 2016

Hi Stefan,

Try this query to get the BOM structure

SELECT    M1.WTPARTNUMBER AS COMPONENT, M2.WTPARTNUMBER AS ASSEMBLY

FROM      WTPART, WTPARTMASTER M2, WTPARTUSAGELINK, WTPARTMASTER M1

WHERE     WTPART.IDA3MASTERREFERENCE = M2.IDA2A2

                   AND WTPART.IDA2A2 = WTPARTUSAGELINK.IDA3A5

                   AND WTPARTUSAGELINK.IDA3B5 = M1.IDA2A2

                   and M2.WTPARTNUMBER = '<Part_number>'

GROUP BY  M2.WTPARTNUMBER, M1.WTPARTNUMBER

order by  M2.WTPARTNUMBER, M1.WTPARTNUMBER;

1-Visitor
February 16, 2021

How do we find the Specific version of a BOM. For example:

Part 1 Rev B.1  Child 1 Rev B.2

Part 1 Rev A.1   Child 1 Rev B.1

 

Thanks.