1 /* contrib/ltree/ltree--1.1--1.2.sql */
3 -- complain if script is sourced in psql, rather than via ALTER EXTENSION
4 \echo Use "ALTER EXTENSION ltree UPDATE TO '1.2'" to load this file. \quit
6 CREATE FUNCTION ltree_recv(internal)
9 LANGUAGE C STRICT IMMUTABLE PARALLEL SAFE;
11 CREATE FUNCTION ltree_send(ltree)
14 LANGUAGE C STRICT IMMUTABLE PARALLEL SAFE;
16 ALTER TYPE ltree SET ( RECEIVE = ltree_recv, SEND = ltree_send );
18 CREATE FUNCTION lquery_recv(internal)
21 LANGUAGE C STRICT IMMUTABLE PARALLEL SAFE;
23 CREATE FUNCTION lquery_send(lquery)
26 LANGUAGE C STRICT IMMUTABLE PARALLEL SAFE;
28 ALTER TYPE lquery SET ( RECEIVE = lquery_recv, SEND = lquery_send );
30 CREATE FUNCTION ltxtq_recv(internal)
33 LANGUAGE C STRICT IMMUTABLE PARALLEL SAFE;
35 CREATE FUNCTION ltxtq_send(ltxtquery)
38 LANGUAGE C STRICT IMMUTABLE PARALLEL SAFE;
40 ALTER TYPE ltxtquery SET ( RECEIVE = ltxtq_recv, SEND = ltxtq_send );
43 CREATE FUNCTION ltree_gist_options(internal)
45 AS 'MODULE_PATHNAME', 'ltree_gist_options'
46 LANGUAGE C IMMUTABLE PARALLEL SAFE;
48 CREATE FUNCTION _ltree_gist_options(internal)
50 AS 'MODULE_PATHNAME', '_ltree_gist_options'
51 LANGUAGE C IMMUTABLE PARALLEL SAFE;
53 ALTER OPERATOR FAMILY gist_ltree_ops USING gist
54 ADD FUNCTION 10 (ltree) ltree_gist_options (internal);
56 ALTER OPERATOR FAMILY gist__ltree_ops USING gist
57 ADD FUNCTION 10 (_ltree) _ltree_gist_options (internal);
59 ALTER OPERATOR < (ltree, ltree)
60 SET (RESTRICT = scalarltsel, JOIN = scalarltjoinsel);
61 ALTER OPERATOR <= (ltree, ltree)
62 SET (RESTRICT = scalarlesel, JOIN = scalarlejoinsel);
63 ALTER OPERATOR >= (ltree, ltree)
64 SET (RESTRICT = scalargesel, JOIN = scalargejoinsel);
65 ALTER OPERATOR > (ltree, ltree)
66 SET (RESTRICT = scalargtsel, JOIN = scalargtjoinsel);
68 ALTER OPERATOR @> (ltree, ltree)
69 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
70 ALTER OPERATOR ^@> (ltree, ltree)
71 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
72 ALTER OPERATOR <@ (ltree, ltree)
73 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
74 ALTER OPERATOR ^<@ (ltree, ltree)
75 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
76 ALTER OPERATOR ~ (ltree, lquery)
77 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
78 ALTER OPERATOR ~ (lquery, ltree)
79 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
80 ALTER OPERATOR ^~ (ltree, lquery)
81 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
82 ALTER OPERATOR ^~ (lquery, ltree)
83 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
84 ALTER OPERATOR ? (ltree, _lquery)
85 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
86 ALTER OPERATOR ? (_lquery, ltree)
87 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
88 ALTER OPERATOR ^? (ltree, _lquery)
89 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
90 ALTER OPERATOR ^? (_lquery, ltree)
91 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
92 ALTER OPERATOR @ (ltree, ltxtquery)
93 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
94 ALTER OPERATOR @ (ltxtquery, ltree)
95 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
96 ALTER OPERATOR ^@ (ltree, ltxtquery)
97 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
98 ALTER OPERATOR ^@ (ltxtquery, ltree)
99 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
100 ALTER OPERATOR @> (_ltree, ltree)
101 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
102 ALTER OPERATOR <@ (ltree, _ltree)
103 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
104 ALTER OPERATOR <@ (_ltree, ltree)
105 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
106 ALTER OPERATOR @> (ltree, _ltree)
107 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
108 ALTER OPERATOR ~ (_ltree, lquery)
109 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
110 ALTER OPERATOR ~ (lquery, _ltree)
111 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
112 ALTER OPERATOR ? (_ltree, _lquery)
113 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
114 ALTER OPERATOR ? (_lquery, _ltree)
115 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
116 ALTER OPERATOR @ (_ltree, ltxtquery)
117 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
118 ALTER OPERATOR @ (ltxtquery, _ltree)
119 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
120 ALTER OPERATOR ^@> (_ltree, ltree)
121 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
122 ALTER OPERATOR ^<@ (ltree, _ltree)
123 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
124 ALTER OPERATOR ^<@ (_ltree, ltree)
125 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
126 ALTER OPERATOR ^@> (ltree, _ltree)
127 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
128 ALTER OPERATOR ^~ (_ltree, lquery)
129 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
130 ALTER OPERATOR ^~ (lquery, _ltree)
131 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
132 ALTER OPERATOR ^? (_ltree, _lquery)
133 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
134 ALTER OPERATOR ^? (_lquery, _ltree)
135 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
136 ALTER OPERATOR ^@ (_ltree, ltxtquery)
137 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);
138 ALTER OPERATOR ^@ (ltxtquery, _ltree)
139 SET (RESTRICT = matchingsel, JOIN = matchingjoinsel);