summaryrefslogtreecommitdiff
path: root/lib/sqlalchemy/sql
diff options
context:
space:
mode:
authorMike Bayer <mike_mp@zzzcomputing.com>2009-08-31 20:38:14 +0000
committerMike Bayer <mike_mp@zzzcomputing.com>2009-08-31 20:38:14 +0000
commit3d38969fd4f88d996d438df63f7cbb1833b63429 (patch)
tree33f33709c5abcfad827bcc0460f9a51558e36542 /lib/sqlalchemy/sql
parentf3480a7ff4d0994bf201f830f31f416a7b1e9f0f (diff)
downloadsqlalchemy-3d38969fd4f88d996d438df63f7cbb1833b63429.tar.gz
- Inserting NULL into a primary key + foreign key column
will allow the "not null constraint" error to raise, not an attempt to execute a nonexistent "col_id_seq" sequence. [ticket:1516] - autoincrement SELECT statements, i.e. those which select from a procedure that modifies rows, now work with server-side cursor mode (the named cursor isn't used for such statements.)
Diffstat (limited to 'lib/sqlalchemy/sql')
-rw-r--r--lib/sqlalchemy/sql/compiler.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/lib/sqlalchemy/sql/compiler.py b/lib/sqlalchemy/sql/compiler.py
index 78529ee6d..7bd0c1b05 100644
--- a/lib/sqlalchemy/sql/compiler.py
+++ b/lib/sqlalchemy/sql/compiler.py
@@ -844,8 +844,7 @@ class SQLCompiler(engine.Compiled):
self.dialect.supports_sequences or
not isinstance(c.default, schema.Sequence)
)
- ) or \
- self.dialect.preexecute_autoincrement_sequences:
+ ) or self.dialect.preexecute_autoincrement_sequences:
values.append((c, self._create_crud_bind_param(c, None)))
self.prefetch.append(c)