- 增加 HavingIf 方法;#1095

This commit is contained in:
2881099
2022-05-06 12:40:06 +08:00
parent 41432cde0a
commit ae1b053189
2 changed files with 9 additions and 1 deletions

View File

@ -226,6 +226,7 @@ namespace FreeSql.Internal.CommonProvider
return this;
}
public ISelectGrouping<TKey, TValue> HavingIf(bool condition, Expression<Func<ISelectGroupingAggregate<TKey, TValue>, bool>> exp) => condition ? Having(exp) : this;
public ISelectGrouping<TKey, TValue> Having(Expression<Func<ISelectGroupingAggregate<TKey, TValue>, bool>> exp)
{
_lambdaParameter = exp?.Parameters[0];