From 03671e9ee4c13f4d7e98ec4a5076fd9c9979e44d Mon Sep 17 00:00:00 2001 From: Alex Gaynor Date: Wed, 25 Sep 2013 10:29:52 -0700 Subject: Replace a big loop + dict lookup in Connection.execute() with a simple visitor pattern --- lib/sqlalchemy/sql/elements.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'lib/sqlalchemy/sql/elements.py') diff --git a/lib/sqlalchemy/sql/elements.py b/lib/sqlalchemy/sql/elements.py index 92cbc3653..ea2132e67 100644 --- a/lib/sqlalchemy/sql/elements.py +++ b/lib/sqlalchemy/sql/elements.py @@ -292,6 +292,9 @@ class ClauseElement(Visitable): # self return self + def _execute_on_connection(self, connection, multiparams, params): + return connection._execute_clauseelement(self, multiparams, params) + def unique_params(self, *optionaldict, **kwargs): """Return a copy with :func:`bindparam()` elements replaced. -- cgit v1.2.1