I have two tables, A and B, and I am trying to select rows from A based on a join query.
I am getting some records from these tables, but there are some duplicate entries. How should I filter this query to avoid duplicate rows? For now, I’m doing it via Java code by putting these into a HashSet.
I have two tables, A and B, and I am trying to select rows
Share
The keyword DISTINCT is used to eliminate duplicate rows from a query result:
However, you can sometimes (possibly even ‘often’, but not always) avoid the need for it if the tables are organized correctly and you are joining correctly.
To get more information, you are going to have to ask your question more clearly, with concrete examples.