I called this query on PostgreSQL and it returned the count of all table rows!
But why?
The ON part is always false then the result should be empty!
select
  count(*)
from
  skyroom_files f
  left join users u on f.user_id = u.id
  and f.id = -1;
I tried another values for the last part and it always returns the count of all rows!
 
     
     
    