Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
1308d6dd
Commit
1308d6dd
authored
Dec 02, 2007
by
Tom Lane
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Remove README files now migrated to SGML docs.
parent
ec2ff520
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
2 additions
and
97 deletions
+2
-97
contrib/dict_int/Makefile
contrib/dict_int/Makefile
+1
-2
contrib/dict_int/README.dict_int
contrib/dict_int/README.dict_int
+0
-41
contrib/dict_xsyn/Makefile
contrib/dict_xsyn/Makefile
+1
-2
contrib/dict_xsyn/README.dict_xsyn
contrib/dict_xsyn/README.dict_xsyn
+0
-52
No files found.
contrib/dict_int/Makefile
View file @
1308d6dd
# $PostgreSQL: pgsql/contrib/dict_int/Makefile,v 1.
1 2007/10/15 21:36:50
tgl Exp $
# $PostgreSQL: pgsql/contrib/dict_int/Makefile,v 1.
2 2007/12/02 21:15:38
tgl Exp $
MODULE_big
=
dict_int
MODULE_big
=
dict_int
OBJS
=
dict_int.o
OBJS
=
dict_int.o
DATA_built
=
dict_int.sql
DATA_built
=
dict_int.sql
DATA
=
uninstall_dict_int.sql
DATA
=
uninstall_dict_int.sql
DOCS
=
README.dict_int
REGRESS
=
dict_int
REGRESS
=
dict_int
ifdef
USE_PGXS
ifdef
USE_PGXS
...
...
contrib/dict_int/README.dict_int
deleted
100644 → 0
View file @
ec2ff520
Dictionary for integers
=======================
The motivation for this example dictionary is to control the indexing of
integers (signed and unsigned), and, consequently, to minimize the number of
unique words which greatly affect the performance of searching.
* Configuration
The dictionary accepts two options:
- The MAXLEN parameter specifies the maximum length (number of digits)
allowed in an integer word. The default value is 6.
- The REJECTLONG parameter specifies if an overlength integer should be
truncated or ignored. If REJECTLONG=FALSE (default), the dictionary returns
the first MAXLEN digits of the integer. If REJECTLONG=TRUE, the
dictionary treats an overlength integer as a stop word, so that it will
not be indexed.
* Usage
1. Compile and install
2. Load dictionary
psql mydb < dict_int.sql
3. Test it
mydb# select ts_lexize('intdict', '12345678');
ts_lexize
-----------
{123456}
4. Change its options as you wish
mydb# ALTER TEXT SEARCH DICTIONARY intdict (MAXLEN = 4, REJECTLONG = true);
ALTER TEXT SEARCH DICTIONARY
That's all.
contrib/dict_xsyn/Makefile
View file @
1308d6dd
# $PostgreSQL: pgsql/contrib/dict_xsyn/Makefile,v 1.
2 2007/10/16 15:59:59
tgl Exp $
# $PostgreSQL: pgsql/contrib/dict_xsyn/Makefile,v 1.
3 2007/12/02 21:15:38
tgl Exp $
MODULE_big
=
dict_xsyn
MODULE_big
=
dict_xsyn
OBJS
=
dict_xsyn.o
OBJS
=
dict_xsyn.o
DATA_built
=
dict_xsyn.sql
DATA_built
=
dict_xsyn.sql
DATA
=
uninstall_dict_xsyn.sql
DATA
=
uninstall_dict_xsyn.sql
DATA_TSEARCH
=
xsyn_sample.rules
DATA_TSEARCH
=
xsyn_sample.rules
DOCS
=
README.dict_xsyn
REGRESS
=
dict_xsyn
REGRESS
=
dict_xsyn
ifdef
USE_PGXS
ifdef
USE_PGXS
...
...
contrib/dict_xsyn/README.dict_xsyn
deleted
100644 → 0
View file @
ec2ff520
Extended Synonym dictionary
===========================
This is a simple synonym dictionary. It replaces words with groups of their
synonyms, and so makes it possible to search for a word using any of its
synonyms.
* Configuration
It accepts the following options:
- KEEPORIG controls whether the original word is included, or only its
synonyms. Default is 'true'.
- RULES is the base name of the file containing the list of synonyms.
This file must be in $(prefix)/share/tsearch_data/, and its name must
end in ".rules" (which is not included in the RULES parameter).
The rules file has the following format:
- Each line represents a group of synonyms for a single word, which is
given first on the line. Synonyms are separated by whitespace:
word syn1 syn2 syn3
- Sharp ('#') sign is a comment delimiter. It may appear at any position
inside the line. The rest of the line will be skipped.
Look at xsyn_sample.rules, which is installed in $(prefix)/share/tsearch_data/,
for an example.
* Usage
1. Compile and install
2. Load dictionary
psql mydb < dict_xsyn.sql
3. Test it
mydb=# SELECT ts_lexize('xsyn','word');
ts_lexize
----------------
{word,syn1,syn2,syn3)
4. Change the dictionary options as you wish
mydb# ALTER TEXT SEARCH DICTIONARY xsyn (KEEPORIG=false);
ALTER TEXT SEARCH DICTIONARY
That's all.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment