Skip to main content
18-Opal
May 8, 2018
Question

Can I use parameters in name and numbering rules?

  • May 8, 2018
  • 1 reply
  • 2170 views

Hello, everyone

 

Can I use parameters for naming and numbering?
We are going to establish a naming and numbering scheme for businesses that are introducing PDM.
We are going to propose the following.
#### _ #### _ <button> .prt or #### _ #### _ <button> .asm


#### means a four-digit number.
The first four digits represent the part number, and the middle four digits represent the pid.
The last <name> will be the name of a generic model.


The 4-digit number will specify the number following the OIR in ORACLE DB.
The last <name> will be the name of the file you will enter.
In combination, EPM documents will be given a number and file name.
The public name will have only <name>.


Each type also expects parameters like parameters PTC_WC_PART_NO, PTC_WC_PRODUCT_ID, and PTC_WC_PART_NAME.

Can I use WINDCHILL PDMLink systematically to satisfy the above requirement without having to use CREATE RELATIONSHIP in CREO?

If possible, please let me know about the approach.


Thank you.

 

Kind Regards

1 reply

CHASEONHO18-OpalAuthor
18-Opal
May 8, 2018

Image1.png

 

 <AttributeValues objType="com.ptc.windchill.option.model.ChoiceEnable">
 <!-- set the name to a generated number -->
 <AttrValue id="number" algorithm="com.ptc.windchill.enterprise.revisionControlled.server.impl.NumberGenerator">
 <Arg>{GEN:wt.enterprise.SequenceGenerator:choiceEnableNumber_seq:5:0}</Arg>
							<Arg>_</Arg>
							<Arg>{PARAM:CREO_PARAM}</Arg>
 <Attr id="PTC_COMMON_NAME"/>
 </AttrValue>
 <AttrConstraint id="number" algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints">
 <Value algorithm="com.ptc.core.rule.server.impl.GetServerAssignedConstraint"/>
 <Value algorithm="com.ptc.core.rule.server.impl.GetImmutableConstraint"/>
 </AttrConstraint> 
 </AttributeValues>
 

In addition, I will explain again.
I hope the results are as follows.
In PDMLink, the numbers are specified as follows:
The same is true of names.
"00007_ <CREO_PARAM_VALUE> _CommonName"
we want the file should be the format like "Common Name . Type"
So how do i write code in OIR?