There are 2 tables: - User(id,pseudo) - Link(id1,id2), those 2 columns are FK on id User
I want to select all Users that have no link with the id = 10. That means I want all id of User but only if a Link(10, id2) doesn't exists.
I have try with a left join but the result is not OK
select distinct *
from USER
left join LINK on USER.id = LINK.id1
where LINK.id1 != 10