Skip to content

Commit

Permalink
dbmanager: fix column renaming
Browse files Browse the repository at this point in the history
  • Loading branch information
jef-n committed Jul 10, 2013
1 parent 5592878 commit 3b6146f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion python/plugins/db_manager/db_plugins/postgis/connector.py
Expand Up @@ -783,7 +783,7 @@ def updateTableColumn(self, table, column, new_name=None, data_type=None, not_nu
if self.has_geometry_columns and not self.is_geometry_columns_view:
schema, tablename = self.getSchemaTableName(table)
schema_where = u" f_table_schema=%s AND " % self.quoteString(schema) if schema is not None else ""
sql = u"UPDATE geometry_columns SET f_geometry_column=%s WHERE %s f_table_name=%s AND f_geometry_column=%s" % (self.quoteString(new_name), schema_where, self.quoteString(tablename), self.quoteString(name))
sql = u"UPDATE geometry_columns SET f_geometry_column=%s WHERE %s f_table_name=%s AND f_geometry_column=%s" % (self.quoteString(new_name), schema_where, self.quoteString(tablename), self.quoteString(column))
self._execute(c, sql)

self._commit()
Expand Down

0 comments on commit 3b6146f

Please sign in to comment.