my database field int_ParentId consist of a Null value . how would i check it for a null in this linq query . it is not working
return _db.Categories.Wher
Have you mapped you int_ParentId database field to int? type (e.g. )? If yes, both:
int_ParentId
int?
return _db.Categories.Where(m => m.int_ParentId == null);
and
return _db.Categories.Where(m => m.int_ParentId.HasValue);
should work.