SQL Server Management Studio で次のクエリを実行すると、132 行のデータが取得されます。正解です。
select *
from cyc.contac con
where (con.note_turn is null) and
(con.cont_type <> '_') and
(con.cont_code <> 'D') and
(con.cont_type <> 'Q')
コードから次の Linq クエリを実行すると、11000 を超えるレコードが取得されます。これは正しくありません。linq クエリが where 句の制約によって制約されないのはなぜだろうと思っています。
var query = from contac in context.CONTACs
orderby contac.ID
where (contac.note_turn == null) &&
(contac.cont_type != "_") &&
(contac.cont_code != "D") &&
(contac.cont_type != "Q")
select contac;