About Attributes

When you extend content types with attributes, you need to define the attribute characteristics (such as data type, default value, and so on) and understand the implications with other operations (such as indexing and 6WTags).

This page discusses:

Content Types

You can only extend the listed types with attributes. When attributes are added to a given type, they are actually added to an interface that will be associated with any object instantiated from that type. Unlike types, all interfaces names are internationalized with the same name.

This table lists the types you can extend and the corresponding interfaces.

Type Name (as shown in the UI)System Name
Physical ProductVPMReference
Physical RepresentationVPMRepReference
MCAD DrawingMCAD Drawing
MCAD AssemblyMCAD Assembly
MCAD ComponentMCAD Component
MCAD RepresentationMCAD Representation
PartPart

You can extend several other types with attributes. The Attributes Management panel lists the available types, including the interface name. In most cases, the interface name is the same as the type name.

Attribute Data Types

When you define an attribute, you need to define its data type. You can specify any of these data types:

  • 16-character String
  • 40-character String
  • 80-character String
  • String (no length limit)
  • Integer
  • Real
  • Boolean
  • Date

Date attributes are not available on MCAD types. If you plan to map string attributes for a physical product to attributes for a part, choose the same string length.

Names and Titles for Additional Attributes

The name defines the attribute in the system and the title is what users see in dialog boxes, forms, and tables.

For more information, see Adding Custom Attributes to Types.

On the cloud only: Names of additional attributes display as defined and cannot be translated.
On premises only: You can define other NLS values for additional attributes for specific languages.
  • For Native clients, you need to create new .CATNls files for each language in <install_path>/win_b64/resources/msgcatalog/<language>. Files can be either OtbIRPCConfiguration.CATNls or OtbERConfiguration.CATNls depending on the type to which you added the attribute. In the file path, <language> can be English, French, German, and so on.
  • For Web clients, create a generic Page object named emxFrameworkStringResource_Custom.properties, and then create specific Page objects for each language. Use this naming convention: emxFrameworkStringResource_<lang>_Custom.properties where <lang> can be en, fr, de, and so on.

About Removing Attributes

You can remove user-defined attributes from the list of attributes for a content type. The list includes all user-defined attributes for the current content type.

This situation prevents you from removing a deployed attribute:

  • The attribute is mapped to a configured Part or Product attribute.
  • The attribute is used to check a configured attribute value as part of a lifecycle rule.

If the app cannot remove the attribute, it displays a message indicating the reason (either it is used in a lifecycle rule or is referenced by a collaboration relation parameter). To remove the attribute, you must first remove the corresponding lifecycle rule.

You should not remove attributes after the environment is deployed and is in production. If your installation has been deployed and people are creating objects, removing an attribute could impact business processes, and the affect on existing content could be inconsistent.

If content has been created and you remove an attribute used by that content:

  • If Part instances exist, the attribute is removed from the instances with no notification to the user. No inconsistency will appear afterwards.
  • If Product or Representation instances exist, the attribute is removed from the instances with no notification to the user. However, the value specified for a removed attribute can appear on preexisting instances on a newly-added attribute. This situation can happen in the following use case:
    1. Add a string(16) attribute "Attribute1" on type Product with default value "default1"
    2. Create a product. Assign value "value1" to Attribute1.
    3. Remove "Attribute1" from type Product.
    4. Add a string(16) attribute "Attribute2" on type Product with default value "default2".
    5. The value of the attribute "Attribute2" will not be "default2", but: "" (empty) in certain cases, "value1" in others.