Is there a cleaner way to perform this query in MySQL?
SELECT * FROM table WHERE id != 1 AND id != 2 AND id != 7
like:
SELECT * FROM table WHERE id != (1,2,7)
SELECT * FROM table WHERE id NOT IN (1,2,7)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With