Browse Source

Fixed SQL content filter on IMonitoringApi.PostgreSql.cs

master
Mateus Viegas 3 years ago
parent
commit
e10658063e
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      src/DotNetCore.CAP.PostgreSql/IMonitoringApi.PostgreSql.cs

+ 1
- 1
src/DotNetCore.CAP.PostgreSql/IMonitoringApi.PostgreSql.cs View File

@@ -81,7 +81,7 @@ namespace DotNetCore.CAP.PostgreSql


if (!string.IsNullOrEmpty(queryDto.Group)) where += " and Lower(\"Group\") = Lower(@Group)"; if (!string.IsNullOrEmpty(queryDto.Group)) where += " and Lower(\"Group\") = Lower(@Group)";


if (!string.IsNullOrEmpty(queryDto.Content)) where += " and \"Content\" ILike concat('%',@Content,'%')";
if (!string.IsNullOrEmpty(queryDto.Content)) where += " and \"Content\" ILike @Content";


var sqlQuery = var sqlQuery =
$"select * from {tableName} where 1=1 {where} order by \"Added\" desc offset @Offset limit @Limit"; $"select * from {tableName} where 1=1 {where} order by \"Added\" desc offset @Offset limit @Limit";


Loading…
Cancel
Save