ums_import_unit_definitions
Creates, updates, and configures the display of Teamcenter units of measure. ums_import_unit_definitions runs automatically during Teamcenter installation and can subsequently be run by a Teamcenter administrator to manage units of measure. Siemens Digital Industries Software strongly recommends backing up any current unit definitions file before modifying the file. Units of measure are created and managed based on unit of measure definitions specified in a comma-delimited .csv file. The initial unit of measure definitions file supplied with Teamcenter is \unit_definitions.csv. See Working with the unit definitions file for a description of this file. After running ums_import_unit_definitions, ensure users log out of Teamcenter and start new sessions to use the updated units of measure. Use the ums_mapping utility to map and add legacy units of measure to the Unit Management System. Syntax ums_import_unit_definitions [-u=user-id {-p=password | -pf=password-file} -g=group] -file=unit_def_file -applications={app_name1,app_name_2,... | all} [-allowOverwrite] [[-createUOM] [-updateUOM]] | [-hideUOM] | [-showUOM] [-dryRun] [-utf8_mapping_file[=mapping_file]] [-h] Arguments -u Specifies the user ID. The user must have Teamcenter administration privileges and be a member of a group with DBA 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. For more information about managing password files, see Manage password files. This argument is mutually exclusive with the -p argument. -g Specifies the group associated with the user. This group must have DBA privileges. If used without a value, the user's default group is assumed. -file The comma-delimited .csv file (unit_def_file) containing unit of measure definitions. When creating or editing a unit of measure definition .csv file with an ASCII editor, save the .csv file with a UTF-8-BOM encoding. If saving a .xslx file as a .csv file, save the file using the "UTF-8 Comma Delimited" format. Doing so ensures that characters such as angstrom symbols, superscripts, and ohm symbols are saved correctly in the file. If your environment does not support UTF-8 encodings, consider using the -utf8_mapping_file option with the ums_import_unit_definitions utility. -allowOverwrite Optional. Overwrite existing units of measure based on the definitions in unit_def_file. -applications Restrict updates to one or more applications (as named in unit_def_file) containing unit of measure definitions. app_name is the string following Application: in unit_def_file For example, set app_name to NX for the column Application:NX. Separate multiple application names with commas. Set -applications to all to process all applications defined in unit_def_file. -createUOM Optional. Create the units of measure defined in unit_def_file. If -allowOverwrite is not specified, only new units of measure are created. If -allowOverwrite is specified, existing units of measure are overwritten based on the definitions in unit_def_file as well. -createUOM cannot be used with -hideUOM or -showUOM. If -createUOM, -updateUOM, -hideUOM, or -showUOM are not specified, -createUOM is assumed. -updateUOM Optional. Update existing units of measure with the definitions in unit_def_file. Units of measure defined in unit_def_file that do not currently exist will not be created. -updateUOM cannot be used with -hideUOM or -showUOM. -hideUOM Optional. Suppress existing units of measure defined in unit_def_file from appearing in Teamcenter and application lists of values. These units of measure are not removed from Teamcenter. -hideUOM cannot be used with -createUOM, -updateUOM, or -showUOM. After using -hideUOM, set the UMS_show_tc_display_uom preference to true to suppress the units of measure. -showUOM Optional. Show units of measure defined in unit_def_file that have previously been hidden using -hideUOM. -showUOM cannot be used with -createUOM, -updateUOM, or -hideUOM -dryRun Optional. Run ums_import_unit_definitions with the specified parameters without actually making changes to the units of measure. The results of running the utility are displayed in the command window, but no units of measure changes are made. Siemens Digital Industries Software strongly recommends using -dryRun to validate changes before actually creating or updating your UMS definitions. -utf8_mapping_file Optional. Specifies a two-column .csv file (mapping_file) associating UTF-8 characters with ASCII characters. When used, instances of the UTF-8 characters in the unit definition file are replaced with the specified ASCII characters. ASCII characters are required when running Teamcenter in a non-UTF-8 environment. The comma-separated data in the file has the following form. Copy UTF-8,ASCII ²,^2 ³,^3 Ω,Ohm µ,u Å,Angstrom If mapping_file is not supplied, the default mapping file \ums_utf8character_mapping.csv is used. -h Displays help for this utility. Environment As specified in Manually configure the Teamcenter environment. Files As specified in Log files produced by Teamcenter. Restrictions None. Examples Create units of measure for all units of measure defined in a .csv file. All existing units of measure are updated with any updated definitions. Copy ums_import_unit_definitions -file=c:\temp\unit_defs.csv -applications=all For units of measure that are members of the Base application, update existing units of measure with changed definitions. Copy ums_import_unit_definitions -file=c:\temp\unit_defs.csv -applications=Base -allowOverwrite -updateUOM Suppress units of measure in the Base application from appearing in lists of values. Copy ums_import_unit_definitions -file=c:\temp\unit_defs.csv -applications=Base -hideUOM Display units of measure in the Base application in lists of values. Copy ums_import_unit_definitions -file=unit_definitions.csv -applications=Base -showUOM