Lookup Block Example

In this example of using a Lookup block, assume you want to migrate Leads from Salesforce into Accounts in a SQL database. If the Account already exists in SQL, you want to update it with the Lead data from Salesforce. If the Account doesn't exist in SQL, you want to create it. In addition, you want to replace the Salesforce Lead address information with Salesforce Account address in the Account record in SQL as each record is processed.

In this scenario, the Lookup Block is matching a Source Lead record with a Source Account record based on a matching field. The flow uses the results of the original Query and the results of the Lookup block to update an existing Target Account record or create a new Target Account record.

Lookup Block Example Block Configuration

Review the configuration information for each block in the flow to understand how the Lookup block is leveraged in this example.

Step 1: Query Block

Step 2: For Each Result Block

Step 3: Lookup Block

Step 4: If/Else Block

Step 5: Update Block

Step 6: Create Block

Related Topics

Lookup Block