mirror of
https://github.com/pgadmin-org/pgadmin4.git
synced 2025-02-25 18:55:31 -06:00
Use 'UPDATE pg_settings' for setting bytea_output as a
convenience hack for those running on old, unsupported versions of PostgreSQL 'cos we're nice like that.
This commit is contained in:
committed by
Dave Page
parent
11ab1918ea
commit
d92368f8e5
@@ -403,9 +403,13 @@ class Connection(BaseConnection):
|
||||
postgres_encoding, self.python_encoding = \
|
||||
getEncoding(self.conn.encoding)
|
||||
|
||||
# Note that we use 'UPDATE pg_settings' for setting bytea_output as a
|
||||
# convenience hack for those running on old, unsupported versions of
|
||||
# PostgreSQL 'cos we're nice like that.
|
||||
status = _execute(cur, "SET DateStyle=ISO; "
|
||||
"SET client_min_messages=notice;"
|
||||
"SET bytea_output=escape;"
|
||||
"UPDATE pg_settings SET setting = 'escape'"
|
||||
" WHERE name = 'bytea_output';"
|
||||
"SET client_encoding='{0}';"
|
||||
.format(postgres_encoding))
|
||||
|
||||
|
||||
Reference in New Issue
Block a user