Is it possible to specify only certain fields from a table when using Linq and possible include a RecordSet count?
Here is my existing query within the HomeController.cs
var contentModel = from m in db.Contents where (m.NavigationId == 1) && (m.Active == true) orderby m.Position select m;
return View(contentModel);
I would like to include Id, Title, Image and Summary, set the maximum number of records within the recordset to 12 and return an extra value which is the actual number of records/12 and pass to the View.
Any help would be much appreciated :-)