Nullable fields strange behaviour
Posted: Wed 14 Dec 2011 09:53
I found a strange behaviour :
I have a nullable bit field in MS SQL.
The value is null.
If i have a query :
(from i in Table
orderby i.Marketid
where i.nullablefield != true)
it does not return any records.
I have to do
(from i in Table
orderby i.Marketid
where i.nullablefield == false || i.nullablefield == null)
It seems like a bug for me.
I have a nullable bit field in MS SQL.
The value is null.
If i have a query :
(from i in Table
orderby i.Marketid
where i.nullablefield != true)
it does not return any records.
I have to do
(from i in Table
orderby i.Marketid
where i.nullablefield == false || i.nullablefield == null)
It seems like a bug for me.