/// <summary> /// Sum /// </summary> /// <param name="expression">表达式树</param> /// <returns>SqlBuilderCore</returns> public SqlBuilderCore <T> Sum(Expression <Func <T, object> > expression) { this._sqlPack.Clear(); this._sqlPack.IsSingleTable = true; SqlBuilderProvider.Sum(expression.Body, this._sqlPack); return(this); }
/// <summary> /// Sum /// </summary> /// <param name="expression">表达式树</param> /// <param name="sqlPack">sql打包对象</param> /// <returns>SqlPack</returns> public override SqlPack Sum(UnaryExpression expression, SqlPack sqlPack) { SqlBuilderProvider.Sum(expression.Operand, sqlPack); return(sqlPack); }