public List<string> GetRecords(List<string> Columns,string tablename) { using (var Context = new MCPEntities()) { string columnnames = string.Join(",", Columns); var Records = Context.Database.SqlQuery<string>("SELECT " + columnnames + " FROM " + tablename + " ").ToList(); return Records.ToList(); } }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)