cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Stay updated on what is happening on the PTC Community by subscribing to PTC Community Announcements. X

Translate the entire conversation x

Extracting family table details from Windchill PDM 12.1 database using SQL Query

Vignesh_AJ_77
8-Gravel

Extracting family table details from Windchill PDM 12.1 database using SQL Query

Version: Windchill 12.1

 

Use Case: Need to extract the generic and instance family table data


Description:

I have already referred article: Article - CS284331 - How to get QML Report/SQL Query to get CAD Generic Part and its corresponding Instance parts in Windchill PDMLink

But in our database, we have different tables related to  family table:

1. EPMSepFamilyTableMaster 2. EPMSepFamilyTable 3. EPMFamilyTableMember. 

 

I formed below query, but it was not successful because it's not retrieving all family table data and also the instance name is incorrect. 

 

SELECT 
    master.name AS parent_name,
  master.createStampA2 AS parent_create_date,
    master.modifyStampA2 AS parent_modify_date,
  ft.versionIdA2versionInfo AS version_id,
    ft.iterationIdA2iterationInfo AS iteration_id,
  ft.statecheckoutinfo AS checkout_state,
  member.title AS member_title
FROM 
    pdmlink.EPMSepFamilyTableMaster master
INNER JOIN 
    pdmlink.EPMSepFamilyTable ft 
    ON master.idA2A2 = ft.idA3masterReference
INNER JOIN 
    pdmlink.EPMFamilyTableMember member 
    ON ft.idA2A2 = member.idA3A3
ORDER BY 
    master.idA2A2, member.idA3A3;


Could you please correct above query or provide me some other table names which I can use to retrieve the generic and instance relationship from database. Thank you.

1 REPLY 1
Announcements
Top Tags