Problem with LINQ Where Clause
Posted
by Krishma
on Stack Overflow
See other posts from Stack Overflow
or by Krishma
Published on 2010-03-25T19:39:50Z
Indexed on
2010/03/25
19:43 UTC
Read the original article
Hit count: 382
LINQ
var results = from formNumber in context.DetailTM join c in context.ClaimPeriodTM on formNumber.ClaimPeriod equals c.Cid where formNumber.FormNumber.StartsWith(fNumber) && formNumber.RegistrationNumber != registrationNumber select new { RegNo = formNumber.RegistrationNumber, CP = c.ClaimPeriod, FormNo = formNumber.FormNumber };
The AND CLAUSE with .STARTSWITH Doesn't work. If I use == operator the query works fine. I tried adding brackets to the where clause but it didn't help. Any idea what is missing. Thank you in Advance.
© Stack Overflow or respective owner