Class form
Understanding the External Mapping tab

  1. About 
  2. New 
  3. General 
  4. Locking 
  5. External Mapping 
  6. Advanced 
  7. History 
  1. More... 
Advanced featureThe External Mapping tab is used primarily for external classes — classes that are created by the Connector and Metadata accelerator or the Database Class Mappings gadget and that are linked by a Database Table data instance to a table in a database other than the PegaRULES database.

Ordinarily, this tab is completed by one of these two tools, and no changes are required. The special case described below is an exception.

Field

Description

External Table Column Mapping

Optional. Leave blank unless this class is an external class that represents a table in an external database (generated by the Connector and Metadata Accelerator or the Database Class Mappings wizard), or you are replicating scalar embedded properties as described below.

Fields in this section map the properties generated for the class rule to the columns in the external table.

Column Name

For generated class rules, the name of a column in the external table.

Property Name

For generated class rules, the name of the property that represents the table column in the Column Name field.

Exposing an embedded Single Value property value into a column

Advanced featureFor a concrete internal class, you can use this tab to expose match an embedded Single Value property in a database column.

For example, the embedded property .pyPreferences.pyCaptionDisplay for a user who is a developer records a preference for whether that operator wants to see rule names, or Description text. (This property has one of the two values NAME or LABEL, as selected on the Preferences menu item, View group.)

If it was important to use this embedded property as report selection criteria, the property must correspond to a column. Use these steps to make a (scalar) embedded property available as a database column.

  1. Ask a DBA to create a new column of the appropriate data type in the PegaRULES database table that corresponds to the Data-Admin-Operator-ID table. In this example, the table is pr_operators. The DBA created a text column named CAPTIONDISPLAY. (You can't use the Modify Schema wizard to add this column, because there is no property named CAPTIONDISPLAY.)
  2. Update the Class rule for the class Data-Admin-Operator-ID. Add a row to the Column Mapping array on this tab. Enter the new column name CAPTIONDISPLAY the Column Name field and the embedded property reference in the Property Name field.
  3. Thereafter, the system updates the new column CAPTIONDISPLAY from the embedded property .pyPreferences.pyCaptionDisplay whenever an Operator ID data instance is saved. The property reference pyPreferences.pyCaptionDisplay can be used as criteria in List View and Summary View reports.

This feature provides a direct but limited alternative to creating an Index- class and maintaining the index through a Declare Index rule, or to replicating the value to a second (top-level) property using a Declare Expression rule or Declare Trigger rule.

Notes:

Up About Class rules