Documentation/How Tos/Creating Mail Merge Documents From Text/CSV or Spreadsheets

From Apache OpenOffice Wiki
< Documentation‎ | How Tos
Revision as of 13:39, 23 June 2008 by Mwaller (Talk | contribs)

Jump to: navigation, search


This is all you need to do to make a nice simple document based on data in text files or spreadsheets.

Get Your Data

You probably already have it. It is in a .txt file or .csv that is comma or tab separated, perhaps. Or it is just a spreadsheet.


Make the Data Source: Text File Instructions

If your data is in text files, follow these steps.

  1. Choose File > New > Database.
  2. Select Connect to an existing database, with Text as the format.
  3. Click Next.
  4. Specify the directory where the text files are. Each text file in that directory will be a table in your database. Then select the item separating fields, i.e. a tab or comma or something else.
  5. When all the settings look correct, click Next.
  6. Unmark the option to open the database for editing. You can open it; you just do not have to.
  7. Click Finish.
  8. Save the data source (aka database) under a name that will help you remember what it is.


Make the Data Source: Spreadsheet Instructions

If your data is in a spreadsheet, follow these steps.

  1. Choose File > New > Database.
  2. Select Connect to an existing database, with Spreadsheet as the format.
  3. Click Next.
  4. Specify the spreadsheet file. Each sheet in that spreadsheet will be a table in your database.
  5. Click Next.
  6. Unmark the option to open the database for editing. You can open it; you just do not have to.
  7. Click Finish.
  8. Save the data source (aka database) under a name that will help you remember what it is.


Create Your Mail Merge Document and Suck the Data In From the Datasource

  1. Create a new Writer document or open a document containing text that you want in the mail merge document.
  2. Choose View > Data Sources. Everything you have created will be displayed.
  3. Click the + sign by the data source you want to use, then click + by Tables until you see the data you want to use.
  4. Type any content you want and do any formatting. You can do this later too.
  5. Click on the field name, not the piece of data, that you want in the mail merge.
  6. Drag it into the document and release. The field name will appear. When you print, the correct data will appear.
  7. Add any other content and fields you want.
  8. Save the document. You are ready to print.

Print the Mail Merge Document

1. Choose File > Print.

2. You will see a message asking you whether you want to print a form letter. Click Yes.

Documentation caution.png Do not mark the checkbox saying you do not want to see the message again.

3. In the Mail Merge window, specify the range of records, if you do not want them all. Select the first record, hold down Ctrl and select the next one, and so on.

4. Specify to print to a printer, or to files and click OK.

5. In the print window, specify the printer and click OK.


This How To comes from Solveig Haugland's Blog

Content on this page is licensed under the Public Documentation License (PDL).
Personal tools