diff --git a/src/bin/psql/describe.c b/src/bin/psql/describe.c
index a89c938..13d0a64 100644
*** a/src/bin/psql/describe.c
--- b/src/bin/psql/describe.c
*************** listForeignDataWrappers(const char *patt
*** 3593,3601 ****
  		appendPQExpBuffer(&buf,
  						  ",\n  fdwoptions AS \"%s\"",
  						  gettext_noop("Options"));
  	}
  
! 	appendPQExpBuffer(&buf, "\nFROM pg_catalog.pg_foreign_data_wrapper\n");
  
  	processSQLNamePattern(pset.db, &buf, pattern, false, false,
  						  NULL, "fdwname", NULL, NULL);
--- 3593,3607 ----
  		appendPQExpBuffer(&buf,
  						  ",\n  fdwoptions AS \"%s\"",
  						  gettext_noop("Options"));
+ 		appendPQExpBuffer(&buf,
+ 						  ",\n  description AS \"%s\"",
+ 						  gettext_noop("Description"));
  	}
  
! 	appendPQExpBuffer(&buf, "\nFROM pg_catalog.pg_foreign_data_wrapper w \n");
! 	appendPQExpBuffer(&buf, 
! 					  "LEFT JOIN pg_catalog.pg_description c ON c.objoid = w.oid "
! 					  "AND c.classoid = 'pg_catalog.pg_foreign_data_wrapper'::pg_catalog.regclass\n");
  
  	processSQLNamePattern(pset.db, &buf, pattern, false, false,
  						  NULL, "fdwname", NULL, NULL);
*************** listForeignServers(const char *pattern, 
*** 3653,3667 ****
  						  ",\n"
  						  "  s.srvtype AS \"%s\",\n"
  						  "  s.srvversion AS \"%s\",\n"
! 						  "  s.srvoptions AS \"%s\"",
  						  gettext_noop("Type"),
  						  gettext_noop("Version"),
! 						  gettext_noop("Options"));
  	}
  
  	appendPQExpBuffer(&buf,
! 					  "\nFROM pg_catalog.pg_foreign_server s\n"
! 	   "     JOIN pg_catalog.pg_foreign_data_wrapper f ON f.oid=s.srvfdw\n");
  
  	processSQLNamePattern(pset.db, &buf, pattern, false, false,
  						  NULL, "s.srvname", NULL, NULL);
--- 3659,3677 ----
  						  ",\n"
  						  "  s.srvtype AS \"%s\",\n"
  						  "  s.srvversion AS \"%s\",\n"
! 						  "  s.srvoptions AS \"%s\",\n"
! 						  "  d.description AS \"%s\"\n",
  						  gettext_noop("Type"),
  						  gettext_noop("Version"),
! 						  gettext_noop("Options"),
! 						  gettext_noop("Description"));
  	}
  
  	appendPQExpBuffer(&buf,
! 		"\nFROM pg_catalog.pg_foreign_server s "
! 		"\n     JOIN pg_catalog.pg_foreign_data_wrapper f ON f.oid=s.srvfdw "
! 		"\nLEFT JOIN pg_catalog.pg_description d ON d.objoid=s.oid "
! 		"\n      AND d.classoid = 'pg_catalog.pg_foreign_server'::regclass ");
  
  	processSQLNamePattern(pset.db, &buf, pattern, false, false,
  						  NULL, "s.srvname", NULL, NULL);
diff --git a/src/test/regress/expected/foreign_data.out b/src/test/regress/expected/foreign_data.out
index c05bcab..7d187d8 100644
*** a/src/test/regress/expected/foreign_data.out
--- b/src/test/regress/expected/foreign_data.out
*************** ERROR:  foreign-data wrapper "foo" alrea
*** 52,63 ****
  DROP FOREIGN DATA WRAPPER foo;
  CREATE FOREIGN DATA WRAPPER foo OPTIONS (testing '1');
  \dew+
