示例#1
0
        /// <summary>
        /// Execute the given query and returns the result as a read only list
        /// </summary>
        public static IReadOnlyList <T> ToList <T>(this ISqlQuery <T> select, NpgsqlConnection conn)
        {
            var sql  = select.ToSql();
            var pars = NpgsqlParamLogic.GetParams(sql.Params);

            return(NpgsqlMapper.Query <T>(conn, sql));
        }