Why shouldn't I use GROUP BY in place of DISTINCT when writing a query that does not contain an aggregate function?
What is the best practice?
Why shouldn't I use GROUP BY in place of DISTINCT when writing a query that does not contain an aggregate function?
What is the best practice?
If you only need to remove duplicates, use DISTINCT, since its usually faster. GROUP BY should be used when you are going to write aggregate operations/functions.
Also, not to be rude or anything but a simple search would have also gotten you the following results