Sending and Receiving Record Types

Salesforce record types enable you to create categories for an object and display different page layouts depending on the relevant record type. Many Certinia applications already use this feature, however you can create your own record types for your objects, if required.

In Foundations messaging, you can create mappings that send record type details in the following ways:

  • Send exact record type details from each source record to the target record
  • Send a static value to apply to all target records
  • Transform a value in a message to be suitable for the target record

For example, you can create a mapping that sends a work order with the record type name RepeatOrder to create a billing document with a record type of that name. If RepeatOrder is not a suitable record type name on the target, you can transform the value to fit the target's requirements, such as Repeat.

Notes:

Messaging references the unique record type name, not the record type label.

The following examples assume that you already have a messaging relationship and the relevant record types set up. You can either create new record types or use the record types supplied with the managed package. For more information about record types, see the Salesforce Help.

Send the Record Type Value to the Record Type Field

To create a mapping that sends the exact record type name from a source to a target:

  1. On the Message Types tab, click the name of the message type that contains the relationship you want to customize.
  2. In the Relationship & Mapping Details section, click Manage Relationship and select the publication and subscription that make up the relationship.
  3. Click Add Mapping.
  4. Enter a message key that describes the information you are sending. For example, Record Type.
  5. Leave the source type as "Field".
  6. For the source field path, select "Record Type ID >" then "Record Type Name".
  7. Leave the target type as "Field".
  8. For the target field, select "Record Type ID".
  9. For this example, do not select a data transformation table. More information about data transformation tables is available in the following section.
  10. Click Save.

Send a Static Value to the Record Type Field

To create a mapping that sends a fixed value in a message to the target record type field:

  1. On the Message Types tab, click the name of the message type that contains the relationship you want to customize.
  2. In the Relationship & Mapping Details section, click Manage Relationship and select the publication and subscription that make up the relationship.
  3. Click Add Mapping.
  4. Enter a message key that describes the information you are sending. For example, Record Type.
  5. For the source type, select "Static".
  6. For the source description, enter a description of the fixed data you want to send for this key. For example, Fixed Record Type.
  7. For the source data, enter the exact record type name you want to send. This is the data that you want to store in the target field. For example, MessagingRecord.
  8. Leave the target type as "Field".
  9. For the target field, select "Record Type ID".
  10. For this example, do not select a data transformation table. More information about data transformation tables is available in the following section.
  11. Click Save.

Transform a Value to Be Suitable for the Target Record Type

For both options described above, you can transform the source data to better suit the target, if required.

This is useful in the following scenarios:

  • If the source and target objects contain comparable record types with different names
  • If the message contains a static record type value that needs to change depending on the subscription in the relationship

To do this, you must have a data transformation table set up that contains the source and target values you want to transform. When creating the mapping, you can specify the relevant data transformation table. For more information, see Data Transformation Tables.