From 9ae117e38808c0db54cfcf174914767c4d446ffb Mon Sep 17 00:00:00 2001 From: asfernandes Date: Thu, 27 Oct 2011 23:53:15 +0000 Subject: [PATCH] Fixed CORE-3611 - Wrong data while retrieving from CTEs (or derived tables) with same column names. --- src/dsql/pass1.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/dsql/pass1.cpp b/src/dsql/pass1.cpp index f991d85839..6dab04db40 100644 --- a/src/dsql/pass1.cpp +++ b/src/dsql/pass1.cpp @@ -1347,7 +1347,7 @@ bool PASS1_node_match(const dsql_nod* node1, const dsql_nod* node2, bool ignore_ { if (derivedField1 && derivedField2) { - if (derivedField1->scope != derivedField2->scope || + if (derivedField1->context->ctx_context != derivedField2->context->ctx_context || derivedField1->name != derivedField2->name) { return false;