Skip to content

Commit

Permalink
Merge pull request #30712 from qgis/backport-30707-to-release-3_8
Browse files Browse the repository at this point in the history
[Backport release-3_8] [Bugfix] DB Mananger: Fix in Oracle plugin the way to strip uniqueCol
  • Loading branch information
rldhont committed Jul 15, 2019
2 parents 5aa55b0 + f198ab2 commit 893395d
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion python/plugins/db_manager/db_plugins/oracle/plugin.py
Expand Up @@ -203,8 +203,12 @@ def toSqlLayer(self, sql, geomCol, uniqueCol,
uri = self.uri()
con = self.database().connector

if uniqueCol is not None:
uniqueCol = uniqueCol.strip('"').replace('""', '"')

uri.setDataSource(u"", u"({}\n)".format(
sql), geomCol, filter, uniqueCol.strip(u'"'))
sql), geomCol, filter, uniqueCol)

if avoidSelectById:
uri.disableSelectAtId(True)
provider = self.dbplugin().providerName()
Expand Down

0 comments on commit 893395d

Please sign in to comment.