summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/sql/dml.py
diff options
context:
space:
mode:
authormike bayer <mike_mp@zzzcomputing.com>2017-01-13 15:41:20 -0500
committerGerrit Code Review <gerrit@awstats.zzzcomputing.com>2017-01-13 15:41:20 -0500
commit2c13aa097b3588a25173eb297eee08afd18f88d6 (patch)
tree2e25114ecf738ded9a3e050d970b7a5e3a639a60 /lib/sqlalchemy/sql/dml.py
parent0460bc79d9986132646049d8167bd5dbe3388a65 (diff)
parentfa6dd376bb24845724287d980a98ea50eb1cfab1 (diff)
downloadsqlalchemy-2c13aa097b3588a25173eb297eee08afd18f88d6.tar.gz
Merge "Support python3.6"
Diffstat (limited to 'lib/sqlalchemy/sql/dml.py')
-rw-r--r--lib/sqlalchemy/sql/dml.py26
1 files changed, 13 insertions, 13 deletions
diff --git a/lib/sqlalchemy/sql/dml.py b/lib/sqlalchemy/sql/dml.py
index cd58cbeb0..767e91350 100644
--- a/lib/sqlalchemy/sql/dml.py
+++ b/lib/sqlalchemy/sql/dml.py
@@ -92,13 +92,13 @@ class UpdateBase(
@_generative
def returning(self, *cols):
- """Add a :term:`RETURNING` or equivalent clause to this statement.
+ r"""Add a :term:`RETURNING` or equivalent clause to this statement.
e.g.::
- stmt = table.update().\\
- where(table.c.data == 'value').\\
- values(status='X').\\
+ stmt = table.update().\
+ where(table.c.data == 'value').\
+ values(status='X').\
returning(table.c.server_flag,
table.c.updated_timestamp)
@@ -206,7 +206,7 @@ class ValuesBase(UpdateBase):
@_generative
def values(self, *args, **kwargs):
- """specify a fixed VALUES clause for an INSERT statement, or the SET
+ r"""specify a fixed VALUES clause for an INSERT statement, or the SET
clause for an UPDATE.
Note that the :class:`.Insert` and :class:`.Update` constructs support
@@ -616,21 +616,21 @@ class Update(ValuesBase):
return_defaults=False,
preserve_parameter_order=False,
**dialect_kw):
- """Construct an :class:`.Update` object.
+ r"""Construct an :class:`.Update` object.
E.g.::
from sqlalchemy import update
- stmt = update(users).where(users.c.id==5).\\
+ stmt = update(users).where(users.c.id==5).\
values(name='user #5')
Similar functionality is available via the
:meth:`~.TableClause.update` method on
:class:`.Table`::
- stmt = users.update().\\
- where(users.c.id==5).\\
+ stmt = users.update().\
+ where(users.c.id==5).\
values(name='user #5')
:param table: A :class:`.Table` object representing the database
@@ -650,8 +650,8 @@ class Update(ValuesBase):
subquery::
users.update().values(name='ed').where(
- users.c.name==select([addresses.c.email_address]).\\
- where(addresses.c.user_id==users.c.id).\\
+ users.c.name==select([addresses.c.email_address]).\
+ where(addresses.c.user_id==users.c.id).\
as_scalar()
)
@@ -719,8 +719,8 @@ class Update(ValuesBase):
being updated::
users.update().values(
- name=select([addresses.c.email_address]).\\
- where(addresses.c.user_id==users.c.id).\\
+ name=select([addresses.c.email_address]).\
+ where(addresses.c.user_id==users.c.id).\
as_scalar()
)