server/sources/rql2sql.py
branchstable
changeset 9324 a5ce068143ad
parent 9230 a68b2fe8a800
child 9361 0542a85fe667
--- a/server/sources/rql2sql.py	Wed Oct 30 13:05:00 2013 +0100
+++ b/server/sources/rql2sql.py	Fri Oct 25 12:23:06 2013 +0200
@@ -486,13 +486,10 @@
             return relation._q_sqltable
         rid = 'rel_%s%s' % (relation.r_type, self.count)
         # relation's table is belonging to the root scope if it is the principal
-        # table of one of it's variable and if that variable belong's to parent
+        # table of one of its variable and that variable belong's to parent
         # scope
         for varref in relation.iget_nodes(VariableRef):
             var = varref.variable
-            if isinstance(var, ColumnAlias):
-                scope = 0
-                break
             # XXX may have a principal without being invariant for this generation,
             #     not sure this is a pb or not
             if var.stinfo.get('principal') is relation and var.scope is var.stmt: