diff options
author | Mike Bayer <mike_mp@zzzcomputing.com> | 2009-10-21 04:47:02 +0000 |
---|---|---|
committer | Mike Bayer <mike_mp@zzzcomputing.com> | 2009-10-21 04:47:02 +0000 |
commit | 5a140299b3ec6c7d800484fd6b5acedacc4aabb7 (patch) | |
tree | 80cc5623b6281f6cec568b82764e4affdefab4f3 /lib/sqlalchemy/engine/ddl.py | |
parent | 7dddcd140339509fb3d208a37eb1ac0f1ea3aa3a (diff) | |
download | sqlalchemy-5a140299b3ec6c7d800484fd6b5acedacc4aabb7.tar.gz |
- Corrected the "has_sequence" query to take current schema,
or explicit sequence-stated schema, into account.
[ticket:1576]
Diffstat (limited to 'lib/sqlalchemy/engine/ddl.py')
-rw-r--r-- | lib/sqlalchemy/engine/ddl.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/sqlalchemy/engine/ddl.py b/lib/sqlalchemy/engine/ddl.py index 6e7253e9a..f5cff1a20 100644 --- a/lib/sqlalchemy/engine/ddl.py +++ b/lib/sqlalchemy/engine/ddl.py @@ -66,7 +66,7 @@ class SchemaGenerator(DDLBase): if ((not self.dialect.sequences_optional or not sequence.optional) and (not self.checkfirst or - not self.dialect.has_sequence(self.connection, sequence.name))): + not self.dialect.has_sequence(self.connection, sequence.name, schema=sequence.schema))): self.connection.execute(schema.CreateSequence(sequence)) def visit_index(self, index): @@ -124,5 +124,5 @@ class SchemaDropper(DDLBase): if ((not self.dialect.sequences_optional or not sequence.optional) and (not self.checkfirst or - self.dialect.has_sequence(self.connection, sequence.name))): + self.dialect.has_sequence(self.connection, sequence.name, schema=sequence.schema))): self.connection.execute(schema.DropSequence(sequence)) |