Create A Batch Merge

2.2.2 | 1/4/2024

Step 1: Prerequisites | Step 2: Define Your Use Case and Conditions | Step 3: Build A Routine | Step 4: Test Routine

Generate A Batch Of Documents At Once

If you’ve ever found the process of generating documents one at a time to be time-consuming, you’re not alone. Fortunately, Mambo Merge offers a series of solutions that help speed up workflows. The “Batch” merge, allows you to generate multiple documents simultaneously with just a single click. Create documents for each record that meet specific conditions and save the merged docs into their respective individual records. In this guide, we’ll walk you through a typical use case using the Opportunities Object, showcasing how this method can greatly enhance your DocOps needs. Let’s dive in!

Step 1: Prerequisites

Before diving in make sure to complete the following checklist.

1.1 Install a “Mambo Component” within the Object page you plan to merge documents.
1.2 Know how to use “Template Builder” to create a template.
1.3 Know how to build a “Routine” and “Merge Button.”
1.4 Have our “Full Speed” edition installed.

Note: We recommend to complete the list above before you proceed.

Step 2: Define Your Use Case and Conditions

You need to identify what use case you are trying to generate documents for and what conditions must be met within each record to merge the data of that record to the template.

2.1 Our use case will include the “Opportunities” Object and create a “VIP Contract” document for all records that are under the stage “Negotiation/Review” and are valued at an amount of "$100K or more."

We will use a List View to sort all the records that Mambo Merge will generate a document once the conditions above have been met.

Note: Records that do not meet these conditions will not have documents merged and saved.

Step 3: Build A Routine

With our use case and conditions defined, we can begin to build out the routine that will traverse all the records within the Opportunities Object and generate a document if the conditions are met within each record.

3.1 Head over to an “Opportunities” record and locate the “Mambo Component” installed.

3.2 Click on the “Down Arrow” and select “Studio” from the drop-down.

3.3 Within the Studio click on “New Routine” to launch the wizard.

3.4 The “Records Selection” screen will be configured by using the following settings. Remember, depending on your use case the “Primary Salesforce Object” and “Filter” options will need to be changed.

Primary Salesforce Object: Opportunity
Records Selection: Records Where
Filter 1 (Field | Operator | Value): Stage Name | = | Negotiation/Review
Filter 2 (Field | Operator | Value): Amount | > | $100,000.00
Filter Logic: 1 AND 2
Order by: Name | Ascending

Once all settings are confirmed, press “Next” to proceed.

3.5 Because we do not need to define any “Relationships” we can skip this section by clicking “Next.”

3.6 Since we already have a template ready to use we won’t need the “Merge Data” screen, however, if we need to adjust our Template we can always use this screen to ensure the correct merge fields are defined in our template. Will skip this screen by pressing “Next” to proceed.

We will be using a “Simple VIP Contract” Template with a simple set of instructions to welcome them as a new client during the last steps of the negotiation.

Note: Remember to Ignore All squiggly line errors to avoid having Mambo Merge create issues during a merge.

3.7 Now we can configure our Template with the following settings. Once again, based on your use case these settings will change.

-Template: (Upload or Add A Template)
-Template File: (Displays The File Name Uploaded or Added)
-Merge Type: One Document Per Record
-Label: VIP Contract
-Destination: Attach to Each Record
-Generated File Name: vip contract

Once you have configured your template click “Next” to proceed.

3.8 Because we do not plan to use “Backup Dancers” we can skip this screen and click “Next.”

3.9 On this last screen, we can finalize the Routine by defining the following settings. These settings will also change based on your use case.

Routine ID: VIP
Description: (Provide A Short Description)
Display Type: Buttons
Preview: (Quick Preview of Component)

Once you are ready click “Save” to complete the Routine and exit the Studio.

Step 4: Test Routine

Now that we have the Routine built, we can assign it to the component and test it out to make sure all records that meet the conditions have their documents generated and saved accordingly.

4.1 Head back to your Opportunities record, where you first started, and click on the “Gear Icon” to select “Edit Page” from the drop-down.

4.2 Within the Lightning App Builder head over to the “Mambo Component” and click on it to open its component settings. From there type in or paste the “Routine ID” (From the previous step) within the “Template ID” field and press the “Tab” key to have Mambo Merge assign the Routine to the component. Click on “Save” and then the “Back Arrow” to exit the builder and apply these settings.

4.3 Once we return to the record page you will notice the component now has the action button “VIP Contract” which it did not before. Proceed to press the button to initiate the component.

4.4 Once the Mambo component completes all the merged documents, a prompt will appear on the top portion of the screen.

4.6 Heading back to our Opportunities List View we noticed some of the records have amounts that do not meet the conditions. We can validate those records to make sure Mambo Merge did not generate docs and proceed to the records where both conditions were met to ensure the “vip contract” doc was generated and stored within each record.

4.7 Looking at the List View we can choose the “United Oil SLA” opportunity to validate that our merged document was created and saved.

Upon checking we can see that the document was created and saved. Repeat these steps with a few more records just to make sure and remove any doubt.

Note: Every time the VIP Contact button is pressed within the component a new version of the merged document is created while preserving the original one.

What’s Your Use Case For Batch Merges?

Share with us your use cases to help identify what is the best way Mambo Merge can help generate your documents.

Back to Top