Data sharing utilities
tc_attribute_bulk_update
Queries for specified properties and their current values, and then exports specified updated values into a TC XML file and then imports the TC XML file containing the updated values into the database. You can use this utility to update the properties of numerous objects in one pass. The update process allows you to update one or more attributes of an object. When a specified object contains multiple attributes, only the specified attributes are exported and updated. For complex update operations, you can create an input XML file containing instructions on which objects to update and the new values to apply. The file is constructed as a series of UpdateSets entries. Each entry must contain type, where, and update components. Before performing lengthy update operations, you can use the utility to determine the number of objects affected by a specified update operation. Syntax tc_attribute_bulk_update -u=user-id {-p=password | -pf=password-file} -g=group {-inputfile=path-to-input-XML-file -type=type-name -update_prop=property-name -update_value=property-value -cond_prop=property-name -cond_value=value-name} [-cond_operator=operator] [performSchemaValidation] [-queryonly] [-outdir=output-XML-file-directory] [-batchsize=number-of-objects-to-update] [-untransformed] [-uidfile] [-import] [-h] Arguments -u Specifies the user ID. This is a user with Teamcenter administration privileges. Note If Security Services single sign-on (SSO) is enabled for your server, the -u and -p arguments are authenticated externally through SSO rather than being authenticated against the Teamcenter database. If you do not supply these arguments, the utility attempts to join an existing SSO session. If no session is found, you are prompted to enter a user ID and password. -p Specifies the password. This argument is mutually exclusive with the -pf argument. -pf Specifies the password file. This argument is mutually exclusive with the -p argument. -g Specifies the group associated with the user. If used without a value, the user's default group is assumed. -inputfile Specifies the full path to the input XML file containing instructions on which objects to update and the new values to apply. The file is constructed as a series of UpdateSets entries. Each entry must contain type, where, and update components. Use the input file for complex updating instances. (For simpler instances, you can use the -cond_prop, -cond_value, and -cond_operator arguments.) You must use either this argument, or the -type, -update_prop and -update_value arguments. Following is an example input file: Copy
<UpdateSet>
<type name="ImanVolume" />
<where>
<cond_prop attrName=volume_name" attrValue="Volume2" cond_operator="=" />
</where>
<update>
<update_prop attrName="node_name" attrValue="s0987324" />
<update_prop attrName="machine_type" attrValue="2" />
<update_prop attrName="shadow_unix_path_name" attrValue="" />
<update_prop attrName="shadow_vms_path_name" attrValue="" />
<update_prop attrName="shadow_wnt_path_name" attrValue="" />
<update_prop attrName="wnt_path_name" attrValue="" />
<update_prop attrName="unix_path_name" attrValue="/users/jpip/volumes/tv2" />
<update_prop attrName="vms_path_name" attrValue="" />
</update>
</UpdateSet>
-type Specifies the type of objects to be updated, for example, item, dataset, ImanVolume, and so on. This argument accepts a single value, which must be a valid Teamcenter object. Use multiple instances of this argument to specify multiple object types. You must either use this argument in conjunction with the -cond_prop, -cond_value, -update_prop, and -update_value arguments, or use the -inputfile argument. -update_prop Specifies the internal name of the property to be updated (as opposed to the display name), for example, object_desc, char VLA, and so on. This argument accepts multiple values in a comma-separated list. Each value must be a valid property on a Teamcenter object, for example: Copy -update_prop=object_name,object_desc You can use multiple instances of this argument. Each instance of this argument should be paired with the -update_value argument. You must either use this argument in conjunction with the -cond_prop, -cond_value, -type, and -update_value arguments, or use the -inputfile argument. -update_value Specifies the new value for the property specified by the -update_prop argument. This argument accepts multiple values in a comma-separated list, for example: Copy -update_value=folder,"Home folder" You can use multiple instances of this argument. Each instance of this argument must be paired with the -update_prod argument. You must either use this argument in conjunction with the -cond_prop, -cond_value, -type, and -update_prop arguments, or use the -inputfile argument. -cond_prop Specifies the name of the property to be queried for and updated during export. This argument accepts multiple values in a comma-separated list. Each value must be a valid property on a Teamcenter object. For example: Copy -cond_prop=object_name,last_mod_date You can use multiple instances of this argument. Each instance of this argument must be paired with the -cond_value argument. You must either use this argument in conjunction with the -cond_value, -type, -update_prop, and -update_value arguments, or use the -inputfile argument. -cond_value Specifies the new value for the property specified by the -cond_prop argument. This argument accepts multiple values in a comma-separated list. Each value must be a valid property on a Teamcenter object. For example: Copy -cond_value=TextData_es_ES,"01-DEC-2011 00:00" You can use multiple instances of this argument. Each instance of this argument must be paired with the -cond_value argument. You must either use this argument in conjunction with the -cond_prop, -type, -update_prop, and -update_value arguments, or use the -inputfile argument. -cond_operator Specifies the operator to be used with the condition arguments. Valid operations are: equal, not equal, greater than, greater than and equal, less than, less than and equal. When setting the value for this argument in the command line, the format for these operations are: EQ, NE, GT, GE, LT, LE. When setting the value for this argument in the input file, you can use this format or the following characters: =, !=, >, >=, <, <=. This argument is optional and is only valid when used with, and placed after, the -cond_prop and -cond_value arguments, for example: Copy -cond_prop=object_name -cond_value="My obj #1"
-cond_prop="last_mod_date" -cond_value="01-DEC-2011 00:00"
-cond_operator="LE" -cond_prop="last_mod_date"
-cond_value="01-DEC-2010 00:00" -cond_operator="GE" -performSchemaValidation Enables schema validation of the XML input file. -queryonly Outputs the number of target objects affected by the specified update parameters to a log file. If the number of objects is less than 100, the object UIDs are included in the log file. When you specify this switch, the utility does not perform the update, it merely reports the number of affected objects. Use this switch in conjunction with either the input file or the condition and update arguments to determine how many objects are affected by specified update operation. You can use the resulting information to determine batch size, and to estimate the duration of the update operation. -outdir Specifies the directory to which the TC XML file and import log is generated. The file name is automatically generated and imported into the database using the following naming convention: Copy BulkAttrOut_1.xml, BulkAttrOut_2.xml, BulkAttrOut_3.xml This argument is optional. If not specified, the current directory is used. -batchsize Specifies the number of objects to update per TC XML file. This argument is optional. The default value is 800. -untransformed Exports the original values of the specified attributes. This argument is optional. -uidfile Specifies the full path to the input XML file containing a list of object UIDs. This argument is optional. If specified, it suppresses the function of the -cond_prop argument. -import Imports the TC XML file generated into the database for updating the property values given in the input file. This argument is optional. -h Displays help for this utility. Restrictions You must be a privileged user to run this utility. You must use either the -inputfile argument or the -type, -update_prop, -update_value, -cond_prop, and -cond_value arguments. Note The condition arguments are the equivalent of the where clause in an SQL phrase. Running this utility without specifying the -cond_prop and -cond_value arguments is technically possible but impractical. Examples To update the attributes of certain properties as specified in the propFile.xml file, enter the following command on a single line: Copy tc_attribute_bulk_update -u=admin-user -p=admin-password -g=dba
-inputfile=d:\propFile.xml -log=logFile.txt To update prop3 to value3 and prop4 to value4 for type1 objects, when prop1 equals value1 and prop2 is greater than value2, enter the following command on a single line: Copy tc_attribute_bulk_update -u=admin-user -pf=d:\password.txt -g=dba -type=type1
-cond_prop=prop1 -cond_value="value1" -cond_prop=prop2 -cond_value="value2"
-cond_operator="GT" -update_prop=prop3 -update_value="value3" -update_prop=prop4 -update_value="value4" To update prop3 to value3 and prop4 to value4 for type1 objects, when prop1 equals value1 and prop2 is greater than value2 in batches of 400, enter the following command on a single line: Copy tc_attribute_bulk_update -u=admin-user -pf=d:\password.txt -g=dba -type=type1
-cond_prop=prop1 -cond_value="value1" -cond_prop=prop2 -cond_value="value2"
-cond_operator="GT" -update_prop=prop3 -update_value="value3"
-update_prop=prop4 -update_value="value4" -batchsize=400 To update an object description to red Desc and the object name to This is a new object name for all items where the object_name property is my object and the str_attr property is red,white,yellow, enter the following command on a single line: Copy tc_attribute_bulk_update -u=admin-user -p=admin-password -g=dba -type=Item
-update_prop=object_desc -update_value="red Desc" -update_prop=object_name
-update_value="This is a new obj name"
-cond_prop=object_name -cond_value="my obj" -cond_value="str attr" -cond_value="red,white,yellow" To update an object description to blue Desc and the int_VLA to 10,3,0,99 for all datasets where the object_name property is TextData_es_ES and the last_mod_date property is 01-DEC-2011 00:00 or greater, enter the following command on a single line: Copy tc_attribute_bulk_update -u=admin-user -p=admin-password -g=dba -type=Dataset
-update_prop=object_desc -update_value="blue Desc"
-update_prop="int_VLA" -update_value="10,3,0,99" -cond_prop=object_name
-cond_value="TextData_es_ES" -cond_prop="last_mod_date" -cond_value=
"01-DEC-2011 00:00" -cond_operator="GE" To update the char_VLA to w,y.d,k,a for all items where the owning_user property is AsL5bfuW4ghudD, enter the following command on a single line: Copy tc_attribute_bulk_update -u=admin-user -p=admin-password -g=dba -type=Item
-update_prop="char VLA" -update_value="w,y,d,k,a" -cond_prop=owning_user
-cond_value="AsL5bfuW4ghudD" To update an object description to blue Desc, and to update the int_VLA property to 10,3,0,99 for all datasets where the object_name property is TextData_es_ES and the last_mod_date property is 01-DEC-2011 00:00 or greater, and to place the changes directly into the database by importing the TC XML file in single step, enter the following command on a single line: Copy tc_attribute_bulk_update -u=admin-user -p=admin-password -g=dba
-type=Dataset -update_prop=object_desc -update_value="blue Desc" -update_prop="int_VLA" -update_value="10,3,0,99" -cond_prop=object_name -cond_value="TextData_es_ES" -cond_prop="last_mod_date" -cond_value="01-DEC-2011 00:00" -cond_operator="GE" -import Related Topics TC XML and PLM XML Configuration for Data Import and Export Multi-Site CollaborationSource: https://docs.sw.siemens.com/documentation/external/PL20251212545240207/en-US/tc_help/utilities_reference/avt1737253695886/xid1179066.html · retrieved Fri Jul 31 2026 00:00:00 GMT+0000 (Coordinated Universal Time)