public SqlQuery <T> GetQuery <T>(Func <ISqlResult, T> createResult) { if (SqlStatement == null) { throw new ArgumentNullException("SqlStatement"); } if (!ResultColumnNames.Any()) { throw new ArgumentException("Must specify result columns for SqlQuery"); } return(new SqlQuery <T>(createResult, SqlQueryCache.Get(this))); }