Skip to content

Commit dad098c

Browse files
committed
rename tsvector function in pg_proc, docs, tests
1 parent a712487 commit dad098c

File tree

4 files changed

+104
-104
lines changed

4 files changed

+104
-104
lines changed

doc/src/sgml/func.sgml

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -9252,26 +9252,26 @@ CREATE TYPE rainbow AS ENUM ('red', 'orange', 'yellow', 'green', 'blue', 'purple
92529252
<row>
92539253
<entry>
92549254
<indexterm>
9255-
<primary>setweight</primary>
9255+
<primary>ts_setweight</primary>
92569256
</indexterm>
9257-
<literal><function>setweight(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">weight</replaceable> <type>"char"</>)</function></literal>
9257+
<literal><function>ts_setweight(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">weight</replaceable> <type>"char"</>)</function></literal>
92589258
</entry>
92599259
<entry><type>tsvector</type></entry>
92609260
<entry>assign <replaceable class="PARAMETER">weight</replaceable> to each element of <replaceable class="PARAMETER">vector</replaceable></entry>
9261-
<entry><literal>setweight('fat:2,4 cat:3 rat:5B'::tsvector, 'A')</literal></entry>
9261+
<entry><literal>ts_setweight('fat:2,4 cat:3 rat:5B'::tsvector, 'A')</literal></entry>
92629262
<entry><literal>'cat':3A 'fat':2A,4A 'rat':5A</literal></entry>
92639263
</row>
92649264
<row>
92659265
<entry>
92669266
<indexterm>
9267-
<primary>setweight</primary>
9268-
<secondary>setweight for specific lexeme(s)</secondary>
9267+
<primary>ts_setweight</primary>
9268+
<secondary>ts_setweight for specific lexeme(s)</secondary>
92699269
</indexterm>
9270-
<literal><function>setweight(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">weight</replaceable> <type>"char"</>, <replaceable class="PARAMETER">lexemes</replaceable> <type>"text"[]</>)</function></literal>
9270+
<literal><function>ts_setweight(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">weight</replaceable> <type>"char"</>, <replaceable class="PARAMETER">lexemes</replaceable> <type>"text"[]</>)</function></literal>
92719271
</entry>
92729272
<entry><type>tsvector</type></entry>
92739273
<entry>assign <replaceable class="PARAMETER">weight</replaceable> to elements of <replaceable class="PARAMETER">vector</replaceable> that are listed in <replaceable class="PARAMETER">lexemes</replaceable> array</entry>
9274-
<entry><literal>setweight('fat:2,4 cat:3 rat:5B'::tsvector, 'A', '{cat,rat}')</literal></entry>
9274+
<entry><literal>ts_setweight('fat:2,4 cat:3 rat:5B'::tsvector, 'A', '{cat,rat}')</literal></entry>
92759275
<entry><literal>'cat':3A 'fat':2,4 'rat':5A</literal></entry>
92769276
</row>
92779277
<row>
@@ -9289,37 +9289,37 @@ CREATE TYPE rainbow AS ENUM ('red', 'orange', 'yellow', 'green', 'blue', 'purple
92899289
<row>
92909290
<entry>
92919291
<indexterm>
9292-
<primary>delete</primary>
9293-
<secondary>delete lexeme(s) from tsvector</secondary>
9292+
<primary>ts_delete</primary>
9293+
<secondary>ts_delete lexeme(s) from tsvector</secondary>
92949294
</indexterm>
9295-
<literal><function>delete(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">lexeme</replaceable> <type>text</>)</function></literal>
9295+
<literal><function>ts_delete(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">lexeme</replaceable> <type>text</>)</function></literal>
92969296
</entry>
92979297
<entry><type>tsvector</type></entry>
92989298
<entry>remove given <replaceable class="PARAMETER">lexeme</replaceable> from <replaceable class="PARAMETER">vector</replaceable></entry>
9299-
<entry><literal>delete('fat:2,4 cat:3 rat:5A'::tsvector, 'fat')</literal></entry>
9299+
<entry><literal>ts_delete('fat:2,4 cat:3 rat:5A'::tsvector, 'fat')</literal></entry>
93009300
<entry><literal>'cat':3 'rat':5A</literal></entry>
93019301
</row>
93029302
<row>
93039303
<entry>
93049304
<!-- previous indexterm entry covers this too -->
9305-
<literal><function>delete(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">lexemes</replaceable> <type>text[]</>)</function></literal>
9305+
<literal><function>ts_delete(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">lexemes</replaceable> <type>text[]</>)</function></literal>
93069306
</entry>
93079307
<entry><type>tsvector</type></entry>
93089308
<entry>remove any occurrence of lexemes in <replaceable class="PARAMETER">lexemes</replaceable> array from <replaceable class="PARAMETER">vector</replaceable></entry>
9309-
<entry><literal>delete('fat:2,4 cat:3 rat:5A'::tsvector, ARRAY['fat','rat'])</literal></entry>
9309+
<entry><literal>ts_delete('fat:2,4 cat:3 rat:5A'::tsvector, ARRAY['fat','rat'])</literal></entry>
93109310
<entry><literal>'cat':3</literal></entry>
93119311
</row>
93129312
<row>
93139313
<entry>
93149314
<indexterm>
9315-
<primary>unnest</primary>
9315+
<primary>ts_unnest</primary>
93169316
<secondary>for tsvector</secondary>
93179317
</indexterm>
9318-
<literal><function>unnest(<type>tsvector</>, OUT <replaceable class="PARAMETER">lexeme</> <type>text</>, OUT <replaceable class="PARAMETER">positions</> <type>smallint[]</>, OUT <replaceable class="PARAMETER">weights</> <type>text</>)</function></literal>
9318+
<literal><function>ts_unnest(<type>tsvector</>, OUT <replaceable class="PARAMETER">lexeme</> <type>text</>, OUT <replaceable class="PARAMETER">positions</> <type>smallint[]</>, OUT <replaceable class="PARAMETER">weights</> <type>text</>)</function></literal>
93199319
</entry>
93209320
<entry><type>setof record</type></entry>
93219321
<entry>expand a tsvector to a set of rows</entry>
9322-
<entry><literal>unnest('fat:2,4 cat:3 rat:5A'::tsvector)</literal></entry>
9322+
<entry><literal>ts_unnest('fat:2,4 cat:3 rat:5A'::tsvector)</literal></entry>
93239323
<entry><literal>(cat,{3},{D}) ...</literal></entry>
93249324
</row>
93259325
<row>
@@ -9349,14 +9349,14 @@ CREATE TYPE rainbow AS ENUM ('red', 'orange', 'yellow', 'green', 'blue', 'purple
93499349
<row>
93509350
<entry>
93519351
<indexterm>
9352-
<primary>filter</primary>
9352+
<primary>ts_filter</primary>
93539353
<secondary>for tsvector</secondary>
93549354
</indexterm>
9355-
<literal><function>filter(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">weights</replaceable> <type>"char"[]</>)</function></literal>
9355+
<literal><function>ts_filter(<replaceable class="PARAMETER">vector</replaceable> <type>tsvector</>, <replaceable class="PARAMETER">weights</replaceable> <type>"char"[]</>)</function></literal>
93569356
</entry>
93579357
<entry><type>tsvector</type></entry>
93589358
<entry>Select only elements with given <replaceable class="PARAMETER">weights</replaceable> from <replaceable class="PARAMETER">vector</replaceable></entry>
9359-
<entry><literal>filter('fat:2,4 cat:3b rat:5A'::tsvector, '{a,b}')</literal></entry>
9359+
<entry><literal>ts_filter('fat:2,4 cat:3b rat:5A'::tsvector, '{a,b}')</literal></entry>
93609360
<entry><literal>'cat':3B 'rat':5A</literal></entry>
93619361
</row>
93629362
<row>

src/include/catalog/pg_proc.h

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4534,22 +4534,22 @@ DATA(insert OID = 3711 ( length PGNSP PGUID 12 1 0 0 0 f f f f t f i s 1 0 2
45344534
DESCR("number of lexemes");
45354535
DATA(insert OID = 3623 ( strip PGNSP PGUID 12 1 0 0 0 f f f f t f i s 1 0 3614 "3614" _null_ _null_ _null_ _null_ _null_ tsvector_strip _null_ _null_ _null_ ));
45364536
DESCR("strip position information");
4537-
DATA(insert OID = 3624 ( setweight PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3614 "3614 18" _null_ _null_ _null_ _null_ _null_ tsvector_setweight _null_ _null_ _null_ ));
4537+
DATA(insert OID = 3624 ( ts_setweight PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3614 "3614 18" _null_ _null_ _null_ _null_ _null_ tsvector_setweight _null_ _null_ _null_ ));
45384538
DESCR("set given weight for whole tsvector");
4539-
DATA(insert OID = 3320 ( setweight PGNSP PGUID 12 1 0 0 0 f f f f t f i s 3 0 3614 "3614 18 1009" _null_ _null_ _null_ _null_ _null_ tsvector_setweight_by_filter _null_ _null_ _null_ ));
4539+
DATA(insert OID = 3320 ( ts_setweight PGNSP PGUID 12 1 0 0 0 f f f f t f i s 3 0 3614 "3614 18 1009" _null_ _null_ _null_ _null_ _null_ tsvector_setweight_by_filter _null_ _null_ _null_ ));
45404540
DESCR("set given weight for given lexemes");
45414541
DATA(insert OID = 3625 ( tsvector_concat PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3614 "3614 3614" _null_ _null_ _null_ _null_ _null_ tsvector_concat _null_ _null_ _null_ ));
4542-
DATA(insert OID = 3321 ( delete PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3614 "3614 25" _null_ _null_ _null_ _null_ _null_ tsvector_delete_str _null_ _null_ _null_ ));
4542+
DATA(insert OID = 3321 ( ts_delete PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3614 "3614 25" _null_ _null_ _null_ _null_ _null_ tsvector_delete_str _null_ _null_ _null_ ));
45434543
DESCR("delete lexeme");
4544-
DATA(insert OID = 3323 ( delete PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3614 "3614 1009" _null_ _null_ _null_ _null_ _null_ tsvector_delete_arr _null_ _null_ _null_ ));
4544+
DATA(insert OID = 3323 ( ts_delete PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3614 "3614 1009" _null_ _null_ _null_ _null_ _null_ tsvector_delete_arr _null_ _null_ _null_ ));
45454545
DESCR("delete given lexemes");
4546-
DATA(insert OID = 3322 ( unnest PGNSP PGUID 12 1 10 0 0 f f f f t t i s 1 0 2249 "3614" "{3614,25,1005,1009}" "{i,o,o,o}" "{tsvector,lexeme,positions,weights}" _null_ _null_ tsvector_unnest _null_ _null_ _null_ ));
4546+
DATA(insert OID = 3322 ( ts_unnest PGNSP PGUID 12 1 10 0 0 f f f f t t i s 1 0 2249 "3614" "{3614,25,1005,1009}" "{i,o,o,o}" "{tsvector,lexeme,positions,weights}" _null_ _null_ tsvector_unnest _null_ _null_ _null_ ));
45474547
DESCR("expand tsvector to set of rows");
45484548
DATA(insert OID = 3326 ( tsvector_to_array PGNSP PGUID 12 1 0 0 0 f f f f t f i s 1 0 1009 "3614" _null_ _null_ _null_ _null_ _null_ tsvector_to_array _null_ _null_ _null_ ));
45494549
DESCR("convert to lexeme's array");
45504550
DATA(insert OID = 3327 ( array_to_tsvector PGNSP PGUID 12 1 0 0 0 f f f f t f i s 1 0 3614 "1009" _null_ _null_ _null_ _null_ _null_ array_to_tsvector _null_ _null_ _null_ ));
45514551
DESCR("build tsvector from lexeme's array");
4552-
DATA(insert OID = 3319 ( filter PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3614 "3614 1002" _null_ _null_ _null_ _null_ _null_ tsvector_filter _null_ _null_ _null_ ));
4552+
DATA(insert OID = 3319 ( ts_filter PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 3614 "3614 1002" _null_ _null_ _null_ _null_ _null_ tsvector_filter _null_ _null_ _null_ ));
45534553
DESCR("returns tsvector that contain only postings with given weights");
45544554

45554555
DATA(insert OID = 3634 ( ts_match_vq PGNSP PGUID 12 1 0 0 0 f f f f t f i s 2 0 16 "3614 3615" _null_ _null_ _null_ _null_ _null_ ts_match_vq _null_ _null_ _null_ ));

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy