Hi and thanks for any help, I created a query based on 2 tables and for some
reason i have duplicate rows. What is the cleanest way to delete duplicate
rows?
is it to place "distinctrow" after the SELECT?
Thanks a lot!
Be careful about "DELETE" in this context. A Query has no independent
existance. Deleting a row from a Query will delete it (permanently and
irrevokably) from the underlying Table.
What exactly are you seeing? If you have two tables in a one to many
relationship, a Query joining the two tables will show as many repeats of the
record in the "one" table as there are matching records in the "many". This
isn't duplication, or redundancy; it's exactly how such queries are designed
and intended to work! Are the records in fact duplicate in all fields?
You can set the Unique Values property of a query to show each duplicate
record only once (based on the fields that you show as visible in the query);
this query will not be updateable though.
John W. Vinson [MVP]