1
- <!-- $PostgreSQL: pgsql/doc/src/sgml/textsearch.sgml,v 1.26 2007/10/25 13:06:35 alvherre Exp $ -->
1
+ <!-- $PostgreSQL: pgsql/doc/src/sgml/textsearch.sgml,v 1.27 2007/10/27 00:19:45 tgl Exp $ -->
2
2
3
3
<chapter id="textsearch">
4
4
<title id="textsearch-title">Full Text Search</title>
@@ -1770,7 +1770,7 @@ LIMIT 10;
1770
1770
<row>
1771
1771
<entry><literal>hword</></entry>
1772
1772
<entry>Hyphenated word, all letters</entry>
1773
- <entry><literal>político-militar </literal></entry>
1773
+ <entry><literal>lógico-matemática </literal></entry>
1774
1774
</row>
1775
1775
<row>
1776
1776
<entry><literal>numhword</></entry>
@@ -1780,14 +1780,13 @@ LIMIT 10;
1780
1780
<row>
1781
1781
<entry><literal>hword_asciipart</></entry>
1782
1782
<entry>Hyphenated word part, all ASCII</entry>
1783
- <entry><literal>militar</literal> in the context
1784
- <literal>político-militar</literal>, or <literal>postgresql</literal> in the context <literal>postgresql-beta1</literal></entry>
1783
+ <entry><literal>postgresql</literal> in the context <literal>postgresql-beta1</literal></entry>
1785
1784
</row>
1786
1785
<row>
1787
1786
<entry><literal>hword_part</></entry>
1788
1787
<entry>Hyphenated word part, all letters</entry>
1789
- <entry><literal>físico </literal> or <literal>químico </literal>
1790
- in the context <literal>físico-químico </literal></entry>
1788
+ <entry><literal>lógico </literal> or <literal>matemática </literal>
1789
+ in the context <literal>lógico-matemática </literal></entry>
1791
1790
</row>
1792
1791
<row>
1793
1792
<entry><literal>hword_numpart</></entry>
@@ -1902,12 +1901,12 @@ SELECT alias, description, token FROM ts_debug('foo-bar-beta1');
1902
1901
instructive example:
1903
1902
1904
1903
<programlisting>
1905
- SELECT alias, description, token FROM ts_debug('http://foo .com/stuff/index.html');
1906
- alias | description | token
1907
- ----------+---------------+--------------------------
1904
+ SELECT alias, description, token FROM ts_debug('http://example .com/stuff/index.html');
1905
+ alias | description | token
1906
+ ----------+---------------+------------------------------
1908
1907
protocol | Protocol head | http://
1909
- url | URL | foo .com/stuff/index.html
1910
- host | Host | foo .com
1908
+ url | URL | example .com/stuff/index.html
1909
+ host | Host | example .com
1911
1910
uri | URI | /stuff/index.html
1912
1911
</programlisting>
1913
1912
</para>
@@ -3093,8 +3092,9 @@ SELECT plainto_tsquery('supernovae stars');
3093
3092
</para>
3094
3093
3095
3094
<para>
3096
- A GiST index is <firstterm>lossy</firstterm>, meaning it is necessary
3097
- to check the actual table row to eliminate false matches.
3095
+ A GiST index is <firstterm>lossy</firstterm>, meaning that the index
3096
+ may produce false matches, and it is necessary
3097
+ to check the actual table row to eliminate such false matches.
3098
3098
<productname>PostgreSQL</productname> does this automatically; for
3099
3099
example, in the query plan below, the <literal>Filter:</literal>
3100
3100
line indicates the index output will be rechecked:
@@ -3112,14 +3112,15 @@ EXPLAIN SELECT * FROM apod WHERE textsearch @@ to_tsquery('supernovae');
3112
3112
index by a fixed-length signature. The signature is generated by hashing
3113
3113
each word into a random bit in an n-bit string, with all these bits OR-ed
3114
3114
together to produce an n-bit document signature. When two words hash to
3115
- the same bit position there will be a false match, and if all words in
3115
+ the same bit position there will be a false match. If all words in
3116
3116
the query have matches (real or false) then the table row must be
3117
3117
retrieved to see if the match is correct.
3118
3118
</para>
3119
3119
3120
3120
<para>
3121
- Lossiness causes performance degradation since random access to table
3122
- records is slow; this limits the usefulness of GiST indexes. The
3121
+ Lossiness causes performance degradation due to useless fetches of table
3122
+ records that turn out to be false matches. Since random access to table
3123
+ records is slow, this limits the usefulness of GiST indexes. The
3123
3124
likelihood of false matches depends on several factors, in particular the
3124
3125
number of unique words, so using dictionaries to reduce this number is
3125
3126
recommended.
0 commit comments