I am trying to get the DISTINCT value of a single column in a table. However, this column is INNER JOINED from another table via id .
When I try to use DISTINCT in a column, it gives the same results, because DISTINCT also takes into account the unique identifier identifier. Is there any work for this to just get the value of a DISTINCT column from a joined table ???
EG.
SELECT val1, b.val2, val3 FROM TABLE 1 JOIN (SELECT DISTINCT val2 FROM TABLE 2) AS b ON val1 = b.val2
source share