I have the following query which should return no rows, but returns 4:
var testAgainst = db.MyForm1_hosps.Select(ta => ta.recordId == recordId); If I use the following query I get zero rows as expected:
var testAgainst = from ta in db.MyForm1_hosps where ta.recordId == recordId select ta; There ARE four rows in MyForm1_hosp but none match the recordId in my test.
The code doesn't lie, so my understanding of LINQ is incorrect. Can someone explain to me why the first one returns 4 rows when it should return 0?
db.MyForm1_hosps.Where(ta => ta.recordId == recordId);