Skip to content

Commit

Permalink
[dbmanager] fixes #17476: QGIS master: update SQL layer error if name…
Browse files Browse the repository at this point in the history
… contains uppercase chars
  • Loading branch information
slarosa committed Nov 21, 2017
1 parent b2c6464 commit ea7c2af
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions python/plugins/db_manager/dlg_sql_layer_window.py
Expand Up @@ -154,9 +154,9 @@ def __init__(self, iface, layer, parent=None):
if not sql.startswith('(') and not sql.endswith(')'):
schema = uri.schema()
if schema and schema.upper() != 'PUBLIC':
sql = 'SELECT * FROM ' + schema + '.' + sql
sql = 'SELECT * FROM {0}.{1}'.format(self.db.connector.quoteId(schema), self.db.connector.quoteId(sql))
else:
sql = 'SELECT * FROM ' + sql
sql = 'SELECT * FROM {0}'.format(self.db.connector.quoteId(sql))
self.editSql.setText(sql)
self.executeSql()

Expand Down

0 comments on commit ea7c2af

Please sign in to comment.