Query Returning Multiple Results

J

Jonathan Kramer

I have created two unrelated tables and created a query to return
fewer fields. However, whenever I run the query it returns 3,780
results. The original tables contain 46 and 660 records. When I sort
the query in Datasheet View the correct number of results is
displayed. It dosnt matter what field I sort by. What am I missing
here? Running Access 2007 on Windows 7. Thanks
 
K

Ken Snell

Unrelated tables implies that you have no join between the two tables. This
is what is called a CROSS JOIN, which also is referred to as a Cartesian
result for the query. Essentially, the query returns every record in the
first table "matched" to every record in the second table. Thus, if you have
5 records in the first table, and 10 records in the second table, your query
would show 50 records.

If you want fewer records than 3780 (this number implies that you have used
some filtering in your query, as the original tables in a cross join would
return 173,880 records), then you'll need to identify how to relate the two
tables together or how to filter out more records.
 

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