I'm confused, I've come across an issue I've not experienced before.
I have a table with columns including ID, ParentID, the first record (ID 1) does not have a ParentID so it is a NULL column, there will be other records in the table where ParentID is NULL.
I'm trying to select everything from the table; that works fine.... BUT when I try to filter it by only selecting all rows where ParentID is not equal to 3, it filters out all of the rows with a null value.
This is wrong as it isn't what i wanted it to do, I wanted everything except the records with a ParentID of 3, not everything except the records with a ParentID of NULL or 3....
Here's my query --
from dbo.MyPage P
where ParentID <> 3
order by P.ID
What have i missed here?