How to select just some fields from a table in EF
I have a table with 9 columns in database and I want to be able to load only some fields of it if I need. How can I do this with Entity Framework 4 please? e.g. My table has these fields: ID, FirstName, LastName, FotherName, BirthDate, Mobile, Email and I want to be able to fetch just these columns: ID, FirstName, LastName My project is an ASP.NET MVC 3 application, with SQLServer 2008 Express and EF 4.1 . Assume you have a table with this model: public class User{ public int ID {get; set;} public string NickName {get; set;} public string FirstName {get; set;} public string LastName {get; set;