Rachel already showed you what you can do (Master-Detail Mail Merge) with a generic calculated field like DOCVARIABLE. I want to take it a bit further and show you how to create a custom field.
Would you like to embed a chart into your documents? 

Field Code:
Switches:
- \c – Specifies the chart type. Supported charts are bar, pie and line. If not specified defaults to pie.
- \l – This switch determines if the chart should display a legend.
- \w – Specifies the chart width
- \h – Specifies the chart height
- \d – Comma separated data points
Example:
{CHART \c pie \w 500 \h 300 \l \d "Asia|4140336501,Africa|994527534,Europe|738523843,North America|528720588,South America|385742554,Oceania|36102071,Antarctica|3687"}
Download the source code
Cheers
Azret