Engaging Networks Mapping

From EN Salesforce Integration
Jump to: navigation, search

How this tool works

This tool provides the mechanism to specify the rules for managing Import and Export Mappings. This piece is the core of the connector and is where the rules for creating/update 'Contacts', 'Lead', "Opportunity' sObject etc. are set.

Legend

Overview of the Engaging Networks Mapping page


1. Name of the mapping

2. Sync direction

The two options available are 'Pull From EN' and 'Push To EN'.

Pull From EN instructs the connector to process the staging sObjects of Engaging Networks Import Records. Whilst the name sounds as though it is connecting to Engaging Networks and pulling records directly, its actual function is to search inside the list of Engaging Networks Import Record objects for those that match the specified 'Pull Query Filter'.


Push To EN instructs the connector that generate a CSV file and push it to Engaging Networks. More information can be found on the Engaging Networks Mapping + Push to EN

3. Batch Size

Set the batch size for the Engaging Networks Import Records, which match the Pull Query filter, at processing time. This can help if governor limits are preventing certain objects from being created, due to a high number of workflows or lookups. If this field is blank, the tool will use the default value set under the Pull Batch Size field on Custom settings: Engaging Network Settings


4. Create / Update options

The two options available are 'Create' and 'Create or Update' and this setting instructs how the processing engine interacts with existing objects.


The 'Create' setting was bundled with the first phase development of the connector. Its base function is obviously to create objects. However, if the target sObject is a Contact or Lead - an additional setting can be enabled to prevent duplicates.

If "Apply Rule to Avoid Duplicate Records" is enabled, the processor will use the value found in EN_Connector__supporter_email__c to check if a Contact/Lead already exists with that email address.


The 'Create or Update' setting was a later addition to the connector (1.35.3) and enables the processing engine to 'update or create', leveraging Salesforce's native de-duplicate toolset as the initial hook. If the processing engine encounters that the sObject trying to be created is triggering a 'de-duplication' warning - it will update the sObject instead.


5. Auto Update Field

Setting this parameter will write back the 'sObject ID', of the newly created sObject, back to the respective Engaging Networks Import Record staging object.

Why this is useful is a) it indicates which Engaging Networks Import Record have been processed (for that rule) and b) subsequently creates a way to stop those records from being re-processed by the same mapping.

In the example, you will see that SFDC Contact ID is set in both the Auto Update Field and the Query Filter. This creates a logic loop which means only 'new' records would be processed.

Leaving this parameter blank however, will set the record to processed = TRUE. This is recommended when 'attaching' sObjects, like an Opportunity.

Subsequently, all Processed = TRUE Engaging Networks Import Record are then ignored and won't be included in processing.

Rule of thumb - always use this when creating Contact (Id -> sfdc_contact_id__c) and Lead (Id -> sfdc_lead_id__c) objects.


6. Apply Rule to Avoid Duplicate Records

If "Apply Rule to Avoid Duplicate Records" is enabled and combined with the 'Create' option, the processor will use the value found in EN_Connector__supporter_email__c to check if a Contact/Lead already exists with that email address.


7. Manually Process Mapping

Trigger this mapping to process. This will be used frequently in testing and setup as well as processing batches, which may have either been missed or failed.

8. Query Filters

Specify the query rules that this mapping will use to find the relevant Engaging Network Import Records.

In the example, as the mapping is creating Contact objects, the query filter is finding Engaging Networks Import Record object where 'SFDC Contact ID' is empty and that Last Name is not empty.

Last name != blank is a useful addition in that Salesforce's own creation rule for Contacts is that a last name must be present.

The SFDC Contact ID filter rule is also important here in that it is concluding that this mapping should only find 'supporters that have not been created in Contacts'. The assumption here is that SFDC Contact ID would be populated if a) the contact was create and the ID written back to the Engaging Networks Import Record object or b) this Contact had been push to Engaging Networks previously and thus the SFDC Contact ID is already populated.


9. Filter Logic

Filter logic allows you to change the default AND behavior, and thus adds flexiblity in filters by including an OR option.


10. Decode values

This option allows values to be replaced on processing. For example, if First Name is Jim - then JIMM!!! would be used instead. See Decode values for a further understanding on how this process works.


11. Field Mapping

Map the information found on the Engaging Networks Import Record to fields on the relevant sObject.

For example, a supporter has submitted a single gift through a donation page. From the transactional data standpoint - this would be an 'FCS' transaction. This means an Engaging Networks Import Record would be created where EN_Connector_type__c = FCS.

More than likely EN_Connector_first_name__c, EN_Connector_first_name__c and EN_Connector_email_address__c is populated too. EN_Connector_data4__c holds the amount of the donation and EN_Connector_data2__c the transaction id.

With this data being held on the Engaging Networks Import Record object, the information can be mapped to fields on the Contact object. In the example, it can be seen that First Name (EN_Connector_first_name__c) is mapped to First Name.

It is thus important that the information that is required on the Contact/Opportunity, is first available on the Engaging Networks Import Record. This means that if Home Phone is a requirement, the data must be there and a question of 'is it being captured on pages'


12. Mapping Field Values

Set the field values, on the Engaging Networks Import Record object, to be populated on the relevant sObject.


13. Field mappings used for the 'Import/Pull from En' process


14. Field mappings used for the 'Export/Push to En' process

Additional Notes

For 13. and 14 - the UI is admittedly a little confusing, as both 'Import' and 'Export' mappings are on the page. This may be solved in a future release where 'Import' mapping are only shown where 'Pull from EN' is set etc.