Loading
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          Import Data from Salesforce Objects to Use in Constraint Models

          Import Data from Salesforce Objects to Use in Constraint Models

          Import data from a standard or custom Salesforce object to use in a table constraint in a constraint model. The imported data populates the columns and rows in the table constraint in CML, and saves you the step of manually entering the data.

          Required Editions

          Available in: Lightning Experience
          Available in: Enterprise, Performance, Unlimited, and Developer Editions of Revenue Cloud with the Revenue Cloud Growth license or the Revenue Cloud Advanced license
          User Permissions Needed
          To import object data: Product Configuration Constraints Designer permission set

          Only the first 10,000 records with a maximum of 10 custom fields from the Salesforce object are imported.

          1. In Setup, enter Permission Sets in Quick Find and select Permission Sets.
          2. Select the Constraint Rules Engine Licenseless permission set. If the Constraint Rules Engine Licenseless permission set for the Platform Integration User isn't available in your org, contact Salesforce Customer Support.
          3. In the Apps section of the setup page for Constraint Rules Engine Licenseless permission set, select Object Settings.
          4. Locate and select the object whose data you want to import to a table constraint.
          5. On the Object Settings page for the object, select Edit. Enable Read, Create, Edit, Delete, View All Records, and View All Fields permissions, then save your changes.
          6. To confirm that the permissions are enabled, open Object Manager and select the object whose data you want to import.
          7. Select Object Access. On the Permission Sets tab, confirm that the Constraint Rules Engine Licenseless permission set is listed, with Read, Create, Edit, and Delete permissions enabled.
          8. To load the imported data into a constraint, in CML Editor, write an expression in the constraint model code. Use the SalesforceTable keyword and include the table name and column names.
          Example
          Example

          In this example, data is imported to a table with four columns. The suffix __c indicates that the data is from a Salesforce custom object.

          constraint(table(attr1, attr2, attr3, attr4, SalesforceTable("tablename__c","column1name__c,column2name__c,column3name__c,column4name__c")));

          Note
          Note If the table data is deployed when the constraint model is activated, and you add records to the table after constraint model activation, to fetch the new table data at runtime you must deactivate and reactivate the constraint model.
           
          Loading
          Salesforce Help | Article