!                                      List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |   Options   
! ------------+-------------------+---------+--------------------------+-------------------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  foo        | foreign_data_user | -       | -                        |                   | {testing=1}
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  DROP FOREIGN DATA WRAPPER foo;
--- 52,63 ----
  DROP FOREIGN DATA WRAPPER foo;
  CREATE FOREIGN DATA WRAPPER foo OPTIONS (testing '1');
  \dew+
!                                             List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |   Options   | Description 
! ------------+-------------------+---------+--------------------------+-------------------+-------------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |             | useless
!  foo        | foreign_data_user | -       | -                        |                   | {testing=1} | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |             | 
  (3 rows)
  
  DROP FOREIGN DATA WRAPPER foo;
*************** CREATE FOREIGN DATA WRAPPER foo OPTIONS 
*** 65,76 ****
  ERROR:  option "testing" provided more than once
  CREATE FOREIGN DATA WRAPPER foo OPTIONS (testing '1', another '2');
  \dew+
!                                           List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |        Options        
! ------------+-------------------+---------+--------------------------+-------------------+-----------------------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  foo        | foreign_data_user | -       | -                        |                   | {testing=1,another=2}
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  DROP FOREIGN DATA WRAPPER foo;
--- 65,76 ----
  ERROR:  option "testing" provided more than once
  CREATE FOREIGN DATA WRAPPER foo OPTIONS (testing '1', another '2');
  \dew+
!                                                  List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |        Options        | Description 
! ------------+-------------------+---------+--------------------------+-------------------+-----------------------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |                       | useless
!  foo        | foreign_data_user | -       | -                        |                   | {testing=1,another=2} | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |                       | 
  (3 rows)
  
  DROP FOREIGN DATA WRAPPER foo;
*************** HINT:  Must be superuser to create a for
*** 81,92 ****
  RESET ROLE;
  CREATE FOREIGN DATA WRAPPER foo VALIDATOR postgresql_fdw_validator;
  \dew+
!                                    List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options 
! ------------+-------------------+---------+--------------------------+-------------------+---------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  foo        | foreign_data_user | -       | postgresql_fdw_validator |                   | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  -- ALTER FOREIGN DATA WRAPPER
--- 81,92 ----
  RESET ROLE;
  CREATE FOREIGN DATA WRAPPER foo VALIDATOR postgresql_fdw_validator;
  \dew+
!                                           List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options | Description 
! ------------+-------------------+---------+--------------------------+-------------------+---------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |         | useless
!  foo        | foreign_data_user | -       | postgresql_fdw_validator |                   |         | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |         | 
  (3 rows)
  
  -- ALTER FOREIGN DATA WRAPPER
*************** ALTER FOREIGN DATA WRAPPER foo VALIDATOR
*** 98,109 ****
  ERROR:  function bar(text[], oid) does not exist
  ALTER FOREIGN DATA WRAPPER foo NO VALIDATOR;
  \dew+
!                                    List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options 
! ------------+-------------------+---------+--------------------------+-------------------+---------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  foo        | foreign_data_user | -       | -                        |                   | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (a '1', b '2');
--- 98,109 ----
  ERROR:  function bar(text[], oid) does not exist
  ALTER FOREIGN DATA WRAPPER foo NO VALIDATOR;
  \dew+
