Assuming mythz will probable be the source on this, so thank you in advance.
I make frequent use of IdBConnection.Query<T>(string SQL, object anon) in much of my existing code. I'm trying to move forward to 4.0.12 and running into problems as it appears .Query is no longer supported.
Can you let me know what method I should be using for something like the following:
public override List<DBOs.Matters.Matter> GetList(Rest.Requests.Matters.Matter request, IDbConnection db)
{
string filterClause = "";
if (!string.IsNullOrEmpty(request.Title))
filterClause += " LOWER(\"title\") like '%' || LOWER(@Title) || '%' AND";
//return db.Query<DBOs.Matters.Matter>(
// "SELECT * FROM \"matter\" WHERE" + filterClause,
// new { Title = request.Title });
db.SqlList<DBOs.Matters.Matter>(
return db.Query<DBOs.Matters.Matter>("SELECT * FROM \"matter\" JOIN \"secured_resource_acl\" ON " +
"\"matter\".\"id\"=\"secured_resource_acl\".\"secured_resource_id\" " +
"WHERE " + filterClause +
"\"secured_resource_acl\".\"allow_flags\" & 2 > 0 " +
"AND NOT \"secured_resource_acl\".\"deny_flags\" & 2 > 0 " +
"AND \"matter\".\"utc_disabled\" is null " +
"AND \"secured_resource_acl\".\"utc_disabled\" is null",
new { Title = request.Title });
}