diff options
| author | Mike Bayer <mike_mp@zzzcomputing.com> | 2016-09-19 16:22:08 -0400 |
|---|---|---|
| committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2016-09-19 16:22:08 -0400 |
| commit | 8c3b9d6083709311c6125d812b242f9e31a90065 (patch) | |
| tree | 1f20251a4a05e5d4d91b173098b0029445fcbc97 /lib/sqlalchemy/sql | |
| parent | 881369b949cff44e0017fdc28d9722ef3c26171a (diff) | |
| download | sqlalchemy-8c3b9d6083709311c6125d812b242f9e31a90065.tar.gz | |
Support bindparam() with callable for primaryjoin
Fixes the comparison of bindparam() objects based on
the "callable" parameter being present which helps to correctly
detect use_get, and also checks for "callable" when detecting
parameters for value substitution and will not impact the
object if present.
Change-Id: I4c93ee5d404d2648dd9835beeae0c5fb67e37d19
Fixes: #3767
Diffstat (limited to 'lib/sqlalchemy/sql')
| -rw-r--r-- | lib/sqlalchemy/sql/elements.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/sqlalchemy/sql/elements.py b/lib/sqlalchemy/sql/elements.py index cff57372c..768574c1a 100644 --- a/lib/sqlalchemy/sql/elements.py +++ b/lib/sqlalchemy/sql/elements.py @@ -1145,7 +1145,8 @@ class BindParameter(ColumnElement): return isinstance(other, BindParameter) \ and self.type._compare_type_affinity(other.type) \ - and self.value == other.value + and self.value == other.value \ + and self.callable == other.callable def __getstate__(self): """execute a deferred value for serialization purposes.""" |
