MatchingRule

Represents a matching rule that is used to identify duplicate records.

A matching rule compares field values to determine whether a record is similar enough to existing records to be considered a duplicate. For example, a matching rule can specify that if the Email and Phone values of two records match exactly, the records are possible duplicates. Your organization uses matching rules with duplicate rules to define what happens when duplicates are identified.

If the rule is for a Person Account, SobjectSubType is automatically set to PersonAccount.

Introduced in API version 33.0.

describeSObjects(), query(), retrieve()

  • As of Summer ’20 and later, only users with the View Setup and Configuration permission can access this object.
  • Type: string
  • Properties: Filter, Group, Nillable, Sort
  • Description: Specifies filter logic conditions.
  • Type: textarea
  • Properties: Filter, Group, Nillable, Sort
  • Description: The description of the matching rule.
  • Type: string

  • Properties: Filter, Group, Sort

  • Description: The developer name for the matching rule.

    Only users with View DeveloperName OR View Setup and Configuration permission can view, group, sort, and filter this field.

  • Type: picklist
  • Properties: Filter, Group, Nillable, Restricted picklist, Sort
  • Description: The language selected for your organization.
  • Type: string
  • Properties: Filter, Group, Sort
  • Description: The name of the matching rule.
  • Type: picklist
  • Properties: Filter, Group, Nillable, Restricted picklist, Sort
  • Description: The match engine used by the matching rule.
  • Type: string
  • Properties: Filter, Group, Nillable, Sort
  • Description: The namespace prefix for matching rules for your organization.
  • Type: picklist

  • Properties: Defaulted on create, Filter, Group, Restricted picklist, Sort

  • Description:

    Required. The activation status of the matching rule. Values are:

    • Inactive
    • Deactivating
    • DeactivationFailed
    • Active
    • Activating
    • ActivationFailed

    The only valid values you can declare when deploying a package are Active and Inactive.

  • Type: picklist

  • Properties: Defaulted on create, Filter, Group, Nillable, Restricted picklist, Sort

  • Introduced: API version 39.0

  • Description:

    Read-only. Indicates if the matching rule is defined for the Person subtype of Account.

    If the rule is for a Person Account, SobjectSubType is automatically set to PersonAccount.

  • Possible values:

    • PersonAccount — PersonAccount
    • None — None
  • Type: picklist
  • Properties: Filter, Group, Restricted picklist, Sort
  • Description: The object for the matching rule.

Use the Salesforce API to retrieve and view details about MatchingRule and MatchingRuleItem. Use the Salesforce Metadata API to create, update, or delete these objects.