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

Community Tip - Learn all about PTC Community Badges. Engage with PTC and see how many you can earn! X

How to delete some data in windchill pdm

ptc-2140310
1-Newbie

How to delete some data in windchill pdm

I am using Windchill PDMLink Release 12.0 and Datecode with CPS 12.0.0.1

There are quite a lot of test data in windchill pdm, including the task of upgrading the process. Is there any good way to delete it? Now some deletions will report an error (it cannot be deleted because of the relationship), and there are built products.

----------------------------------------------------------

Translated the text to English using google translate on 26-Apr-23 at 9:57am IST. Done by vnamboodheri

----------------------------------------------------------

Subject: windchill pdm怎么删除一些数据

Body: windchill pdm里面有比较多的测试数据,包括升级流程的任务,有什么好的方法删除吗? 现在有的删除会报错(有关联导致删不掉),及有建的产品。
----------------------------------------------------------

6 REPLIES 6

@ptc-2140310 

 

PDMLink is not designed to simply delete data that are in usage. 

If data are used by assemblies or WTPart objects are linked then you need to delete all. together. 

 

PetrH

BenLoosli
23-Emerald II
(To:ptc-2140310)

Can you explain what you mean by test data?

How much production data is in the system?

In order to delete any items, all related items must also be deleted. Drawings first, then assemblies and finally part files, working backwards through all top level objects.

jbailey
17-Peridot
(To:BenLoosli)

Actually you would have to start with process objects first (variances, problem reports, change requests, change notices, change reviews, promotion requests etc)

We see this happen some times too. Data was created without a distinct plan, test data was added by mistake, duplicates etc. Deleting data in Windchill is a pain, especially if it has been linked to somehow.

 

We have a separate context that we've aptly named "Hidden objects" to which only admins can move objects. Only admins are participants of this context. This way we "remove" objects from the end-users without actually deleting anything. We've also had users come back and say that the document they wanted to have deleted shouldn't have been. Moving stuff to Hidden objects instead of deleting is then a life saver.

 

Edit: I wanted to add that you will want to terminate any active workflow processes related to any moved objects since Tasks may still be viewed while the objects are unavailable.

It's good to have a separate test system for upgrades. This will help minimize the amount of test data in your production system.

I had a request to write a utility that will perform a power delete. That is, if the object is referenced by something delete it anyway.

The code deletes using APIs, NOT sql, so by the time the object is deleted all references to and the object it’s self are added to a WTSet and the set is deleted.

Currently the utility deletes EPMDocuments, WTParts and WTDocuments. The links that are Checked include, but are not limited to,

links to WTParts, Baselines, Change objects, links to other EPMDocuments, etc.

 

I did mention that deleting the link will not affect a CAD Assembly opened in Pro/E (please tell me everyone remembers when PTC first CAD app was called Pro/ENGINEER) from requiring the deleted CAD component, thus a regen failure was in the offing. The response was, “We understand and we don’t care, but thanks for the heads up”.

 

So, it is definitely possible to bulk delete referenced objects in Windchill. You just need to know what links to delete with the object and you definitely want to us the APIs to do it.

And you need a solid plan.

Announcements

Top Tags