!                                           List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options | Description 
! ------------+-------------------+---------+--------------------------+-------------------+---------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |         | useless
!  foo        | foreign_data_user | -       | -                        |                   |         | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |         | 
  (3 rows)
  
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (a '1', b '2');
*************** ALTER FOREIGN DATA WRAPPER foo OPTIONS (
*** 113,146 ****
  ERROR:  option "c" not found
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (ADD x '1', DROP x);
  \dew+
!                                     List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |  Options  
! ------------+-------------------+---------+--------------------------+-------------------+-----------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  foo        | foreign_data_user | -       | -                        |                   | {a=1,b=2}
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (DROP a, SET b '3', ADD c '4');
  \dew+
!                                     List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |  Options  
! ------------+-------------------+---------+--------------------------+-------------------+-----------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  foo        | foreign_data_user | -       | -                        |                   | {b=3,c=4}
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (a '2');
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (b '4');             -- ERROR
  ERROR:  option "b" provided more than once
  \dew+
!                                       List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |    Options    
! ------------+-------------------+---------+--------------------------+-------------------+---------------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  foo        | foreign_data_user | -       | -                        |                   | {b=3,c=4,a=2}
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  SET ROLE regress_test_role;
--- 113,146 ----
  ERROR:  option "c" not found
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (ADD x '1', DROP x);
  \dew+
!                                            List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |  Options  | Description 
! ------------+-------------------+---------+--------------------------+-------------------+-----------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |           | useless
!  foo        | foreign_data_user | -       | -                        |                   | {a=1,b=2} | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |           | 
  (3 rows)
  
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (DROP a, SET b '3', ADD c '4');
  \dew+
!                                            List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |  Options  | Description 
! ------------+-------------------+---------+--------------------------+-------------------+-----------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |           | useless
!  foo        | foreign_data_user | -       | -                        |                   | {b=3,c=4} | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |           | 
  (3 rows)
  
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (a '2');
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (b '4');             -- ERROR
  ERROR:  option "b" provided more than once
  \dew+
!                                              List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |    Options    | Description 
! ------------+-------------------+---------+--------------------------+-------------------+---------------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |               | useless
!  foo        | foreign_data_user | -       | -                        |                   | {b=3,c=4,a=2} | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |               | 
  (3 rows)
  
  SET ROLE regress_test_role;
*************** HINT:  Must be superuser to alter a fore
*** 150,161 ****
  SET ROLE regress_test_role_super;
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (ADD d '5');
  \dew+
!                                         List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |      Options      
! ------------+-------------------+---------+--------------------------+-------------------+-------------------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  foo        | foreign_data_user | -       | -                        |                   | {b=3,c=4,a=2,d=5}
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  ALTER FOREIGN DATA WRAPPER foo OWNER TO regress_test_role;  -- ERROR
--- 150,161 ----
  SET ROLE regress_test_role_super;
  ALTER FOREIGN DATA WRAPPER foo OPTIONS (ADD d '5');
  \dew+
!                                                List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges |      Options      | Description 
! ------------+-------------------+---------+--------------------------+-------------------+-------------------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |                   | useless
!  foo        | foreign_data_user | -       | -                        |                   | {b=3,c=4,a=2,d=5} | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |                   | 
  (3 rows)
  
  ALTER FOREIGN DATA WRAPPER foo OWNER TO regress_test_role;  -- ERROR
*************** ERROR:  permission denied to alter forei
*** 169,180 ****
  HINT:  Must be superuser to alter a foreign-data wrapper.
  RESET ROLE;
  \dew+
!                                            List of foreign-data wrappers
!     Name    |          Owner          | Handler |        Validator         | Access privileges |      Options      
! ------------+-------------------------+---------+--------------------------+-------------------+-------------------
!  dummy      | foreign_data_user       | -       | -                        |                   | 
!  foo        | regress_test_role_super | -       | -                        |                   | {b=3,c=4,a=2,d=5}
!  postgresql | foreign_data_user       | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  -- DROP FOREIGN DATA WRAPPER
--- 169,180 ----
  HINT:  Must be superuser to alter a foreign-data wrapper.
  RESET ROLE;
  \dew+
!                                                   List of foreign-data wrappers
!     Name    |          Owner          | Handler |        Validator         | Access privileges |      Options      | Description 
! ------------+-------------------------+---------+--------------------------+-------------------+-------------------+-------------
!  dummy      | foreign_data_user       | -       | -                        |                   |                   | useless
!  foo        | regress_test_role_super | -       | -                        |                   | {b=3,c=4,a=2,d=5} | 
!  postgresql | foreign_data_user       | -       | postgresql_fdw_validator |                   |                   | 
  (3 rows)
  
  -- DROP FOREIGN DATA WRAPPER
*************** ERROR:  foreign-data wrapper "nonexisten
*** 183,194 ****
  DROP FOREIGN DATA WRAPPER IF EXISTS nonexistent;
  NOTICE:  foreign-data wrapper "nonexistent" does not exist, skipping
  \dew+
!                                            List of foreign-data wrappers
!     Name    |          Owner          | Handler |        Validator         | Access privileges |      Options      
! ------------+-------------------------+---------+--------------------------+-------------------+-------------------
!  dummy      | foreign_data_user       | -       | -                        |                   | 
!  foo        | regress_test_role_super | -       | -                        |                   | {b=3,c=4,a=2,d=5}
!  postgresql | foreign_data_user       | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  DROP ROLE regress_test_role_super;                          -- ERROR
--- 183,194 ----
  DROP FOREIGN DATA WRAPPER IF EXISTS nonexistent;
  NOTICE:  foreign-data wrapper "nonexistent" does not exist, skipping
  \dew+
!                                                   List of foreign-data wrappers
!     Name    |          Owner          | Handler |        Validator         | Access privileges |      Options      | Description 
! ------------+-------------------------+---------+--------------------------+-------------------+-------------------+-------------
!  dummy      | foreign_data_user       | -       | -                        |                   |                   | useless
!  foo        | regress_test_role_super | -       | -                        |                   | {b=3,c=4,a=2,d=5} | 
!  postgresql | foreign_data_user       | -       | postgresql_fdw_validator |                   |                   | 
  (3 rows)
  
  DROP ROLE regress_test_role_super;                          -- ERROR
*************** ALTER ROLE regress_test_role_super SUPER
*** 203,213 ****
  DROP FOREIGN DATA WRAPPER foo;
  DROP ROLE regress_test_role_super;
  \dew+
!                                    List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options 
! ------------+-------------------+---------+--------------------------+-------------------+---------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (2 rows)
  
  CREATE FOREIGN DATA WRAPPER foo;
--- 203,213 ----
  DROP FOREIGN DATA WRAPPER foo;
  DROP ROLE regress_test_role_super;
  \dew+
!                                           List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options | Description 
! ------------+-------------------+---------+--------------------------+-------------------+---------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |         | useless
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |         | 
  (2 rows)
  
  CREATE FOREIGN DATA WRAPPER foo;
*************** CREATE SERVER s1 FOREIGN DATA WRAPPER fo
*** 215,233 ****
  COMMENT ON SERVER s1 IS 'foreign server';
  CREATE USER MAPPING FOR current_user SERVER s1;
  \dew+
!                                    List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options 
! ------------+-------------------+---------+--------------------------+-------------------+---------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  foo        | foreign_data_user | -       | -                        |                   | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (3 rows)
  
  \des+
!                                     List of foreign servers
!  Name |       Owner       | Foreign-data wrapper | Access privileges | Type | Version | Options 
! ------+-------------------+----------------------+-------------------+------+---------+---------
!  s1   | foreign_data_user | foo                  |                   |      |         | 
  (1 row)
  
  \deu+
--- 215,233 ----
  COMMENT ON SERVER s1 IS 'foreign server';
  CREATE USER MAPPING FOR current_user SERVER s1;
  \dew+
!                                           List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options | Description 
! ------------+-------------------+---------+--------------------------+-------------------+---------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |         | useless
!  foo        | foreign_data_user | -       | -                        |                   |         | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |         | 
  (3 rows)
  
  \des+
!                                              List of foreign servers
!  Name |       Owner       | Foreign-data wrapper | Access privileges | Type | Version | Options |  Description   
! ------+-------------------+----------------------+-------------------+------+---------+---------+----------------
!  s1   | foreign_data_user | foo                  |                   |      |         |         | foreign server
  (1 row)
  
  \deu+
*************** NOTICE:  drop cascades to 2 other object
*** 252,268 ****
  DETAIL:  drop cascades to server s1
  drop cascades to user mapping for foreign_data_user
  \dew+
!                                    List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options 
! ------------+-------------------+---------+--------------------------+-------------------+---------
!  dummy      | foreign_data_user | -       | -                        |                   | 
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   | 
  (2 rows)
  
  \des+
!                               List of foreign servers
!  Name | Owner | Foreign-data wrapper | Access privileges | Type | Version | Options 
! ------+-------+----------------------+-------------------+------+---------+---------
  (0 rows)
  
  \deu+
--- 252,268 ----
  DETAIL:  drop cascades to server s1
  drop cascades to user mapping for foreign_data_user
  \dew+
!                                           List of foreign-data wrappers
!     Name    |       Owner       | Handler |        Validator         | Access privileges | Options | Description 
! ------------+-------------------+---------+--------------------------+-------------------+---------+-------------
!  dummy      | foreign_data_user | -       | -                        |                   |         | useless
!  postgresql | foreign_data_user | -       | postgresql_fdw_validator |                   |         | 
  (2 rows)
  
  \des+
!                                      List of foreign servers
!  Name | Owner | Foreign-data wrapper | Access privileges | Type | Version | Options | Description 
! ------+-------+----------------------+-------------------+------+---------+---------+-------------
  (0 rows)
  
  \deu+
*************** ERROR:  invalid option "foo"
*** 289,305 ****
  HINT:  Valid options in this context are: authtype, service, connect_timeout, dbname, host, hostaddr, port, tty, options, requiressl, sslmode, gsslib
  CREATE SERVER s8 FOREIGN DATA WRAPPER postgresql OPTIONS (host 'localhost', dbname 's8db');
  \des+
!                                                 List of foreign servers
!  Name |       Owner       | Foreign-data wrapper | Access privileges |  Type  | Version |           Options            
! ------+-------------------+----------------------+-------------------+--------+---------+------------------------------
!  s1   | foreign_data_user | foo                  |                   |        |         | 
!  s2   | foreign_data_user | foo                  |                   |        |         | {host=a,dbname=b}
!  s3   | foreign_data_user | foo                  |                   | oracle |         | 
!  s4   | foreign_data_user | foo                  |                   | oracle |         | {host=a,dbname=b}
!  s5   | foreign_data_user | foo                  |                   |        | 15.0    | 
!  s6   | foreign_data_user | foo                  |                   |        | 16.0    | {host=a,dbname=b}
!  s7   | foreign_data_user | foo                  |                   | oracle | 17.0    | {host=a,dbname=b}
!  s8   | foreign_data_user | postgresql           |                   |        |         | {host=localhost,dbname=s8db}
  (8 rows)
  
  SET ROLE regress_test_role;
--- 289,305 ----
  HINT:  Valid options in this context are: authtype, service, connect_timeout, dbname, host, hostaddr, port, tty, options, requiressl, sslmode, gsslib
  CREATE SERVER s8 FOREIGN DATA WRAPPER postgresql OPTIONS (host 'localhost', dbname 's8db');
  \des+
!                                                        List of foreign servers
!  Name |       Owner       | Foreign-data wrapper | Access privileges |  Type  | Version |           Options            | Description 
! ------+-------------------+----------------------+-------------------+--------+---------+------------------------------+-------------
!  s1   | foreign_data_user | foo                  |                   |        |         |                              | 
!  s2   | foreign_data_user | foo                  |                   |        |         | {host=a,dbname=b}            | 
!  s3   | foreign_data_user | foo                  |                   | oracle |         |                              | 
!  s4   | foreign_data_user | foo                  |                   | oracle |         | {host=a,dbname=b}            | 
!  s5   | foreign_data_user | foo                  |                   |        | 15.0    |                              | 
!  s6   | foreign_data_user | foo                  |                   |        | 16.0    | {host=a,dbname=b}            | 
!  s7   | foreign_data_user | foo                  |                   | oracle | 17.0    | {host=a,dbname=b}            | 
!  s8   | foreign_data_user | postgresql           |                   |        |         | {host=localhost,dbname=s8db} | 
  (8 rows)
  
  SET ROLE regress_test_role;
*************** SET ROLE regress_test_role;
*** 311,328 ****
  CREATE SERVER t1 FOREIGN DATA WRAPPER foo;
  RESET ROLE;
  \des+
!                                                 List of foreign servers
!  Name |       Owner       | Foreign-data wrapper | Access privileges |  Type  | Version |           Options            
! ------+-------------------+----------------------+-------------------+--------+---------+------------------------------
!  s1   | foreign_data_user | foo                  |                   |        |         | 
!  s2   | foreign_data_user | foo                  |                   |        |         | {host=a,dbname=b}
!  s3   | foreign_data_user | foo                  |                   | oracle |         | 
!  s4   | foreign_data_user | foo                  |                   | oracle |         | {host=a,dbname=b}
!  s5   | foreign_data_user | foo                  |                   |        | 15.0    | 
!  s6   | foreign_data_user | foo                  |                   |        | 16.0    | {host=a,dbname=b}
!  s7   | foreign_data_user | foo                  |                   | oracle | 17.0    | {host=a,dbname=b}
!  s8   | foreign_data_user | postgresql           |                   |        |         | {host=localhost,dbname=s8db}
!  t1   | regress_test_role | foo                  |                   |        |         | 
  (9 rows)
  
  REVOKE USAGE ON FOREIGN DATA WRAPPER foo FROM regress_test_role;
--- 311,328 ----
  CREATE SERVER t1 FOREIGN DATA WRAPPER foo;
  RESET ROLE;
  \des+
!                                                        List of foreign servers
!  Name |       Owner       | Foreign-data wrapper | Access privileges |  Type  | Version |           Options            | Description 
! ------+-------------------+----------------------+-------------------+--------+---------+------------------------------+-------------
!  s1   | foreign_data_user | foo                  |                   |        |         |                              | 
!  s2   | foreign_data_user | foo                  |                   |        |         | {host=a,dbname=b}            | 
!  s3   | foreign_data_user | foo                  |                   | oracle |         |                              | 
!  s4   | foreign_data_user | foo                  |                   | oracle |         | {host=a,dbname=b}            | 
!  s5   | foreign_data_user | foo                  |                   |        | 15.0    |                              | 
!  s6   | foreign_data_user | foo                  |                   |        | 16.0    | {host=a,dbname=b}            | 
!  s7   | foreign_data_user | foo                  |                   | oracle | 17.0    | {host=a,dbname=b}            | 
!  s8   | foreign_data_user | postgresql           |                   |        |         | {host=localhost,dbname=s8db} | 
!  t1   | regress_test_role | foo                  |                   |        |         |                              | 
  (9 rows)
  
  REVOKE USAGE ON FOREIGN DATA WRAPPER foo FROM regress_test_role;
*************** GRANT regress_test_indirect TO regress_t
*** 335,353 ****
  SET ROLE regress_test_role;
  CREATE SERVER t2 FOREIGN DATA WRAPPER foo;
  \des+
!                                                 List of foreign servers
!  Name |       Owner       | Foreign-data wrapper | Access privileges |  Type  | Version |           Options            
! ------+-------------------+----------------------+-------------------+--------+---------+------------------------------
!  s1   | foreign_data_user | foo                  |                   |        |         | 
!  s2   | foreign_data_user | foo                  |                   |        |         | {host=a,dbname=b}
!  s3   | foreign_data_user | foo                  |                   | oracle |         | 
!  s4   | foreign_data_user | foo                  |                   | oracle |         | {host=a,dbname=b}
!  s5   | foreign_data_user | foo                  |                   |        | 15.0    | 
!  s6   | foreign_data_user | foo                  |                   |        | 16.0    | {host=a,dbname=b}
!  s7   | foreign_data_user | foo                  |                   | oracle | 17.0    | {host=a,dbname=b}
!  s8   | foreign_data_user | postgresql           |                   |        |         | {host=localhost,dbname=s8db}
!  t1   | regress_test_role | foo                  |                   |        |         | 
!  t2   | regress_test_role | foo                  |                   |        |         | 
  (10 rows)
  
  RESET ROLE;
--- 335,353 ----
  SET ROLE regress_test_role;
  CREATE SERVER t2 FOREIGN DATA WRAPPER foo;
  \des+
!                                                        List of foreign servers
!  Name |       Owner       | Foreign-data wrapper | Access privileges |  Type  | Version |           Options            | Description 
! ------+-------------------+----------------------+-------------------+--------+---------+------------------------------+-------------
!  s1   | foreign_data_user | foo                  |                   |        |         |                              | 
!  s2   | foreign_data_user | foo                  |                   |        |         | {host=a,dbname=b}            | 
!  s3   | foreign_data_user | foo                  |                   | oracle |         |                              | 
!  s4   | foreign_data_user | foo                  |                   | oracle |         | {host=a,dbname=b}            | 
!  s5   | foreign_data_user | foo                  |                   |        | 15.0    |                              | 
!  s6   | foreign_data_user | foo                  |                   |        | 16.0    | {host=a,dbname=b}            | 
!  s7   | foreign_data_user | foo                  |                   | oracle | 17.0    | {host=a,dbname=b}            | 
!  s8   | foreign_data_user | postgresql           |                   |        |         | {host=localhost,dbname=s8db} | 
!  t1   | regress_test_role | foo                  |                   |        |         |                              | 
!  t2   | regress_test_role | foo                  |                   |        |         |                              | 
  (10 rows)
  
  RESET ROLE;
*************** ALTER SERVER s3 OPTIONS (tnsname 'orcl',
*** 365,385 ****
  GRANT USAGE ON FOREIGN SERVER s1 TO regress_test_role;
  GRANT USAGE ON FOREIGN SERVER s6 TO regress_test_role2 WITH GRANT OPTION;
  \des+
!                                                            List of foreign servers
!  Name |       Owner       | Foreign-data wrapper |            Access privileges            |  Type  | Version |           Options            
! ------+-------------------+----------------------+-----------------------------------------+--------+---------+------------------------------
!  s1   | foreign_data_user | foo                  | foreign_data_user=U/foreign_data_user  +|        | 1.0     | {servername=s1}
!       |                   |                      | regress_test_role=U/foreign_data_user   |        |         | 
!  s2   | foreign_data_user | foo                  |                                         |        | 1.1     | {host=a,dbname=b}
!  s3   | foreign_data_user | foo                  |                                         | oracle |         | {tnsname=orcl,port=1521}
!  s4   | foreign_data_user | foo                  |                                         | oracle |         | {host=a,dbname=b}
!  s5   | foreign_data_user | foo                  |                                         |        | 15.0    | 
!  s6   | foreign_data_user | foo                  | foreign_data_user=U/foreign_data_user  +|        | 16.0    | {host=a,dbname=b}
!       |                   |                      | regress_test_role2=U*/foreign_data_user |        |         | 
!  s7   | foreign_data_user | foo                  |                                         | oracle | 17.0    | {host=a,dbname=b}
!  s8   | foreign_data_user | postgresql           |                                         |        |         | {host=localhost,dbname=s8db}
!  t1   | regress_test_role | foo                  |                                         |        |         | 
!  t2   | regress_test_role | foo                  |                                         |        |         | 
  (10 rows)
  
  SET ROLE regress_test_role;
--- 365,385 ----
  GRANT USAGE ON FOREIGN SERVER s1 TO regress_test_role;
  GRANT USAGE ON FOREIGN SERVER s6 TO regress_test_role2 WITH GRANT OPTION;
  \des+
!                                                                   List of foreign servers
!  Name |       Owner       | Foreign-data wrapper |            Access privileges            |  Type  | Version |           Options            | Description 
! ------+-------------------+----------------------+-----------------------------------------+--------+---------+------------------------------+-------------
!  s1   | foreign_data_user | foo                  | foreign_data_user=U/foreign_data_user  +|        | 1.0     | {servername=s1}              | 
!       |                   |                      | regress_test_role=U/foreign_data_user   |        |         |                              | 
!  s2   | foreign_data_user | foo                  |                                         |        | 1.1     | {host=a,dbname=b}            | 
!  s3   | foreign_data_user | foo                  |                                         | oracle |         | {tnsname=orcl,port=1521}     | 
!  s4   | foreign_data_user | foo                  |                                         | oracle |         | {host=a,dbname=b}            | 
!  s5   | foreign_data_user | foo                  |                                         |        | 15.0    |                              | 
!  s6   | foreign_data_user | foo                  | foreign_data_user=U/foreign_data_user  +|        | 16.0    | {host=a,dbname=b}            | 
!       |                   |                      | regress_test_role2=U*/foreign_data_user |        |         |                              | 
!  s7   | foreign_data_user | foo                  |                                         | oracle | 17.0    | {host=a,dbname=b}            | 
!  s8   | foreign_data_user | postgresql           |                                         |        |         | {host=localhost,dbname=s8db} | 
!  t1   | regress_test_role | foo                  |                                         |        |         |                              | 
!  t2   | regress_test_role | foo                  |                                         |        |         |                              | 
  (10 rows)
  
  SET ROLE regress_test_role;
*************** ERROR:  role "regress_test_indirect" can
*** 416,436 ****
  DETAIL:  owner of server s1
  privileges for foreign-data wrapper foo
  \des+
!                                                               List of foreign servers
!  Name |         Owner         | Foreign-data wrapper |            Access privileges            |  Type  | Version |             Options             
! ------+-----------------------+----------------------+-----------------------------------------+--------+---------+---------------------------------
!  s1   | regress_test_indirect | foo                  | foreign_data_user=U/foreign_data_user  +|        | 1.1     | {servername=s1}
!       |                       |                      | regress_test_role=U/foreign_data_user   |        |         | 
!  s2   | foreign_data_user     | foo                  |                                         |        | 1.1     | {host=a,dbname=b}
!  s3   | foreign_data_user     | foo                  |                                         | oracle |         | {tnsname=orcl,port=1521}
!  s4   | foreign_data_user     | foo                  |                                         | oracle |         | {host=a,dbname=b}
!  s5   | foreign_data_user     | foo                  |                                         |        | 15.0    | 
!  s6   | foreign_data_user     | foo                  | foreign_data_user=U/foreign_data_user  +|        | 16.0    | {host=a,dbname=b}
!       |                       |                      | regress_test_role2=U*/foreign_data_user |        |         | 
!  s7   | foreign_data_user     | foo                  |                                         | oracle | 17.0    | {host=a,dbname=b}
!  s8   | foreign_data_user     | postgresql           |                                         |        |         | {dbname=db1,connect_timeout=30}
!  t1   | regress_test_role     | foo                  |                                         |        |         | 
!  t2   | regress_test_role     | foo                  |                                         |        |         | 
  (10 rows)
  
  -- DROP SERVER
--- 416,436 ----
  DETAIL:  owner of server s1
  privileges for foreign-data wrapper foo
  \des+
!                                                                      List of foreign servers
!  Name |         Owner         | Foreign-data wrapper |            Access privileges            |  Type  | Version |             Options             | Description 
! ------+-----------------------+----------------------+-----------------------------------------+--------+---------+---------------------------------+-------------
!  s1   | regress_test_indirect | foo                  | foreign_data_user=U/foreign_data_user  +|        | 1.1     | {servername=s1}                 | 
!       |                       |                      | regress_test_role=U/foreign_data_user   |        |         |                                 | 
!  s2   | foreign_data_user     | foo                  |                                         |        | 1.1     | {host=a,dbname=b}               | 
!  s3   | foreign_data_user     | foo                  |                                         | oracle |         | {tnsname=orcl,port=1521}        | 
!  s4   | foreign_data_user     | foo                  |                                         | oracle |         | {host=a,dbname=b}               | 
!  s5   | foreign_data_user     | foo                  |                                         |        | 15.0    |                                 | 
!  s6   | foreign_data_user     | foo                  | foreign_data_user=U/foreign_data_user  +|        | 16.0    | {host=a,dbname=b}               | 
!       |                       |                      | regress_test_role2=U*/foreign_data_user |        |         |                                 | 
!  s7   | foreign_data_user     | foo                  |                                         | oracle | 17.0    | {host=a,dbname=b}               | 
!  s8   | foreign_data_user     | postgresql           |                                         |        |         | {dbname=db1,connect_timeout=30} | 
!  t1   | regress_test_role     | foo                  |                                         |        |         |                                 | 
!  t2   | regress_test_role     | foo                  |                                         |        |         |                                 | 
  (10 rows)
  
  -- DROP SERVER
