ActiveRecord的ProjectionQuery

Castle.ActiveRecord.Queries.ProjectionQuery<CheckOutInfo> pq = new Castle.ActiveRecord.Queries.ProjectionQuery<RelationInfo>(
    criteria, Projections.ProjectionList()
    .Add(Projections.Sum(
"Quantity"))
    .Add(Projections.GroupProperty(
"ClassA"))
    .Add(Projections.GroupProperty(
"ClassB"))
);


需要作分组以及统计操作时,需要用到ProjectionQuery.

 

 

 

posted @ 2008-11-17 15:59  果果’er  阅读(289)  评论(1编辑  收藏  举报