1ALTER FOREIGN DATA WRAPPER(7)    SQL Commands    ALTER FOREIGN DATA WRAPPER(7)
2
3
4

NAME

6       ALTER  FOREIGN  DATA  WRAPPER - change the definition of a foreign-data
7       wrapper
8
9

SYNOPSIS

11       ALTER FOREIGN DATA WRAPPER name
12           [ VALIDATOR valfunction | NO VALIDATOR ]
13           [ OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ]) ]
14       ALTER FOREIGN DATA WRAPPER name OWNER TO new_owner
15
16

DESCRIPTION

18       ALTER FOREIGN DATA WRAPPER changes the  definition  of  a  foreign-data
19       wrapper.  The  first  form  of  the  command changes the library or the
20       generic options of the foreign-data wrapper (at  least  one  clause  is
21       required).  The second form changes the owner of the foreign-data wrap‐
22       per.
23
24       Only superusers can alter  foreign-data  wrappers.  Additionally,  only
25       superusers can own foreign-data wrappers.
26

PARAMETERS

28       name   The name of an existing foreign-data wrapper.
29
30       VALIDATOR valfunction
31              Specifies a new foreign-data wrapper validator function.
32
33              Note  that  it is possible that after changing the validator the
34              options to the foreign-data wrapper, servers, and user  mappings
35              have  become  invalid.  It  is  up to the user to make sure that
36              these options are correct before using the foreign-data wrapper.
37
38       NO VALIDATOR
39              This is used to specify that the foreign-data wrapper should  no
40              longer have a validator function.
41
42       OPTIONS ( [ ADD | SET | DROP ] option ['value'] [, ... ] )
43              Change  options for the foreign-data wrapper. ADD, SET, and DROP
44              specify the action to be performed. ADD is assumed if no  opera‐
45              tion is explicitly specified. Option names must be unique; names
46              and values are also validated using  the  foreign  data  wrapper
47              library.
48

EXAMPLES

50       Change a foreign-data wrapper dbi, add option foo, drop bar:
51
52       ALTER FOREIGN DATA WRAPPER dbi OPTIONS (ADD foo '1', DROP 'bar');
53
54
55       Change the foreign-data wrapper dbi validator to bob.myvalidator:
56
57       ALTER FOREIGN DATA WRAPPER dbi VALIDATOR bob.myvalidator;
58
59

COMPATIBILITY

61       ALTER  FOREIGN  DATA  WRAPPER conforms to ISO/IEC 9075-9 (SQL/MED). The
62       standard does not specify the  VALIDATOR and OWNER TO variants  of  the
63       command.
64

SEE ALSO

66       CREATE FOREIGN DATA WRAPPER [create_foreign_data_wrapper(7)], DROP FOR‐
67       EIGN DATA WRAPPER [drop_foreign_data_wrapper(7)]
68
69
70
71SQL - Language Statements         2014-02-17     ALTER FOREIGN DATA WRAPPER(7)
Impressum