Exemplo n.º 1
0
        protected internal virtual Expression VisitAggregateRequest(AggregateRequestsExpression request)
        {
            var ag = (AggregateExpression)this.Visit(request.Aggregate);

            if (ag != request.Aggregate)
            {
                return(new AggregateRequestsExpression(request.GroupByAlias, ag));
            }

            return(request);
        }
Exemplo n.º 2
0
        protected internal override Expression VisitAggregateRequest(AggregateRequestsExpression request)
        {
            var ag       = (AggregateExpression)this.Visit(request.Aggregate);
            var newAlias = aliasMap.TryGetC(request.GroupByAlias) ?? request.GroupByAlias;

            if (ag != request.Aggregate || request.GroupByAlias != newAlias)
            {
                return(new AggregateRequestsExpression(newAlias, ag));
            }

            return(request);
        }
Exemplo n.º 3
0
 protected internal override Expression VisitAggregateRequest(AggregateRequestsExpression aggregate)
 {
     throw InvalidSqlExpression(aggregate);
 }
Exemplo n.º 4
0
 protected virtual bool CompareAggregateSubquery(AggregateRequestsExpression a, AggregateRequestsExpression b)
 {
     return(Compare(a.Aggregate, b.Aggregate) &&
            a.GroupByAlias == b.GroupByAlias);
 }
Exemplo n.º 5
0
 protected internal override Expression VisitAggregateRequest(AggregateRequestsExpression aggregate)
 {
     this.aggregates.Add(aggregate);
     return(base.VisitAggregateRequest(aggregate));
 }
Exemplo n.º 6
0
 protected internal override Expression VisitAggregateRequest(AggregateRequestsExpression aggregate)
 {
     return(this.map.GetOrThrow(aggregate));
 }