diff options
| author | Tom Lane | 2011-02-14 02:24:14 +0000 |
|---|---|---|
| committer | Tom Lane | 2011-02-14 03:54:52 +0000 |
| commit | 029fac2264101919b65fb6319bb994f941969471 (patch) | |
| tree | edb89110508318a04730a7caa42d312e050ef7ce /contrib/unaccent | |
| parent | 629b3af27d5c2bc9d6e16b22b943ad651d4ecb56 (diff) | |
Avoid use of CREATE OR REPLACE FUNCTION in extension installation files.
It was never terribly consistent to use OR REPLACE (because of the lack of
comparable functionality for data types, operators, etc), and
experimentation shows that it's now positively pernicious in the extension
world. We really want a failure to occur if there are any conflicts, else
it's unclear what the extension-ownership state of the conflicted object
ought to be. Most of the time, CREATE EXTENSION will fail anyway because
of conflicts on other object types, but an extension defining only
functions can succeed, with bad results.
Diffstat (limited to 'contrib/unaccent')
| -rw-r--r-- | contrib/unaccent/unaccent--1.0.sql | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/contrib/unaccent/unaccent--1.0.sql b/contrib/unaccent/unaccent--1.0.sql index 4dc9c3d9c66..b5909e0b556 100644 --- a/contrib/unaccent/unaccent--1.0.sql +++ b/contrib/unaccent/unaccent--1.0.sql @@ -1,21 +1,21 @@ /* contrib/unaccent/unaccent--1.0.sql */ -CREATE OR REPLACE FUNCTION unaccent(regdictionary, text) +CREATE FUNCTION unaccent(regdictionary, text) RETURNS text AS 'MODULE_PATHNAME', 'unaccent_dict' LANGUAGE C STABLE STRICT; -CREATE OR REPLACE FUNCTION unaccent(text) +CREATE FUNCTION unaccent(text) RETURNS text AS 'MODULE_PATHNAME', 'unaccent_dict' LANGUAGE C STABLE STRICT; -CREATE OR REPLACE FUNCTION unaccent_init(internal) +CREATE FUNCTION unaccent_init(internal) RETURNS internal AS 'MODULE_PATHNAME', 'unaccent_init' LANGUAGE C; -CREATE OR REPLACE FUNCTION unaccent_lexize(internal,internal,internal,internal) +CREATE FUNCTION unaccent_lexize(internal,internal,internal,internal) RETURNS internal AS 'MODULE_PATHNAME', 'unaccent_lexize' LANGUAGE C; |
