1
I have the following tables
livro
id int pk
passador
id int pk
fk_livro_id int
ordem int
I am making a screen listing books. The goal is to bring all the books that are not registered in the dealer
I made the following query:
SELECT * FROM livro as l JOIN passador as p ON l.id != p.fk_livro_id AND like %?%
When I have at least one book registered in the dealer the search works normally, however when there is no book in the dealer the search always returns empty.
I recommend reading: Not IN or Not EXISTS which to use?
– Marconi