Is there a way to do something like this:
//Create Connection.
NMBSReportViewer.Models.SchoolEntities db = new NMBSReportViewer.Models.SchoolEntities();
//Get the Data Using the Report's Stored QueryString.
String QueryString = report.Query; //"SELECT VALUE c FROM SchoolEntities.Courses AS c WHERE c.Credits > 0";
IQueryable<dynamic> data = db.CreateQuery<dynamic>(QueryString);
//Given String FieldName, String Operator, & String Value, from user, Filter the Above dataset.
data.Where(c => c.'FieldName' 'Operator' 'Value');
I’m assuming there’s nothing like I have above, but is there a way to achieve the same end result?
I am going to have Dropdownlists of the Fields and operators for the user and then they will input a value they want in a textbox for the three values, so the FieldName is should always be a viable field in the set.
Is there a way in LINQ to do such a thing?
If there isn’t a way to do that…
Is there a way to create an IQueryable with a static type of “SchoolEntities.Course” given just the string?
Sorry for the Confusion, I guess Entity Framework wasn’t an option after all.
In the end I guess I’ll have to use this approach in order to maintain the freedom from redeploying the project everytime the database gains or loses a table.
Thank you for the help and information. Sorry it wasn’t entirely a clear question.