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

Community Tip - You can Bookmark boards, posts or articles that you'd like to access again easily! X

How to identify parts and assemblies with the same name in Windchill

DeepenRavalia
10-Marble

How to identify parts and assemblies with the same name in Windchill

Hi all,

I am going to create WTParts for all EPM Documents in Windchill, what I'd like to know is how can I find out what parts and assemblies have the same name?

E.g root.prt and root.asm

Once I create the WTParts they will have the file extension for the number (root.prt) which is fine however I will be removing all extensions but the tool will run in to problems if a part and assembly have the same name.

Does anyone know how to produce a query/search in order to identify duplicate name parts and assemblies? Has anyone had to do this before so that they could integrate WTParts with their ERP/MRP?

Many thanks.

Best,

-=D

1 REPLY 1

Deepen: The following sql will list all epmdocument .asm's and .prt's that have the same base number. This is using the "cadname" field (to find the number) however could be easily changed to use the documentnumber field.

select s2.partNumber

from

    (select

        substr(s1.cadname, 0, instr(s1.cadname, '.') - 1) partNumber,

        count(*) numDups

        from

                (select distinct

                    edm.cadname

                from

                    epmdocumentmaster edm,

                    epmdocument ed

                where

                    ed.ida3masterreference = edm.ida2a2 and

                    (edm.cadname like '%.asm' or edm.cadname like '%.prt') and

                    classnamekeyc10 is not null and

                    ed.statecheckoutinfo = 'c/i') s1

    group by

        substr(s1.cadname, 0, instr(s1.cadname, '.') - 1)) s2

where

    s2.numDups > 1

order by

    s2.partNumber;

Top Tags