private async Task <IEnumerable <string> > GetDistinctRequestUrls(Filters filters)
        {
            var sql = "SELECT DISTINCT RequestUrl FROM HttpStatusResult";

            sql += CreateWhereClause(filters.NullRequestUrl(), out var sqlParams);

            var requestUrls = await _dbConnection.QueryAsync <string>(sql, sqlParams);

            return(_service.SelectUniqueRequests(requestUrls));
        }
Example #2
0
        public async Task <string[]> GetDistinctRequestUrls(string method)
        {
            var sqlParams = new Dictionary <string, object>();

            var sql = "SELECT DISTINCT RequestUrl FROM HttpStatusResult";

            if (!string.IsNullOrEmpty(method))
            {
                sql += " WHERE Method = @method";
                sqlParams.Add("method", method);
            }

            var requestUrls = await _dbConnection.QueryAsync <string>(sql, sqlParams);

            return(_service.SelectUniqueRequests(requestUrls).ToArray());
        }