How can I run a report based on two tables?

M

michaaal

Is it possible to run a report based on two tables?

I'll give you an example...

Table #1 contains these fields:

Customer Number
Customer First Name
Customer Last Name

Table #2 contains these fields:

Sales Order #
Customer Number (this item is a "no edit" combo box pulling its values from
the Customer Number in Table #1)

I would like to run a report which shows the Sales Order #, Customer First
Name, and Customer Last Name.

Is there a better way to do this?

Thank you!!!
 
A

Allen Browne

Create a query that contains both tables.

You should see a line joining the two tables on your [Customer Number]
field. If not, drag the field from one table onto the matching field from
the other table.

If you need to include all customers (even those with no orders)
double-click the join-line. Access gives you 3 options. Choose the one that
says:
All Customers, and any matching Orders.
More information on this "outer join":
http://allenbrowne.com/casu-02.html
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top