Mail Merge for Custom Entity in Sage CRM

Mail merge is a word processing document which contains fixed text, which will be the same in each output document, and variables, which act as placeholders that are replaced by text from the data source.
Whenever we create a custom entity using advanced customization wizard, the ‘Has Library’ and ‘Has Communication’ check boxes must be checked for the mail merge functionality to work. Otherwise it will give an error message ‘Mail Merge is only allowed for entities that have a library and communications’ when we click on start mail merge button in document tab of the custom entity.


To fix this error, we should execute the following update query
update Custom_Tables set Bord_HasLibrary='Y',Bord_HasCommunication='Y' where Bord_Name='entity name'

Then refresh the metadata from the following path:

Administration -> System -> Metadata

After this we can check the mail merge functionality.


Using the above solution mail merge functionality will start working perfectly for the custom entity.