I’m working with a Informix DB and with a table like this:
Col1 Col2 Col3
a a a
b a c
c b a
d c d
Is it possible from the SQL statement to just display ONE of the first 2 rows by just specify only unique results (values can be anything). I only want one result from col2 with the same value and I don’t mind which one of the lines being retrieved.
I hope I’m making sense.
Assuming you have a tie-breaking column (a single-column primary key), you could use something like this