Fix an issue where select, insert and update scripts on tables throwing an error. Fixes #5074.

This commit is contained in:
Akshay Joshi 2020-01-09 18:23:23 +05:30
parent 093d7af748
commit be4b8284c5
3 changed files with 24 additions and 3 deletions

View File

@ -11,6 +11,7 @@ notes for it.
.. toctree::
:maxdepth: 1
release_notes_4_18
release_notes_4_17
release_notes_4_16
release_notes_4_15

View File

@ -0,0 +1,20 @@
************
Version 4.18
************
Release date: 2020-02-06
This release contains a number of bug fixes and new features since the release of pgAdmin4 4.17.
New features
************
Housekeeping
************
Bug fixes
*********
| `Issue #5074 <https://redmine.postgresql.org/issues/5074>`_ - Fix an issue where select, insert and update scripts on tables throwing an error.

View File

@ -1307,7 +1307,7 @@ class TableView(BaseTableView, DataTypeReader, VacuumSettings):
# Now we have all list of columns which we need
if 'columns' in data:
for c in data['columns']:
columns.append(self.qtIdent(self.conn, c['attname']))
columns.append(self.qtIdent(self.conn, c['name']))
if len(columns) > 0:
columns = ", ".join(columns)
@ -1353,7 +1353,7 @@ class TableView(BaseTableView, DataTypeReader, VacuumSettings):
# Now we have all list of columns which we need
if 'columns' in data:
for c in data['columns']:
columns.append(self.qtIdent(self.conn, c['attname']))
columns.append(self.qtIdent(self.conn, c['name']))
values.append('?')
if len(columns) > 0:
@ -1400,7 +1400,7 @@ class TableView(BaseTableView, DataTypeReader, VacuumSettings):
# Now we have all list of columns which we need
if 'columns' in data:
for c in data['columns']:
columns.append(self.qtIdent(self.conn, c['attname']))
columns.append(self.qtIdent(self.conn, c['name']))
if len(columns) > 0:
if len(columns) == 1: