Mail merge

From Wikipedia, the free encyclopedia

Mail merge is a computer term describing the production of multiple (and potentially large numbers of) documents from a single template form and a structured data source. This technique is used to create personalised letters and pre-addressed envelopes or mailing labels for mass mailings from a database mailing list of names and addresses.

The procedure of mail merging is typically carried out using a word processing program. The template is a word processing document which contains

  • fixed text that will be the same in each output document
  • variables which act as placeholders to be replaced by text from the data source.

The data source is typically a spreadsheet or a database which has a field or column matching each variable in the template. When the mail merge is run, the word processing system creates an output document for each row in the database, using the fixed text exactly as it appears in the template, but substituting the data variables in the template with the values from the matching columns.

For example, a company may want to send letters confirming places at a set of events. The template will be laid out as the required letter, explaining to each recipient that their place is confirmed and detailing instructions for the event. The data variables will be used to specify the recipient's name, address, first name for the salutation and perhaps a seat number and the name and date of the specific event they are booked to attend. These variables can be placed anywhere in the template document, within a paragraph of text or on their own. When the mail merge is run, each letter will be personalised to the recipient and will show the information that is applicable to them.

This technique of merging data to create mailshots gave rise to the term mail merge.

In other languages