From: Rodrigo Menezes Date: Tue, 26 Aug 2014 17:02:19 +0000 (-0400) Subject: Removed changes that are no longer necessary for postgresql_relkind. Also, removed... X-Git-Tag: rel_1_0_0b1~70^2~84^2~4^2~3 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d39be884321d0afbae7ef3da556382b53fef8060;p=thirdparty%2Fsqlalchemy%2Fsqlalchemy.git Removed changes that are no longer necessary for postgresql_relkind. Also, removed newline changes. --- diff --git a/lib/sqlalchemy/dialects/postgresql/base.py b/lib/sqlalchemy/dialects/postgresql/base.py index 206a25d284..40b2f60ae9 100644 --- a/lib/sqlalchemy/dialects/postgresql/base.py +++ b/lib/sqlalchemy/dialects/postgresql/base.py @@ -1781,7 +1781,7 @@ class PGDialect(default.DefaultDialect): }) ] - reflection_options = ('postgresql_ignore_search_path',) + reflection_options = ('postgresql_ignore_search_path', ) _backslash_escapes = True @@ -2019,7 +2019,6 @@ class PGDialect(default.DefaultDialect): schema_where_clause = "n.nspname = :schema" else: schema_where_clause = "pg_catalog.pg_table_is_visible(c.oid)" - query = """ SELECT c.oid FROM pg_catalog.pg_class c @@ -2435,6 +2434,7 @@ class PGDialect(default.DefaultDialect): # cast indkey as varchar since it's an int2vector, # returned as a list by some drivers such as pypostgresql + IDX_SQL = """ SELECT i.relname as relname, diff --git a/lib/sqlalchemy/engine/reflection.py b/lib/sqlalchemy/engine/reflection.py index afe9a8b3e2..012d1d35dd 100644 --- a/lib/sqlalchemy/engine/reflection.py +++ b/lib/sqlalchemy/engine/reflection.py @@ -378,6 +378,7 @@ class Inspector(object): use :class:`.quoted_name`. """ + return self.dialect.get_indexes(self.bind, table_name, schema, info_cache=self.info_cache, **kw) @@ -404,6 +405,7 @@ class Inspector(object): .. versionadded:: 0.8.4 """ + return self.dialect.get_unique_constraints( self.bind, table_name, schema, info_cache=self.info_cache, **kw) @@ -571,7 +573,7 @@ class Inspector(object): conname, link_to_name=True, **options)) # Indexes - indexes = self.get_indexes(table_name, schema, **table.dialect_kwargs) + indexes = self.get_indexes(table_name, schema) for index_d in indexes: name = index_d['name'] columns = index_d['column_names']