summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/sql
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2013-07-12 12:14:50 -0400
committerMike Bayer <mike_mp@zzzcomputing.com>2013-07-12 12:15:39 -0400
commit3c363e125c461d08e9fe4a73ac8c5a3aa741eac6 (patch)
tree74c0a51038b3aeef7b7bad5ad32509ac1151b244 /lib/sqlalchemy/sql
parent6c85d5bc0c7f6a77ab6eec3e2571883ae2532601 (diff)
downloadsqlalchemy-3c363e125c461d08e9fe4a73ac8c5a3aa741eac6.tar.gz
- use inline=True for the insert..select here so it works on oracle
Diffstat (limited to 'lib/sqlalchemy/sql')
-rw-r--r--lib/sqlalchemy/sql/expression.py11
1 files changed, 11 insertions, 0 deletions
diff --git a/lib/sqlalchemy/sql/expression.py b/lib/sqlalchemy/sql/expression.py
index 7cb1326e2..45341bba7 100644
--- a/lib/sqlalchemy/sql/expression.py
+++ b/lib/sqlalchemy/sql/expression.py
@@ -6364,6 +6364,17 @@ class Insert(ValuesBase):
would normally raise an exception if these column lists don't
correspond.
+ .. note::
+
+ Depending on backend, it may be necessary for the :class:`.Insert`
+ statement to be constructed using the ``inline=True`` flag; this
+ flag will prevent the implicit usage of ``RETURNING`` when the
+ ``INSERT`` statement is rendered, which isn't supported on a backend
+ such as Oracle in conjunction with an ``INSERT..SELECT`` combination::
+
+ sel = select([table1.c.a, table1.c.b]).where(table1.c.c > 5)
+ ins = table2.insert(inline=True).from_select(['a', 'b'], sel)
+
.. versionadded:: 0.8.3
"""