DISTINCT and GROUP BY
Jun 3rd, 2009 by sherlock Hit :: 236
A DISTINCT and GROUP BY usually generate the same query plan, so performance should be the same across both query constructs.
Use “Group by” when you use aggregate query, and “DISTINCT” when you want to distinct values.
Essentially it is just a matter of syntax in this case, the end result should be same.
Comment ::
Many said that “DISTINCT” executes faster than the “GROUP BY” clause. Couse GROUP BY performs appropriate sorting before returning the results.