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

Change Notice Number jumps

IanWexler
3-Visitor

Change Notice Number jumps

Currently, our CNs use the scheme of CN-xxxxx. We are currently running 10.1 M040. This morning, when creating a new CN, the number jumped from CN-10460 to CN-20461. The only thing that happened between the last CN we created, last night a 6:30 and this morning, was a windows patching of the servers. What would cause the number to jump like this and where do I go to hopefully fix this the next time it happens as we already created 20461 in the database.

Addendum: I just realized, not only did the Change Notice Numbers jump by 10000, the Change Request and the Task Numbers in the CN also jumped by 10000.

Thanks,

Ian Wexler

Digital Signal Corp

Message was edited by: Ian Wexler

8 REPLIES 8
BenPerry
13-Aquamarine
(To:IanWexler)

Ian,

Are you able to search the PTC tech support site? If yes, then search for "nocache". There are many articles about this.

Are you able to take a look at the sequences in your database? Whoever is able to look, view the CACHE_SIZE for the sequences WTCHANGEORDERID_SEQ and WTCHANGEREQUESTID_SEQ. Usually this is set to 20 OOTB. I'm surprised that it has jumped by 10,000 in your case. You might also want to submit your OIR for CNs and CRs to this posting. I'd be curious if that is factoring into it at all.

Thanks Ben,

Where would I find the CACHE_SIZE on the server? My IT folks would want to know where to look as they don't really know the system too well.

Here is the CN OIR, this was done by a third party for us.

<?xml version="1.0"?>

-<AttributeValues objType="wt.change2.WTChangeOrder2">

<!-- set the folder -->

-<AttrValue algorithm="com.ptc.core.foundation.folder.server.impl.FolderPathAttributeAlgorithm" id="folder.id"><Arg>/Default</Arg></AttrValue>

<!-- set the lifecycle -->

-<AttrValue algorithm="com.ptc.core.foundation.lifecycle.server.impl.LifeCycleTemplateAttributeAlgorithm" id="lifeCycle.id"><Arg>Change Notice Life Cycle</Arg></AttrValue>

<!-- set the team template -->

-<AttrValue algorithm="com.ptc.core.foundation.team.server.impl.TeamTemplateAttributeAlgorithm" id="teamTemplate.id"><Arg>Change Notice Team</Arg></AttrValue>

<!-- set the number to a generated number -->

-<AttrValue algorithm="com.ptc.windchill.enterprise.revisionControlled.server.impl.NumberGenerator" id="number"><Arg>{GEN:wt.enterprise.SequenceGenerator:WTCHANGEORDERID_seq:5:0}</Arg></AttrValue>

<!-- set the version info to a generated version info -->

-<AttrValue algorithm="com.ptc.core.foundation.vc.server.impl.VersionInfoGenerator" id="MBA|versionInfo"><Arg>wt.series.HarvardSeries</Arg></AttrValue>

<!-- specify AttrConstraint tag -->

-<AttrConstraint algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints" id="lifeCycle.id"><Value algorithm="com.ptc.core.rule.server.impl.GetServerAssignedConstraint"/><Value algorithm="com.ptc.core.rule.server.impl.GetImmutableConstraint"/></AttrConstraint>-<AttrConstraint algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints" id="lifeCycle"><Value algorithm="com.ptc.core.rule.server.impl.GetServerAssignedConstraint"/><Value algorithm="com.ptc.core.rule.server.impl.GetImmutableConstraint"/></AttrConstraint>-<AttrConstraint algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints" id="folder.id"><Value algorithm="com.ptc.core.rule.server.impl.GetServerAssignedConstraint"/><Value algorithm="com.ptc.core.rule.server.impl.GetImmutableConstraint"/></AttrConstraint>-<AttrConstraint algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints" id="number"><Value algorithm="com.ptc.core.rule.server.impl.GetServerAssignedConstraint"/><Value algorithm="com.ptc.core.rule.server.impl.GetImmutableConstraint"/></AttrConstraint>-<AttrConstraint algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints" id="teamTemplate.id"><Value algorithm="com.ptc.core.rule.server.impl.GetServerAssignedConstraint"/><Value algorithm="com.ptc.core.rule.server.impl.GetImmutableConstraint"/></AttrConstraint>-<AttrConstraint algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints" id="teamTemplate"><Value algorithm="com.ptc.core.rule.server.impl.GetServerAssignedConstraint"/><Value algorithm="com.ptc.core.rule.server.impl.GetImmutableConstraint"/></AttrConstraint>-<AttrConstraint algorithm="com.ptc.core.rule.server.impl.GatherAttributeConstraints" id="organization.id">-<Value algorithm="com.ptc.core.rule.server.impl.GetServerPreGeneratedValue"><Value algorithm="com.ptc.windchill.enterprise.org.server.impl.OwningOrgDefaultAlgorithm"/></Value></AttrConstraint></AttributeValues>

BenPerry
13-Aquamarine
(To:IanWexler)

Ian,

I tried to look for some SQL that could be executed to view the cache size of a sequence, but came up empty. I connect to the DB with a program called SQL Developer. You can use any program to connect to the DB, I would assume. In SQL Developer, it shows me the tables and sequences, among other things. Just drill down to it, and then view the attributes that are displayed on the screen.

The example below demonstrates how to view the CACHE_SIZE of the sequence ACTIONITEMNUMBER_SEQ.

I'm a little confused about your OIR. I only see this in reference to the Number of the Change Notice:

<AttrValue algorithm="com.ptc.windchill.enterprise.revisionControlled.server.impl.NumberGenerator" id="number">

<Arg>{GEN:wt.enterprise.SequenceGenerator:WTCHANGEORDERID_seq:5:0}</Arg>

</AttrValue>

Whereas if the resultant number is CN-#####, then it should look more like this:

<AttrValue algorithm="com.ptc.windchill.enterprise.revisionControlled.server.impl.NumberGenerator" id="number">

<Arg>CN-</Arg>

<Arg>{GEN:wt.enterprise.SequenceGenerator:WTCHANGEORDERID_seq:5:0}</Arg>

</AttrValue>

Maybe you have another OIR for wt.change2.WTChangeOrder2 at some different context level that is overriding this one.

2015-03-27_13-32-51.png

BenLoosli
23-Emerald II
(To:IanWexler)

It is a number coming out of Oracle and by setting it to 'no_cache' you diasable the number jumping.

On your Oracle server, use SQL*Plus, log into the Windchill instance and run this command:

Alter Sequence WTCHANGEREQUESTID_seq NOCACHE;

If you use the Oracle Console utilty, you can also change it in there by disabling the cache of the sequence chosen.

What if we use Sequel Server and not Oracle Server?

BenPerry
13-Aquamarine
(To:IanWexler)

Ian,

Your database admin should be able to find out the cache setting of the sequence. A cache setting of 10,000 is awfully high. Since your number jumped by 10,000, can you please have a DBA confirm the cache setting before we jump to conclusions? Just want to make sure first, before making any changes.

Thanks Ben,

I will work on getting IT to get me that number.

To save you the half day it took me to figure it out. Windchill uses identities in SQL Server, not Sequences.

Identity.png

Top Tags