Example #1
0
        protected override Expression VisitSubquery(DbSubqueryExpression subquery)
        {
            var saveOrderings = this.gatheredOrderings;

            this.gatheredOrderings = null;
            var result = base.VisitSubquery(subquery);

            this.gatheredOrderings = saveOrderings;
            return(result);
        }
Example #2
0
 protected override Expression VisitSubquery(DbSubqueryExpression subquery)
 {
     if ((subquery.NodeType == (ExpressionType)DbExpressionType.Scalar ||
          subquery.NodeType == (ExpressionType)DbExpressionType.In) &&
         subquery.Select != null)
     {
         System.Diagnostics.Debug.Assert(subquery.Select.Columns.Count == 1);
         MarkColumnAsUsed(subquery.Select.Alias, subquery.Select.Columns[0].Name);
     }
     return(base.VisitSubquery(subquery));
 }
        protected override Expression VisitSubquery(DbSubqueryExpression subquery) 
        {
            if ((subquery.NodeType == (ExpressionType)DbExpressionType.Scalar ||
                subquery.NodeType == (ExpressionType)DbExpressionType.In) &&
                subquery.Select != null) 
            {
                System.Diagnostics.Debug.Assert(subquery.Select.Columns.Count == 1);
                MarkColumnAsUsed(subquery.Select.Alias, subquery.Select.Columns[0].Name);
            }
 	        return base.VisitSubquery(subquery);
        }
Example #4
0
        protected virtual Expression VisitSubquery(DbSubqueryExpression subquery)
        {
            switch ((DbExpressionType)subquery.NodeType)
            {
            case DbExpressionType.Scalar:
                return(VisitScalar((DbScalarExpression)subquery));

            case DbExpressionType.Exists:
                return(VisitExists((DbExistsExpression)subquery));

            case DbExpressionType.In:
                return(VisitIn((DbInExpression)subquery));
            }
            return(subquery);
        }
        protected virtual bool CompareSubquery(DbSubqueryExpression a, DbSubqueryExpression b)
        {
            if (a.NodeType != b.NodeType)
            {
                return(false);
            }

            switch ((DbExpressionType)a.NodeType)
            {
            case DbExpressionType.Scalar:
                return(CompareScalar((DbScalarExpression)a, (DbScalarExpression)b));

            case DbExpressionType.Exists:
                return(CompareExists((DbExistsExpression)a, (DbExistsExpression)b));

            case DbExpressionType.In:
                return(CompareIn((DbInExpression)a, (DbInExpression)b));
            }
            return(false);
        }
 protected override Expression VisitSubquery(DbSubqueryExpression subquery)
 {
     // don't count aggregates in subqueries
     return(subquery);
 }
 protected virtual Expression VisitSubquery(DbSubqueryExpression subquery)
 {
     switch ((DbExpressionType)subquery.NodeType)
     {
         case DbExpressionType.Scalar:
             return VisitScalar((DbScalarExpression)subquery);
         case DbExpressionType.Exists:
             return VisitExists((DbExistsExpression)subquery);
         case DbExpressionType.In:
             return VisitIn((DbInExpression)subquery);
     }
     return subquery;
 }
 protected override Expression VisitSubquery(DbSubqueryExpression subquery)
 {
     // don't count aggregates in subqueries
     return subquery;
 }
 protected override Expression VisitSubquery(DbSubqueryExpression subquery)
 {
     // don't gather inside scalar & exists
     return subquery;
 }
 protected override Expression VisitSubquery(DbSubqueryExpression subquery)
 {
     return subquery;
 }
Example #11
0
 protected override Expression VisitSubquery(DbSubqueryExpression subquery)
 {
     // don't gather inside scalar & exists
     return(subquery);
 }
 protected override Expression VisitSubquery(DbSubqueryExpression subquery)
 {
     var saveOrderings = this.gatheredOrderings;
     this.gatheredOrderings = null;
     var result = base.VisitSubquery(subquery);
     this.gatheredOrderings = saveOrderings;
     return result;
 }
 protected override Expression VisitSubquery(DbSubqueryExpression subquery)
 {
     return(subquery);
 }
        protected virtual bool CompareSubquery(DbSubqueryExpression a, DbSubqueryExpression b)
        {
            if (a.NodeType != b.NodeType)
                return false;

            switch ((DbExpressionType)a.NodeType)
            {
                case DbExpressionType.Scalar:
                    return CompareScalar((DbScalarExpression)a, (DbScalarExpression)b);
                case DbExpressionType.Exists:
                    return CompareExists((DbExistsExpression)a, (DbExistsExpression)b);
                case DbExpressionType.In:
                    return CompareIn((DbInExpression)a, (DbInExpression)b);
            }
            return false;
        }