rset.py
branchstable
changeset 8085 51929d531aff
parent 8048 10a0f73d834d
child 8087 dc788369d35f
--- a/rset.py	Thu Nov 10 23:18:56 2011 +0100
+++ b/rset.py	Wed Nov 16 22:07:27 2011 +0100
@@ -695,7 +695,7 @@
             continue
         if rootvar.name == rootmainvar.name:
             continue
-        if select is not rootselect:
+        if select is not rootselect and isinstance(rootvar, nodes.ColumnAlias):
             term = select.selection[root.subquery_selection_index(select, i)]
         var = _get_variable(term)
         if var is None: