diff options
author | Mike Bayer <mike_mp@zzzcomputing.com> | 2007-05-11 00:21:29 +0000 |
---|---|---|
committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2007-05-11 00:21:29 +0000 |
commit | 3de128138a896bc7373aa2684c920271c4781b7d (patch) | |
tree | 8ac21a6767187636e6243043b989be160cf52a7b /lib/sqlalchemy/sql.py | |
parent | 48648eedda50a84f5518ac2055286e1fde22fa00 (diff) | |
download | sqlalchemy-3de128138a896bc7373aa2684c920271c4781b7d.tar.gz |
- _Label propigates "_hide_froms()" so that scalar selects
behave more properly with regards to FROM clause #574
Diffstat (limited to 'lib/sqlalchemy/sql.py')
-rw-r--r-- | lib/sqlalchemy/sql.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/sqlalchemy/sql.py b/lib/sqlalchemy/sql.py index 0dcba3698..5adef46f2 100644 --- a/lib/sqlalchemy/sql.py +++ b/lib/sqlalchemy/sql.py @@ -2393,6 +2393,9 @@ class _Label(ColumnElement): def _get_from_objects(self): return self.obj._get_from_objects() + def _hide_froms(self): + return self.obj._hide_froms() + def _make_proxy(self, selectable, name = None): if isinstance(self.obj, Selectable): return self.obj._make_proxy(selectable, name=self.name) @@ -2829,7 +2832,7 @@ class Select(_SelectBaseMixin, FromClause): if self.is_scalar and not hasattr(self, 'type'): self.type = column.type - + # if the column is a Select statement itself, # accept visitor self.__correlator.traverse(column) |