Loading Supersede Relationships Among Parts
Using the LoadfromFile utility, you can add, update, and remove supersede relationships among parts as well as groups of parts. To add or remove a supersede relationship between two single parts, you can use the Windchill user interface.
Shared teams must be loaded into an existing organization context. For more information about shared teams, see Basic Administration.
For more information, see Example for Superseding a Part. To learn more about supersede relationships, see Superseding Parts Overview.
This topic includes examples to use the LoadfromFile utility to do the following:
Create a supersede relationship among parts that exist in Windchill
Update supersede information among parts that exist in Windchill
Add a new supersede link using the <csvAddSupersede> tag
Delete an existing supersede link using the <csvDeleteSupersede> tag
Add or edit site-defined attribute values
Remove a supersede group and all of its corresponding supersede links
* 
If a part listed in the file does not exist in Windchill, it will be skipped. If there is an error, for example, in the syntax for an attribute, the load file will discontinue and exit.
For information on using the LoadfromFile utility, see Before you Begin.
Example 1: Create
In this first example, part number 111 is being superseded by parts 222 and 444.
The XML should resemble the following:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE NmLoader SYSTEM "standardX24.dtd">
<NmLoader>
<csvBeginCreateSupersede handler="wt.supersede.LoadSupersede.beginCreateSupersede"/>
<csvCreateSuperseded handler="wt.supersede.LoadSupersede.createSuperseded">
<csvsupersededNumber>111</csvsupersededNumber>
<csvsupersededName>111</csvsupersededName>
</csvCreateSuperseded>
<csvCreateSuperseding handler="wt.supersede.LoadSupersede.createSuperseding">
<csvsupersedingNumber>222</csvsupersedingNumber>
<csvsupersedingName>222</csvsupersedingName>
</csvCreateSuperseding>
<csvCreateSuperseding handler="wt.supersede.LoadSupersede.createSuperseding">
<csvsupersedingNumber>444</csvsupersedingNumber>
<csvsupersedingName>444</csvsupersedingName>
</csvCreateSuperseding>
<csvEndCreateSupersede handler="wt.supersede.LoadSupersede.endCreateSupersede" />
Example 2: Update
In this second example:
Parts 111 and 222 identify the supersede group on which the update is being performed.
A new supersede link is created between parts 111 and 345.
The existing supersede link between parts 111 and 567 is deleted.
The Company Name attribute on the supersede object will be modified to Val123.
The XML should resemble the following:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE NmLoader SYSTEM "standardX24.dtd">
<NmLoader>
<csvBeginUpdateSupersede handler="wt.supersede.LoadSupersede.beginUpdateSupersede">
<csvsupersededNumber>111</csvsupersededNumber>
<csvsupersededName>111</csvsupersededName>
<csvsupersedingNumber>222</csvsupersedingNumber>
<csvsupersedingName>222</csvsupersedingName>
</csvBeginUpdateSupersede>
<csvAddSupersede handler="wt.supersede.LoadSupersede.addSupersede">
<csvsupersededNumber>111</csvsupersededNumber>
<csvsupersededName>111</csvsupersededName>
<csvsupersedingNumber>345</csvsupersedingNumber>
<csvsupersedingName>345</csvsupersedingName>
</csvAddSupersede>
<csvDeleteSupersede handler="wt.supersede.LoadSupersede.deleteSupersede">
<csvsupersededNumber>111</csvsupersededNumber>
<csvsupersededName>111</csvsupersededName>
<csvsupersedingNumber>567</csvsupersedingNumber>
<csvsupersedingName>567</csvsupersedingName>
</csvDeleteSupersede>
<csvIBAValue handler="wt.iba.value.service.LoadValue.createIBAValue">
<csvdefinition>CompanyName123</csvdefinition>
<csvvalue1>Val123</csvvalue1>
<csvvalue2/>
<csvdependency_id/>
</csvIBAValue>
<csvEndUpdateSupersede handler="wt.supersede.LoadSupersede.endUpdateSupersede"/>
Example 3: Remove
In this third example, all supersede links of the supersede group and the supersede group itself are removed from Windchill. Parts 555 and 666 are two parts within the group and identify the group that should be removed.
The XML should resemble the following:
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE NmLoader SYSTEM "standardX24.dtd">
<NmLoader>
<csvRemoveSupersede handler="wt.supersede.LoadSupersede.removeSupersede">
<csvsupersededNumber>555</csvsupersededNumber>
<csvsupersededName>555</csvsupersededName>
<csvsupersedingNumber>666</csvsupersedingNumber>
<csvsupersedingName>666</csvsupersedingName>
</csvRemoveSupersede>
Was this helpful?