1.XPO中 聚合函数的使用(Count,Max,Sum,Min)
用Session中的Evaluate<>()方法
decimal sumPaid = (decimal)session.Evaluate<Order>(CriteriaOperator.Parse("Sum(OrderTotals)"),
new BinaryOperator("OrderDate", DateTime.Today.AddDays(-10), BinaryOperatorType.Greater));
new BinaryOperator("OrderDate", DateTime.Today.AddDays(-10), BinaryOperatorType.Greater));
欢迎转载,转载请注明出处:http://www.cnblogs.com/Tonyyang/