NULL
is a special value in SQL denoting the absence of data. As such, you cannot do queries like:
SELECT fields FROM table WHERE column = NULL
NULL
cannot be compared to anything, including NULL
itself. Instead, you'd need:
SELECT fields FROM table WHERE column IS NULL
However in your case you are really inserting an empty value in Sex
and DOB
.
And empty value is not NULL
. You'd have to query for:
SELECT fields FROM table WHERE column = ''