Skip to content

Commit

Permalink
Merge pull request dbcli#1341 from dbcli/fix-csv-status
Browse files Browse the repository at this point in the history
Show status in csv format.
  • Loading branch information
amjith authored Sep 2, 2022
2 parents f858c4d + 318cdb9 commit abc03c5
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 2 additions & 0 deletions changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,8 @@ Bug fixes:
----------

* Fix the bug with Redshift not displaying word count in status ([related issue](https://github.com/dbcli/pgcli/issues/1320)).
* Show the error status for CSV output format.


3.4.0 (2022/02/21)
==================
Expand Down
4 changes: 2 additions & 2 deletions pgcli/main.py
Original file line number Diff line number Diff line change
Expand Up @@ -1585,8 +1585,8 @@ def format_status(cur, status):

output = itertools.chain(output, formatted)

# Only print the status if it's not None and we are not producing CSV
if status and table_format != "csv":
# Only print the status if it's not None
if status:
output = itertools.chain(output, [format_status(cur, status)])

return output
Expand Down

0 comments on commit abc03c5

Please sign in to comment.