I have implemented as search function on my website that uses 1 table using the following function.
Search function
[HttpPost]
public ActionResult Results(string SearchString)
{
using (var objCtx = new ApplicationDbContext())
{
var Restaurant = from u in objCtx.Restaurants
select u;
if (!String.IsNullOrEmpty(SearchString))
{
Restaurant = Restaurant.Where(s => s.Name.Contains(SearchString));
}
return View(Restaurant.ToList());
}
}
Is it possible to extend this function so that it can search through multiple tables without using a search engine such as Lucene.net?
Any help would be greatful.