trying to make a generic SQL Query via a method that will fetch data i was making this code 

public ObjectResult&lt;theSelectedTableNameModel&gt; getUsersRes(string sqlStr, string ColNameAsfilter, string FiltersValue,string OrderByFilter="")
{
    string SqlCmd = "";
    string By = "";
    if (OrderByFilter.isNotEmptyOrNull())
       By = string.Concat(" ORDER BY ", OrderByFilter);
    SqlCmd = string.Format("{0} WHERE {1}={2}{3}", SqlStr, ColNameAsfilter, FiltersValue, By);


    return anEntityName.ExecuteStoreQuery&lt;theSelectedTableNameModel&gt;(SqlCmd);
}


i have copied my code and edited real names and other variables /parameters so i might have made a mistake, but the question is , how could i make it more generic than this ?

this is a working approach that lets me specify the query of the sqlCommand

i wanted it to fit any entity and any model/object/table 

how could it be done ? 
i guess there's a ready solution for this or the engeniring of EF not ment to be generic...
i'm using asp.net 4.0 , and latest EF..


Question: How to know which edition a DotNetNuke site is
Answer: 
Log into the site with the Host account
Mouseover Host from the navigation menu - select Host Settings from the dropdown
Version should be the second row, Edition first row


Mine says
DotNetNuke Product: DotNetNuke Community Edition 
DotNetNuke Version: 04.09.05