3
My scenario is as follows:
I have the Activity table
I need to mount a select, taking the values from the row table, however I need to exclude from the row the values that already exist in the activity table. If the activity table already exists the URL 976 and USER 96 , ai in select it would skip this line. Based on the image, the row select would return only Ids 975 and 973
I tried that way, but I couldn’t:
SELECT *
FROM fila f
WHERE NOT EXISTS
(
SELECT NULL FROM atividade a
WHERE a.url = f.idlinks
AND a.usuario = f.usuario
AND a.url = f.idlinks and a.usuario = 96
)
Thanks in advance, thank you.
Possible duplicate of How to create Mysql search that returns lines without matching?
– Bacco