This article describes how to merge rows in batches in order to overcome error messages such as:
1. Service Documents failed while accessing document with ID [Google Doc ID], when merging many rows into a single document and Google cannot handle the load.
2. NetworkConnection failure due to HTTP 0, when emails sent with personalized PDF attachments take a long time to send.
In Google Sheets, create a new column and name it whatever you want (e.g., Merged).
In Google Docs, click on Options in the Mail Merge sidebar to open the Options dialog box.
Select the Merged column from the Track Merged Rows and Merge Specific Rows drop-down menus.
This enables Mail Merge add-on to track which rows have been merged.
Set the Batch Size to as many rows as you need to merge at once.
Batches of 50 or 80 are recommended to make sure the mail merge occurs smoothly.
Click on Save to apply the changes.
Select Letters from the Merge To list, and then click on Merge to merge the first batch.
NOTE: Once the first batch is merged, you need to manually click on Merge again to merge the next batch. Repeat until all batches are merged.
Select the To Letters tab and enter the Batch Size number.
Click the Merge Letters button to start merging the first batch.
NOTE: Once the first batch is merged, you need to manually click on Merge Letters again to merge the next batch. Repeat until all batches are merged.