Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit3b61e57

Browse files
committed
Assorted fixups for "unpackaged" conversion scripts.
From first pass of testing. Notably, there seems to be no need foradminpack--unpackaged--1.0.sql because none of the objects that theold module creates would ever be dumped by pg_dump anyway (they areall in pg_catalog).
1 parent029fac2 commit3b61e57

File tree

5 files changed

+28
-16
lines changed

5 files changed

+28
-16
lines changed

‎contrib/adminpack/Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ OBJS = adminpack.o
55
PG_CPPFLAGS = -I$(libpq_srcdir)
66

77
EXTENSION = adminpack
8-
DATA = adminpack--1.0.sql adminpack--unpackaged--1.0.sql
8+
DATA = adminpack--1.0.sql
99

1010
ifdefUSE_PGXS
1111
PG_CONFIG = pg_config

‎contrib/adminpack/adminpack--unpackaged--1.0.sql

Lines changed: 0 additions & 10 deletions
This file was deleted.

‎contrib/fuzzystrmatch/fuzzystrmatch--unpackaged--1.0.sql

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,19 @@
22

33
ALTER EXTENSION fuzzystrmatch ADD function levenshtein(text,text);
44
ALTER EXTENSION fuzzystrmatch ADD function levenshtein(text,text,integer,integer,integer);
5-
ALTER EXTENSION fuzzystrmatch ADD function levenshtein_less_equal(text,text,integer);
6-
ALTER EXTENSION fuzzystrmatch ADD function levenshtein_less_equal(text,text,integer,integer,integer,integer);
75
ALTER EXTENSION fuzzystrmatch ADD function metaphone(text,integer);
86
ALTER EXTENSION fuzzystrmatch ADD function soundex(text);
97
ALTER EXTENSION fuzzystrmatch ADD function text_soundex(text);
108
ALTER EXTENSION fuzzystrmatch ADD function difference(text,text);
119
ALTER EXTENSION fuzzystrmatch ADD function dmetaphone(text);
1210
ALTER EXTENSION fuzzystrmatch ADD function dmetaphone_alt(text);
11+
12+
-- these functions were not in 9.0
13+
14+
CREATEFUNCTIONlevenshtein_less_equal (text,text,int) RETURNSint
15+
AS'MODULE_PATHNAME','levenshtein_less_equal'
16+
LANGUAGE C IMMUTABLE STRICT;
17+
18+
CREATEFUNCTIONlevenshtein_less_equal (text,text,int,int,int,int) RETURNSint
19+
AS'MODULE_PATHNAME','levenshtein_less_equal_with_costs'
20+
LANGUAGE C IMMUTABLE STRICT;

‎contrib/pg_trgm/pg_trgm--unpackaged--1.0.sql

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,6 @@ ALTER EXTENSION pg_trgm ADD function show_trgm(text);
66
ALTER EXTENSION pg_trgm ADD function similarity(text,text);
77
ALTER EXTENSION pg_trgm ADD function similarity_op(text,text);
88
ALTER EXTENSION pg_trgm ADD operator %(text,text);
9-
ALTER EXTENSION pg_trgm ADD function similarity_dist(text,text);
10-
ALTER EXTENSION pg_trgm ADD operator<->(text,text);
119
ALTER EXTENSION pg_trgm ADD type gtrgm;
1210
ALTER EXTENSION pg_trgm ADD function gtrgm_in(cstring);
1311
ALTER EXTENSION pg_trgm ADD function gtrgm_out(gtrgm);
@@ -26,3 +24,17 @@ ALTER EXTENSION pg_trgm ADD function gin_extract_query_trgm(text,internal,smalli
2624
ALTER EXTENSION pg_trgm ADD function gin_trgm_consistent(internal,smallint,text,integer,internal,internal,internal,internal);
2725
ALTER EXTENSION pg_trgm ADD operator family gin_trgm_ops using gin;
2826
ALTER EXTENSION pg_trgm ADD operator class gin_trgm_ops using gin;
27+
28+
-- these were not in 9.0:
29+
30+
CREATEFUNCTIONsimilarity_dist(text,text)
31+
RETURNS float4
32+
AS'MODULE_PATHNAME'
33+
LANGUAGE C STRICT IMMUTABLE;
34+
35+
CREATE OPERATOR<-> (
36+
LEFTARG=text,
37+
RIGHTARG=text,
38+
PROCEDURE= similarity_dist,
39+
COMMUTATOR='<->'
40+
);

‎contrib/tsearch2/tsearch2.control

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,6 @@
22
comment = 'compatibility package for pre-8.3 text search functions'
33
default_version = '1.0'
44
module_pathname = '$libdir/tsearch2'
5-
relocatable = true
5+
# this is not relocatable because the tsearch2--unpackaged--1.0.sql script
6+
# has to use @extschema@ to avoid conflict with items in pg_catalog
7+
relocatable = false

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp