diff --git a/docs/en_US/release_notes_9_4.rst b/docs/en_US/release_notes_9_4.rst index 0a18face2..93b1cdac7 100644 --- a/docs/en_US/release_notes_9_4.rst +++ b/docs/en_US/release_notes_9_4.rst @@ -34,6 +34,7 @@ Bug fixes | `Issue #6510 `_ - Fixed an issue where the result grid slowed down when any column contained a large amount of data. | `Issue #6564 `_ - Fix the issue where an error is displayed when a table is dropped while a query is running. | `Issue #6968 `_ - Fixed an issue where the options key was not working as expected in the PSQL tool. + | `Issue #7926 `_ - Fixed an issue where correct error message not displayed when sql statement contains Arabic letters. | `Issue #8595 `_ - Enhance contrast for selected and hovered items in the Object Explorer to improve visibility and accessibility. | `Issue #8607 `_ - Fixed an issue where the query tool returns "cannot unpack non-iterable Response object" when running any query with a database name change. | `Issue #8608 `_ - Handle result grid data changes in View/Edit Data mode by automatically reconnecting to the server if a disconnection occurs. diff --git a/web/pgadmin/tools/sqleditor/utils/apply_explain_plan_wrapper.py b/web/pgadmin/tools/sqleditor/utils/apply_explain_plan_wrapper.py index 54491df65..5c4fab5b1 100644 --- a/web/pgadmin/tools/sqleditor/utils/apply_explain_plan_wrapper.py +++ b/web/pgadmin/tools/sqleditor/utils/apply_explain_plan_wrapper.py @@ -34,7 +34,13 @@ def get_explain_query_length(query_obj): Args: query_obj: sql query """ - query = query_obj.query.decode() + try: + query = query_obj.query.decode() + except Exception: + try: + query = query_obj.query.decode('UTF-8') + except Exception: + query = query_obj.query.decode('UTF-8', errors='replace') if query.startswith("EXPLAIN"): return len(query) else: