In the past I was sure it was not possible in MySQL to use DISTINCT on multiple columns, such as below;
SELECT DISTINCT a,b FROM my_table;
and have in the past, instead used something similar to the below as a workaround;
SELECT DISTINCT CONCAT (a,' ', b) FROM my_table;
However, it seems I am remiss and MySQL does indeed support DISTINCT on multiple columns.
No comments:
Post a Comment
Note: only a member of this blog may post a comment.