Derived and Stored Property Processing

This topic discusses how properties with the Derived and Stored default type are processed when nodes are added or updated in a viewpoint.

Tip:

In the processing sections below, a stored value refers to a value that is either defined or one that has already been derived and then stored on a node.

Interactive Requests

For properties with the Derived and Stored default type, values are derived during a request and then stored after the request is committed and before it is completed. While the request is in process, for any Derived and Stored properties that do not already have a stored value, the value for that property is dynamically calculated based on the expression that you defined in Default Value. The property origin during request processing is Derived.

After the request is committed and before it is completed, all properties with the Derived and Stored default type are checked. The properties that do not have a stored value or a property update action with a user defined value are updated with the value from the expression that you defined, and the value is stored as a Derived and Stored value.

Note:

These property update actions are added to the request and can be viewed in the request inspector. See Inspecting Request Items.

The process of calculating and populating the derived value in a property is an internal system property update action and therefore is not subject to security and validations. In other words, when a user adds or updates a node the system populates all properties with the Derived and Stored default type for that node that do not already have defined values even if:

  • The user does not have write access on that property
  • The property is hidden in the viewpoint
  • The property is not defined as editable
  • The property has Lock on Commit enabled

However, if a user clears or manually enters a defined value the usual security and validations are applied.

If you clear the value on a Derived and Stored property, the system displays the currently calculated value based on the expression that you defined and the property origin is Derived. Clearing the value provides a way to recalculate the value of Derived and Stored properties if the information used in the expression has changed. When the request is committed, the calculated value is stored as a Derived and Stored value.

Note:

For copy and model after operations the Derived and Stored values are not copied from the source nodes. The values for the new nodes are calculated and stored from the expression that is defined in Default Value.

Request File Load

For requests from a file load (that is, uploaded request files in an interactive request, compare requests, copy or model after requests, subscriptions, consolidation requests, and merge imports), nodes that do not already have stored values for a Derived and Stored property are updated as follows:

  • If the request file contains a defined value for the Derived and Stored property, the value is updated as normal. This is a user action and security and validations apply.
    • The <blank> keyword updates the property with a defined blank value.
    • The <clear> keyword clears the existing value (including blank values) and calculates the derived value.

      Tip:

      If you add a property with the Derived and Stored default type to an existing node type, an easy way to populate values for that property on existing nodes without making any other changes is to update that property with the <clear> keyword using a request file or viewpoint load.
  • If the request file does not contain a defined value for the Derived and Stored property, then the property is updated with a derived value based on the expression that you defined in Default Value and stored as a Derived and Stored value. This is an internal system action and security and validations do not apply.

    Note:

    Derived and Stored property values for nodes in a request file are updated even if that property isn't included in the file. For example, if your file contains updates for the Description property only, any nodes in that file that do not have a stored value for a property with a default type of Derived and Stored will also have that property updated with the calculated value, even if the user doesn't have write access to that property or the property is hidden in the viewpoint.

Imports and Viewpoint Loads

Merge Mode

Imports and viewpoint loads in merge mode are processed the same as Request File Load, above. All properties with a default type of Derived and Stored (including unbound properties) that do not already have a stored value are updated with the calculated value during the import or viewpoint load. That calculated value is then stored for that property.

You can use the <clear> keyword to calculate Derived and Stored values in imports and viewpoint loads in Merge mode.

Reset and Replace Modes

For imports in both Reset and Replace modes, unbound properties with the Derived and Stored default type are not modified. Only bound properties in Universal applications can be updated with Derived and Stored values. The values are updated following the same processing as Request File Load, above.

For viewpoint loads in Replace mode, only the Derived and Stored properties that are included in the viewpoint load file are updated with a derived and stored value. If your viewpoint load file does not contain a column for a property with a Derived and Stored default type, that property is not updated during the viewpoint load.

Using the <clear> Keyword in Reset and Replace Modes

For viewpoint loads in Replace mode, you can use the <clear> keyword to calculate Derived and Stored values for properties.

For imports in both Reset or Replace modes, you can use a clear keyword to calculate Derived and Stored values for properties if you have set one up in your import options. See Managing Import Options.