Duplicate Returns.

  • Thread starter Thread starter Andrew
  • Start date Start date
A

Andrew

Sometimes when I do a query, I get the record listed twice (or more) after
hitting Run. The records aren't duplicated in the table, so why am I getting
two results?
 
If your query uses multiple tables with one-to-many relations, the records
from the ONE side of the relation will appear on as many rows as there are
records in the related table.

For example, if you have tables for Customers, Invoices, and Payments. If an
invoice was paid in 2 instalments, the invoice will appear twice because
there are 2 payments for it.
 
Thanks. I thought of that as soon as I posted this.

Is there any easy way to tell Access to only list each record once? Even if
there is multiple entries in another table?
 
Create a query on just the other table. In that query, GROUP BY the field
that should appear once only, and choose First or Sum or whatever for the
other field(s.)

Then use that query as an input 'table' for your main query, instead of the
problem table. Since it only has ONE record for each key field, you won't
get duplicated records.
 
Back
Top