From bebc9bee52a63ee7d4d84b07b451a40b5a79a948 Mon Sep 17 00:00:00 2001 From: lsv Date: Tue, 6 Aug 2024 15:55:40 +0500 Subject: [PATCH] Non-superusers are allowed to use the functions pg_conf_load_time,pg_postmaster_start_time MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Отключены проверки на суперпользователя для некоторых функций. --- schema/pgServer.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/schema/pgServer.cpp b/schema/pgServer.cpp index 2e4096c..6f9390c 100644 --- a/schema/pgServer.cpp +++ b/schema/pgServer.cpp @@ -892,7 +892,7 @@ int pgServer::Connect(frmMain *form, bool askPassword, const wxString &pwd, bool if (conn->BackendMinimumVersion(8, 1)) { hasUptime = true; - sql += wxT(", CASE WHEN usesuper THEN pg_postmaster_start_time() ELSE NULL END as upsince"); + sql += wxT(", pg_postmaster_start_time() as upsince"); } else if (conn->HasFeature(FEATURE_POSTMASTER_STARTTIME)) { @@ -901,7 +901,7 @@ int pgServer::Connect(frmMain *form, bool askPassword, const wxString &pwd, bool } if (conn->BackendMinimumVersion(8, 4)) { - sql += wxT(", CASE WHEN usesuper THEN pg_conf_load_time() ELSE NULL END as confloadedsince"); + sql += wxT(", pg_conf_load_time() as confloadedsince"); } if (conn->BackendMinimumVersion(8, 5)) {