Conditions in Writer's mail merge

Conditional Fields in merge

Conditions are a set of guidelines to evaluate the value in the merge field based on which you determine what to show on the merged document after running the merge. 

How to insert a condition?

We'll walk you through the process with a simple example. Let's say we are sending a welcome email to new members. Our welcome email has dynamic fields and if the value in the field - Membership type is Regular, the letter has to say "From now on, you get to enjoy unlimited services and benefits at just INR 250 per annum across Zylker!" 
If the field value is Student, it has to say "From now on, you get to enjoy unlimited services and benefits at just INR 125 per annum across Zylker!"

Step 1: Create a merge template. Click here to learn how. Insert necessary fields. To learn in detail about fields, refer help.
Step 2: Click Condition under Advanced Merge Fields. A pop up follows. 

Step 3: Select the field from the dropdown list for which you want to set a condition.
Step 4: Select the field type and a conditional operator. If the chosen field contains a date, set the field type to date and configure date format. 
Ensure that you choose the same date format as used in the data source. We've explained how conditions with date-type field work in detail here.

Step 5: Enter any text or value. The entered value acts as the criteria based on which the condition is evaluated. Please look at the given example.

Conditions for subforms

Generally, when you insert conditions, only the main fields are listed in the dropdown. For the subform fields to be listed, place the cursor anywhere on the subform region and then click Condition.

Show/hide table rows using conditions

With row conditions, you can show or hide a particular row on a table based on any logic. If a condition is not fulfilled, you can hide an entire row from the table. Let's see how to do this with an example. Zylker Pastries offers a 20% cash discount for products above INR 500 using row conditions. Refer the following steps to learn how.
Step 1: Create a merge template with multiple table rows.
Step 2: Place the cursor in the table cell where you want to apply this condition. In this example, the table row with Discount is where the condition should be applied.

Step 3: Now click Condition under "Advanced Merge Fields". In the pop up, check Row condition. Specify your condition and click Insert.

In the below preview, the first bill contains a product which costs more than INR 500 and therefore is eligible for a discount whereas the other bill contains a product which is less than INR 500 and therefore, no discount is availed.

Edit / Delete row condition   

To edit or delete the row condition that has been inserted, right click the table cell in which it has been inserted.
  1. Choosing Edit Row Condition opens a pop-up where you can make changes to the inserted condition.
  2. To delete a condition click Remove Row Condition.


    Zoho CRM Training Programs

    Learn how to use the best tools for sales force automation and better customer engagement from Zoho's implementation specialists.

    Zoho CRM Training
      Redefine the way you work
      with Zoho Workplace

        Zoho DataPrep Personalized Demo

        If you'd like a personalized walk-through of our data preparation tool, please request a demo and we'll be happy to show you how to get the best out of Zoho DataPrep.

        Zoho CRM Training

          Create, share, and deliver

          beautiful slides from anywhere.

          Get Started Now

            Get started with Zoho Sign

            in a few quick steps!

            Download Help Guide

                        Still can't find what you're looking for?

                        Write to us:



                          Zoho Marketing Automation

                            Zoho Sheet Resources


                                Zoho Forms Resources

                                  Secure your business
                                  communication with Zoho Mail

                                  Mail on the move with
                                  Zoho Mail mobile application

                                    Stay on top of your schedule
                                    at all times

                                    Carry your calendar with you
                                    Anytime, anywhere

                                          Zoho Sign Resources

                                            Sign, Paperless!

                                            Sign and send business documents on the go!

                                            Get Started Now

                                                Zoho SalesIQ Resources

                                                    Zoho TeamInbox Resources

                                                            Zoho DataPrep Resources

                                                              Zoho DataPrep Demo

                                                              Get a personalized demo or POC

                                                              REGISTER NOW

                                                                Design. Discuss. Deliver.

                                                                Create visually engaging stories with Zoho Show.

                                                                Get Started Now

                                                                                      • Related Articles

                                                                                      • How to use merge fields inside formula fields in a document ?

                                                                                        To use merge fields inside formula and enter your formula with merge field as shown below. During  merge Writer maps the values to the merge fields, executes the calculations and places the value in the document. Example : { =("Mergefield1" * ...
                                                                                      • How to map document merge fields with names in data source?

                                                                                        Field Mapping gives the ability to map merge fields of the document to the record names in the data source linked to the document before merging or sending them out for signature. If the document is connected to a different data source that uses ...
                                                                                      • How to check if the conditional field's value is empty?

                                                                                         To check if the conditional field's value is empty, follow the below steps.  Open the required document. Go to More Options (☰) > Automate > Select your data source > Conditions. The Set Conditions popup will open.  Use the IsEmpty comparison ...
                                                                                      • How to change the format of date type merge fields?

                                                                                        To change the format of date type merge fields before inserting into the document, follow the below steps: 1.  Click on the gear icon next to Manage Fields. 2. Now change the type of the field to date and click on Configure. 3. Now under Input ...
                                                                                      • How to create charts with merge fields data during merge?

                                                                                        Creating Charts from merge fields in now possible in Writer. Step 1 : Go to Form or Subform tab and choose Chart as shown Step 2:  Choose the Chart type and Fields containing data to populate charts and Click Insert. Step 3:  On Merge, data will be ...
                                                                                      Wherever you are is as good as
                                                                                      your workplace



                                                                                        Watch comprehensive videos on features and other important topics that will help you master Zoho CRM.


                                                                                        Download free eBooks and access a range of topics to get deeper insight on successfully using Zoho CRM.


                                                                                        Sign up for our webinars and learn the Zoho CRM basics, from customization to sales force automation and more.

                                                                                        CRM Tips

                                                                                        Make the most of Zoho CRM with these useful tips.

                                                                                          Zoho Show Resources