diff options
author | Mike Bayer <mike_mp@zzzcomputing.com> | 2007-06-06 23:37:18 +0000 |
---|---|---|
committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2007-06-06 23:37:18 +0000 |
commit | a74da6d21e7f5f2dd31dbaa8bc6cbf11e165360e (patch) | |
tree | 850032d13dfd5bc2a7a142d237bb20143f97f91b /lib/sqlalchemy/sql.py | |
parent | 72113780f3a88c2ae8c8e568b4833702c72c5788 (diff) | |
download | sqlalchemy-a74da6d21e7f5f2dd31dbaa8bc6cbf11e165360e.tar.gz |
- fixed bug where selectable.corresponding_column(selectable.c.col)
would not return selectable.c.col, if the selectable is a join
of a table and another join involving the same table. messed
up ORM decision making [ticket:593]
Diffstat (limited to 'lib/sqlalchemy/sql.py')
-rw-r--r-- | lib/sqlalchemy/sql.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/sqlalchemy/sql.py b/lib/sqlalchemy/sql.py index fb32c0f07..3a8a27d67 100644 --- a/lib/sqlalchemy/sql.py +++ b/lib/sqlalchemy/sql.py @@ -1670,7 +1670,9 @@ class FromClause(Selectable): it merely shares a common anscestor with one of the exported columns of this ``FromClause``. """ - + if column in self.c: + return column + if require_embedded and column not in util.Set(self._get_all_embedded_columns()): if not raiseerr: return None |