diff --git a/docs/en_US/release_notes_9_5.rst b/docs/en_US/release_notes_9_5.rst index a83355095..abd66d41f 100644 --- a/docs/en_US/release_notes_9_5.rst +++ b/docs/en_US/release_notes_9_5.rst @@ -21,6 +21,7 @@ New features ************ | `Issue #1926 `_ - Add a new permission to allow disabling "Change Password" feature for a pgAdmin role. + | `Issue #3319 `_ - Added support to preserve the workspace, query windows, and pgAdmin state during an abrupt shutdown or restart. | `Issue #8665 `_ - Supports JSON logging for gunicorn process within Docker. Housekeeping @@ -34,3 +35,4 @@ Bug fixes | `Issue #7466 `_ - Fixed an issue where utilities such as pg_dump and pg_restore failed to log error messages when required dependency files were missing. | `Issue #8032 `_ - Fixed an issue where the Schema Diff Tool incorrectly reported differences due to variations in the order of the privileges. | `Issue #8691 `_ - Fixed an issue in the query tool where using multiple cursors to copy text resulted in only the first line being copied. + | `Issue #8809 `_ - Fixed an issue where data export using a query failed when the query contained a newline character. diff --git a/web/pgadmin/tools/import_export/__init__.py b/web/pgadmin/tools/import_export/__init__.py index 3303ec6e2..971247f40 100644 --- a/web/pgadmin/tools/import_export/__init__.py +++ b/web/pgadmin/tools/import_export/__init__.py @@ -355,6 +355,10 @@ def create_import_export_job(sid): # Remove unwanted keys from data update_data_for_import_export(data) + # Replace "\n" with " " as it is not working on Windows. + if 'query' in data: + data['query'] = data['query'].replace("\n", " ") + # Create the COPY FROM/TO from template temp_path = 'import_export/sql/#{0}#/cmd.sql'.format(manager.version) query = render_template(temp_path, conn=conn, data=data, columns=cols,