Go Premium for a chance to win a PS4. Enter to Win

x
?
Solved

How do you set up a query that is used for mail merging where there is a one to many table relationship and I want to show multiple dependents of each person?

Posted on 2011-02-23
2
Medium Priority
?
330 Views
Last Modified: 2012-06-27
I have two tables that I want to use for a qeury to mail merge onto word documents.  There is the main employee table, and the dependents table.  I want to merge the employee information along with all the dependents each employee has.  How do I do that?
0
Comment
Question by:tlahpalli
2 Comments
 
LVL 120

Expert Comment

by:Rey Obrero (Capricorn1)
ID: 34961730
you create a query joining  the two table using a common field

select table1.* , table2.*
from table1
inner join table2
on table1.ID=table2.ID
0
 
LVL 31

Accepted Solution

by:
Helen Feddema earned 2000 total points
ID: 34961957
I like to use doc properties for the data in the main table, and TypeText into a Word table for the "many" records.  This allows expansion for as many rows as are needed, for example an invoice with order details.  See my Access Archon #44  for a discussion of this method, and a sample database.  Here is a link for downloading it (note that the sample database is in Access 97 format, so you may have to upgrade it):
http://www.helenfeddema.com/Files/accarch44.zip

And here is screen shot of the Word document produced by it:
Northwind-Invoice.jpg
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

If you need a simple but flexible process for maintaining an audit trail of who created, edited, or deleted data from a table, or multiple tables, and you can do all of your work from within a form, this simple Audit Log will work for you.
This article shows how to get a list of available printers for display in a drop-down list, and then to use the selected printer to print an Access report or a Word document filled with Access data, using different syntax as needed for working with …
Add bar graphs to Access queries using Unicode block characters. Graphs appear on every record in the color you want. Give life to numbers. Hopes this gives you ideas on visualizing your data in new ways ~ Create a calculated field in a query: …
Visualize your data even better in Access queries. Given a date and a value, this lesson shows how to compare that value with the previous value, calculate the difference, and display a circle if the value is the same, an up triangle if it increased…
Suggested Courses

824 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question