The community will undergo maintenance on October 16th at 10:00 PM PDT and will be unavailable for up to one hour.
I am really struggling with Windchill's autonumbering behavior and its integration with Creo. Even though Windchill was released 19 years ago (1998), it still doesn't seem like it's properly integrated with Creo. What I would really like is to have autonumbering enabled, but optional, and not have numbers automatically consumed (in the database) unless they are actually used (by Creo).
Here is what my OIR (object initialization rule) looks like. This should pull a number only when I don't manually name the Creo object something else.
This works exaclty as expected when creating a new file in Creo. No number is pulled from the database until an object has actually been created by Creo.
Unfortunately this falls apart everywhere else. All of these other actions will pull a number from the database as soon as the dialog is opened:
Wasting a number every time one of these other actions is taken is making the whole thing unusable (at least for us.) Yes, it functions, but it's not acceptable to "waste" 70% of the available numbers. My goal was to replace manually assigning numbers from an Excel spreadsheet with Windchill's autonumbering, but that's not going to be possible if most of the numbers Windchill assigns never end up actually becomming real objects.
Does anyone have any possible workarounds? Is there some way to have autonumbering enabled in Windchill but prevent Creo from using it? (I'm fine with either creating the CAD docs in Windchill first or using Windchill rename to get the correct numbers assigned later.) What about Creo config options? Is there any way to allow autonumbering for new files but disable it other places? Am I missing something else in the OIR? Do I just wait for the day when PTC makes the behavior consistent everywhere?
There is an existing product idea for the save-as use case. If this matters at all to you, please vote it up.
So I managed to come up with a database query that counts how many of the issued EPM sequence numbers have never been used. Of the 3,661 sequence numbers Windchill has issued so far, 2,952 (80%) of them were wasted. This occurred in less than one week (hence the reason auto numbering is currently disabled.)
Here is the SQL query if anyone is interested. You will need to change the sequence table name to match the one in your system. Also keep in mind that this is only looking for EPMDocuments (CAD files).
-- Count sequence numbers without corresponding CAD document SELECT COUNT(seq.value) FROM wt_sequence_EPM_seq AS seq OUTER APPLY ( SELECT CADName FROM EPMDocumentMaster WHERE CADName LIKE (CAST(seq.value as nvarchar(10)) + '.%') ) edm WHERE edm.CADName IS NULL;
Have you checked the Oracle DB for how it handles the sequence numbering?
By default, it rounds up to the next multiple of 10 whenever there is a pause in obtaining a number. It can be turned off in Oracle so you will continuously get sequential numbers. I will have to dig out some of the PTC Cs articles that explain this.
I know what you're talking about and I dealt with that before I ever enabled auto numbering. These are being correctly issued one at a time, but unfortunately the way Creo interacts with Windchill it "burns up" numbers unnecessarily. (See the original post.)
If the Creo team every gets this working correctly then I would also like to be able to enable auto numbering separately for parts and assemblies vs. drawings. This does not seem possible either so I created this product idea: https://community.ptc.com/t5/Windchill-Ideas/Allow-object-initialization-rules-to-branch-based-on-quot/idi-p/566980
@TomU Did you ever make any progress with autonumbering? Looks like PTC archived your Product Idea related to this - not sure if it got implemented/resolved. Is there any way to identify which numbers were never checked in to Windchill and reuse them?
Nope. Creo functionality is greatly lacking. Really need PTC to make some changes before it will be usable.
I believe ideas were automatically archived based on the creation date. I've contacted the moderator to ask if they would prefer to un-archive the idea or have me create a new duplicate idea.
Yes, it's possible to identify which numbers were never used, but this has to be done on the database directly.
Normally I'm using just one number generator for cad documents. It's just a sad subject. Instead of making fundamental changes to the system, PTC simply patches a few minor problems.
I don't know how long that PTC sticks to this old Workspace and WGM functionality...
There are two possibilities to change the number generator for model, assembly and drawings:
1. OIR Configuration. This works only when creating new CAD-Files with the "New CAD-Document" wizard in the workspace and within Creo 5 direct (I belief). It won't work when you do a Save-As in Creo since the docType is empty.
<AttributeValues objType="wt.epm.EPMDocument"> <AttrValue id="number" algorithm="com.ptc.windchill.enterprise.revisionControlled.server.impl.NumberGenerator"> <Value algorithm="wt.rule.algorithm.CaseBranch"> <Value algorithm="wt.rule.algorithm.EqualsTest"> <Attr id="docType"/> <Arg>CADCOMPONENT</Arg> </Value> <Arg>{GEN:wt.enterprise.SequenceGenerator:CADCOMPONENT_seq:7:0}</Arg> <Value algorithm="wt.rule.algorithm.EqualsTest"> <Attr id="docType"/> <Arg>CADASSEMBLY</Arg> </Value> <Arg>{GEN:wt.enterprise.SequenceGenerator:CADASSEMBLY_seq:7:0}</Arg> <Value algorithm="wt.rule.algorithm.EqualsTest"> <Attr id="docType"/> <Arg>CADDRAWING</Arg> </Value> <Arg>{GEN:wt.enterprise.SequenceGenerator:CADDRAWING_seq:7:0}</Arg> <Arg>{GEN:wt.enterprise.SequenceGenerator:CADFALLBACK_seq:7:0}</Arg> </Value> </AttrValue> </AttributeValues>
2. The more convenience way is to create subtypes for each docType. This is necessary, since a cad model has a mass and density etc. but not a drawing. This enables you also to have different attributes on the different types:
<?xml version="1.0" encoding="UTF-8"?> <SoftTypeDescriptor xmlns='http://www.ptc.com/SoftTypeDescriptor' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.ptc.com SoftTypeDescriptor.xsd'> <!-- Default soft types for the authoring application : PROE --> <AuthAppSoftTypeInfo authAppName="PROE"> <!-- Zuweisung betrifft EPM-Dokumente --> <ObjectClassInfo classType="EPMDocument"> <!-- Creo Drawing --> <ObjectTypeInfo type="CADDRAWING"> <SoftTypeInfo softTypeId="${internet_domain_name}.CreoDrawing"/> <SoftTypeInfo subType="*" softTypeId="${internet_domain_name}.CreoDrawing"/> </ObjectTypeInfo> <!-- Creo Assembly --> <ObjectTypeInfo type="CADASSEMBLY"> <SoftTypeInfo softTypeId="${internet_domain_name}.CreoAssembly"/> <SoftTypeInfo subType="*" softTypeId="${internet_domain_name}.CreoAssembly"/> </ObjectTypeInfo> <!-- Creo Part / Sheet Part --> <ObjectTypeInfo type="CADCOMPONENT"> <SoftTypeInfo softTypeId="${internet_domain_name}.CreoPart"/> <SoftTypeInfo subType="*" softTypeId="${internet_domain_name}.CreoPart"/> </ObjectTypeInfo> <!-- Other Creo-Files like frames, etc. --> <ObjectTypeInfo type="*"> <SoftTypeInfo softTypeId="${internet_domain_name}.CreoDocument"/> <SoftTypeInfo subType="*" softTypeId="${internet_domain_name}.CreoDocument"/> </ObjectTypeInfo> </ObjectClassInfo> </AuthAppSoftTypeInfo> </SoftTypeDescriptor>
Hope this helps
According to this article, OIRs will not branch based on docType (like you're showing in the first example.)
As I have written, it will work in the workspace and commonspace, but not in Creo itself.
As long you create CAD-Objects with the Workspace Create New Wizard and Save-As etc. in the workspace and commonspace, it will work.
#2 from brueegg's reply worked great for me. I was able to specify that drawings do not use the same autonumbers that models do, and creating drawings doesn't burn numbers used for models. I've always wanted to do this but had never stumbled across it. It's even in the help since at least Windchill 10.0. Search for EPMDefaultSoftType.xml.
@TomU I might vote for a new idea. I think the way you described the issue here shows a lot of the gaps using Autonumbering in Creo.
Here is the new product idea. Please vote it up!