A table called table1 has a field called field1 with null values in it. This query does not return any rows:
SELECT *
FROM table1
WHERE field1 NOT IN
(
SELECT field1
FROM table1
)
I know there are better ways of writing this query. What causes this behaviour i.e. using not in with a field that contains null values.