aboutsummaryrefslogtreecommitdiff
path: root/src/backend
diff options
context:
space:
mode:
Diffstat (limited to 'src/backend')
-rw-r--r--src/backend/tsearch/Makefile5
-rw-r--r--src/backend/tsearch/hunspell_sample.affix24
-rw-r--r--src/backend/tsearch/ispell_sample.affix26
-rw-r--r--src/backend/tsearch/ispell_sample.dict8
-rw-r--r--src/backend/tsearch/synonym.syn.sample3
-rw-r--r--src/backend/tsearch/synonym_sample.syn4
-rw-r--r--src/backend/tsearch/thesaurus_sample.ths (renamed from src/backend/tsearch/thesaurus.ths.sample)10
7 files changed, 69 insertions, 11 deletions
diff --git a/src/backend/tsearch/Makefile b/src/backend/tsearch/Makefile
index d5076ef18d4..720a5366677 100644
--- a/src/backend/tsearch/Makefile
+++ b/src/backend/tsearch/Makefile
@@ -4,7 +4,7 @@
#
# Copyright (c) 2006-2007, PostgreSQL Global Development Group
#
-# $PostgreSQL: pgsql/src/backend/tsearch/Makefile,v 1.2 2007/08/22 06:11:56 tgl Exp $
+# $PostgreSQL: pgsql/src/backend/tsearch/Makefile,v 1.3 2007/09/11 11:54:42 teodor Exp $
#
#-------------------------------------------------------------------------
subdir = src/backend/tsearch
@@ -13,7 +13,8 @@ include $(top_builddir)/src/Makefile.global
DICTDIR=tsearch_data
-DICTFILES=synonym.syn.sample thesaurus.ths.sample
+DICTFILES=synonym_sample.syn thesaurus_sample.ths hunspell_sample.affix \
+ ispell_sample.affix ispell_sample.dict
OBJS = ts_locale.o ts_parse.o wparser.o wparser_def.o dict.o \
dict_simple.o dict_synonym.o dict_thesaurus.o \
diff --git a/src/backend/tsearch/hunspell_sample.affix b/src/backend/tsearch/hunspell_sample.affix
new file mode 100644
index 00000000000..d1984c295fb
--- /dev/null
+++ b/src/backend/tsearch/hunspell_sample.affix
@@ -0,0 +1,24 @@
+COMPOUNDFLAG Z
+ONLYINCOMPOUND L
+
+PFX B Y 1
+PFX B 0 re .
+
+PFX U N 1
+PFX U 0 un .
+
+SFX J Y 1
+SFX J 0 INGS [^E]
+
+SFX G Y 1
+SFX G 0 ING [^E]
+
+SFX S Y 1
+SFX S 0 S [^SXZHY]
+
+SFX A Y 1
+SFX A Y IES [^AEIOU]Y
+
+SFX \ N 1
+SFX \ 0 Y/L [^Y]
+
diff --git a/src/backend/tsearch/ispell_sample.affix b/src/backend/tsearch/ispell_sample.affix
new file mode 100644
index 00000000000..f29004ff1da
--- /dev/null
+++ b/src/backend/tsearch/ispell_sample.affix
@@ -0,0 +1,26 @@
+compoundwords controlled Z
+
+prefixes
+
+flag *B:
+ . > RE # As in enter > reenter
+
+flag U:
+ . > UN # As in natural > unnatural
+
+suffixes
+
+flag *J:
+ [^E] > INGS # As in cross > crossings
+
+flag *G:
+ [^E] > ING # As in cross > crossing
+
+flag *S:
+ [^SXZHY] > S # As in bat > bats
+
+flag *A:
+ [^AEIOU]Y > -Y,IES # As in imply > implies
+
+flag ~\\:
+ [^Y] > Y #~ advarsel > advarsely-
diff --git a/src/backend/tsearch/ispell_sample.dict b/src/backend/tsearch/ispell_sample.dict
new file mode 100644
index 00000000000..44df1967a6c
--- /dev/null
+++ b/src/backend/tsearch/ispell_sample.dict
@@ -0,0 +1,8 @@
+book/GJUS
+booking/SB
+footballklubber
+foot/ZS
+football/Z
+ball/SZ\
+klubber/Z
+sky/A
diff --git a/src/backend/tsearch/synonym.syn.sample b/src/backend/tsearch/synonym.syn.sample
deleted file mode 100644
index fdccca102b4..00000000000
--- a/src/backend/tsearch/synonym.syn.sample
+++ /dev/null
@@ -1,3 +0,0 @@
-skies sky
-booking book
-bookings book
diff --git a/src/backend/tsearch/synonym_sample.syn b/src/backend/tsearch/synonym_sample.syn
new file mode 100644
index 00000000000..4e2eaeec0c1
--- /dev/null
+++ b/src/backend/tsearch/synonym_sample.syn
@@ -0,0 +1,4 @@
+postgres pgsql
+postgresql pgsql
+postgre pgsql
+gogle googl
diff --git a/src/backend/tsearch/thesaurus.ths.sample b/src/backend/tsearch/thesaurus_sample.ths
index 7e7702e2ae4..b83d8f1452a 100644
--- a/src/backend/tsearch/thesaurus.ths.sample
+++ b/src/backend/tsearch/thesaurus_sample.ths
@@ -11,10 +11,8 @@ one two : *12
one : *1
two : *2
-#foo bar : blah blah
-#f bar : fbar
-#e bar : ebar
-#g bar bar : gbarbar
-#asd:sdffff
-#qwerty:qwer wert erty
+supernovae stars : *sn
+supernovae : *sn
+booking tickets : order invitation cards
+booking the tickets : order invitation Cards