diff options
author | mike bayer <mike_mp@zzzcomputing.com> | 2021-11-07 21:19:45 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@ci3.zzzcomputing.com> | 2021-11-07 21:19:45 +0000 |
commit | 201c00bc0837af831f115e8313ad3ccb0be97e7a (patch) | |
tree | beb7558e95d073b63fa4bb76d830ccaa2de9711a /lib/sqlalchemy/sql/elements.py | |
parent | 5b1c9053b0903b2d5a06f82b47fe16a870696ddc (diff) | |
parent | d050193daaa8d91371c759296f3304b8641c1976 (diff) | |
download | sqlalchemy-201c00bc0837af831f115e8313ad3ccb0be97e7a.tar.gz |
Merge "fully implement future engine and remove legacy" into main
Diffstat (limited to 'lib/sqlalchemy/sql/elements.py')
-rw-r--r-- | lib/sqlalchemy/sql/elements.py | 26 |
1 files changed, 4 insertions, 22 deletions
diff --git a/lib/sqlalchemy/sql/elements.py b/lib/sqlalchemy/sql/elements.py index c8faebbd9..a279f634d 100644 --- a/lib/sqlalchemy/sql/elements.py +++ b/lib/sqlalchemy/sql/elements.py @@ -29,7 +29,6 @@ from .base import Executable from .base import HasMemoized from .base import Immutable from .base import NO_ARG -from .base import PARSE_AUTOCOMMIT from .base import SingletonConstant from .coercions import _document_text_coercion from .traversals import HasCopyInternals @@ -319,11 +318,11 @@ class ClauseElement( return d def _execute_on_connection( - self, connection, multiparams, params, execution_options, _force=False + self, connection, distilled_params, execution_options, _force=False ): if _force or self.supports_execution: return connection._execute_clauseelement( - self, multiparams, params, execution_options + self, distilled_params, execution_options ) else: raise exc.ObjectNotExecutableError(self) @@ -1755,9 +1754,6 @@ class TextClause( _is_textual = True _bind_params_regex = re.compile(r"(?<![:\w\x5c]):(\w+)(?!:)", re.UNICODE) - _execution_options = Executable._execution_options.union( - {"autocommit": PARSE_AUTOCOMMIT} - ) _is_implicitly_boolean = False _render_label_in_columns_clause = False @@ -1860,19 +1856,8 @@ class TextClause( :func:`_expression.text` is also used for the construction of a full, standalone statement using plain text. As such, SQLAlchemy refers - to it as an :class:`.Executable` object, and it supports - the :meth:`Executable.execution_options` method. For example, - a :func:`_expression.text` - construct that should be subject to "autocommit" - can be set explicitly so using the - :paramref:`.Connection.execution_options.autocommit` option:: - - t = text("EXEC my_procedural_thing()").\ - execution_options(autocommit=True) - - .. deprecated:: 1.4 The "autocommit" execution option is deprecated - and will be removed in SQLAlchemy 2.0. See - :ref:`migration_20_autocommit` for discussion. + to it as an :class:`.Executable` object and may be used + like any other statement passed to an ``.execute()`` method. :param text: the text of the SQL statement to be created. Use ``:<param>`` @@ -5044,9 +5029,6 @@ class CollationClause(ColumnElement): class _IdentifiedClause(Executable, ClauseElement): __visit_name__ = "identified" - _execution_options = Executable._execution_options.union( - {"autocommit": False} - ) def __init__(self, ident): self.ident = ident |