Original table
+-- Col 1 --+-- Col 2 --+
+-- 1 --+-- a --+
+-- 1 --+-- b --+
+-- 1 --+-- c --+
+-- 2 --+-- d --+
+-- 3 --+-- e --+
+-- 3 --+-- f --+
+-----------------------+
Result :
+-- Col 1 --+-- Col 2 --+
+-- 1 --+-- a --+
+-- 2 --+-- d --+
+-- 3 --+-- e --+
+-----------------------+
Any idea how to distinct the table?
“DISTINCT” applies to every column in the result set.
A “GROUP BY” will provide the result you require, but you need to think about whether “col2” has any real meaning in your result set.