We have a simple database and we are trying to retrieve db records asynchronously with EntityFramework in an MVC5 application like so:
var result = await dbcontext.Emails.Where(e=>e.name.StartsWith("ask")).ToListAsync;
return View(result);
OR
var result = dbcontext.Emails.Where(e=>e.name.StartsWith("ask"));
return View(await result.ToListAsync());
However we do not even get the option of using the ToListAsync (only ToList) even though the Where clause produces an IQueryable. We are using EF6 of course. Any help would be greatly appreciated.