aboutsummaryrefslogtreecommitdiff
path: root/contrib/postgres_fdw
diff options
context:
space:
mode:
authorPeter Eisentraut <peter@eisentraut.org>2022-09-16 15:57:34 +0200
committerPeter Eisentraut <peter@eisentraut.org>2022-09-16 15:57:34 +0200
commit32b507378fac179717f093c78a0e70371fbdf514 (patch)
tree38b07f5a856d8d1060eb5e4446e47d85c63c34ca /contrib/postgres_fdw
parent5ac51c8c9e4434140f4ba45b7bdb38896b48cc64 (diff)
downloadpostgresql-32b507378fac179717f093c78a0e70371fbdf514.tar.gz
postgresql-32b507378fac179717f093c78a0e70371fbdf514.zip
postgres_fdw: Remove useless DO block in test
Discussion: https://www.postgresql.org/message-id/flat/b1f9f399-3a1a-b554-283f-4ae7f34608e2@enterprisedb.com
Diffstat (limited to 'contrib/postgres_fdw')
-rw-r--r--contrib/postgres_fdw/expected/postgres_fdw.out8
-rw-r--r--contrib/postgres_fdw/sql/postgres_fdw.sql6
2 files changed, 2 insertions, 12 deletions
diff --git a/contrib/postgres_fdw/expected/postgres_fdw.out b/contrib/postgres_fdw/expected/postgres_fdw.out
index ad0910e8672..2e4e82a94f1 100644
--- a/contrib/postgres_fdw/expected/postgres_fdw.out
+++ b/contrib/postgres_fdw/expected/postgres_fdw.out
@@ -9699,15 +9699,9 @@ ERROR: password is required
DETAIL: Non-superusers must provide a password in the user mapping.
-- If we add a password to the connstr it'll fail, because we don't allow passwords
-- in connstrs only in user mappings.
-DO $d$
- BEGIN
- EXECUTE $$ALTER SERVER loopback_nopw OPTIONS (ADD password 'dummypw')$$;
- END;
-$d$;
+ALTER SERVER loopback_nopw OPTIONS (ADD password 'dummypw');
ERROR: invalid option "password"
HINT: Perhaps you meant the option "passfile".
-CONTEXT: SQL statement "ALTER SERVER loopback_nopw OPTIONS (ADD password 'dummypw')"
-PL/pgSQL function inline_code_block line 3 at EXECUTE
-- If we add a password for our user mapping instead, we should get a different
-- error because the password wasn't actually *used* when we run with trust auth.
--
diff --git a/contrib/postgres_fdw/sql/postgres_fdw.sql b/contrib/postgres_fdw/sql/postgres_fdw.sql
index 9a493502f1e..e48ccd286bb 100644
--- a/contrib/postgres_fdw/sql/postgres_fdw.sql
+++ b/contrib/postgres_fdw/sql/postgres_fdw.sql
@@ -2899,11 +2899,7 @@ SELECT 1 FROM ft1_nopw LIMIT 1;
-- If we add a password to the connstr it'll fail, because we don't allow passwords
-- in connstrs only in user mappings.
-DO $d$
- BEGIN
- EXECUTE $$ALTER SERVER loopback_nopw OPTIONS (ADD password 'dummypw')$$;
- END;
-$d$;
+ALTER SERVER loopback_nopw OPTIONS (ADD password 'dummypw');
-- If we add a password for our user mapping instead, we should get a different
-- error because the password wasn't actually *used* when we run with trust auth.