Skip to content

Commit 28568e5

Browse files
author
Neil Conway
committed
Spelling and related minor fixes for the GIN docs.
1 parent ce3d1a4 commit 28568e5

File tree

1 file changed

+26
-27
lines changed

1 file changed

+26
-27
lines changed

doc/src/sgml/gin.sgml

Lines changed: 26 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<!-- $PostgreSQL: pgsql/doc/src/sgml/gin.sgml,v 2.4 2006/09/18 12:11:36 teodor Exp $ -->
1+
<!-- $PostgreSQL: pgsql/doc/src/sgml/gin.sgml,v 2.5 2006/11/23 05:58:01 neilc Exp $ -->
22

33
<chapter id="GIN">
44
<title>GIN Indexes</title>
@@ -31,14 +31,13 @@
3131
This is much the same advantage as using <acronym>GiST</acronym>.
3232
</para>
3333

34-
<para>
35-
The <acronym>GIN</acronym>
36-
implementation in <productname>PostgreSQL</productname> is primarily
37-
maintained by Teodor Sigaev and Oleg Bartunov, and there is more
38-
information on their
39-
<ulink url="http://www.sai.msu.su/~megera/oddmuse/index.cgi/Gin">website</ulink>.
40-
</para>
41-
34+
<para>
35+
The <acronym>GIN</acronym>
36+
implementation in <productname>PostgreSQL</productname> is primarily
37+
maintained by Teodor Sigaev and Oleg Bartunov. There is more
38+
information about <acronym>GIN</acronym> on their
39+
<ulink url="http://www.sai.msu.su/~megera/oddmuse/index.cgi/Gin">website</ulink>.
40+
</para>
4241
</sect1>
4342

4443
<sect1 id="gin-extensibility">
@@ -78,7 +77,7 @@
7877

7978
<variablelist>
8079
<varlistentry>
81-
<term>int compare( Datum a, Datum b )</term>
80+
<term>int compare(Datum a, Datum b)</term>
8281
<listitem>
8382
<para>
8483
Compares keys (not indexed values!) and returns an integer less than
@@ -103,22 +102,22 @@
103102
StrategyNumber n)</term>
104103
<listitem>
105104
<para>
106-
Returns an array of keys of the query to be executed. n contains
107-
the strategy number of the operation
108-
(see <xref linkend="xindex-strategies">).
109-
Depending on n, query may be different type.
105+
Returns an array of keys of the query to be executed. n contains the
106+
strategy number of the operation (see <xref
107+
linkend="xindex-strategies">). Depending on n, query may be
108+
different type.
110109
</para>
111110
</listitem>
112111
</varlistentry>
113112

114113
<varlistentry>
115-
<term>bool consistent( bool check[], StrategyNumber n, Datum query)</term>
114+
<term>bool consistent(bool check[], StrategyNumber n, Datum query)</term>
116115
<listitem>
117116
<para>
118117
Returns TRUE if the indexed value satisfies the query qualifier with
119118
strategy n (or may satisfy in case of RECHECK mark in operator class).
120119
Each element of the check array is TRUE if the indexed value has a
121-
corresponding key in the query: if (check[i] == TRUE ) the i-th key of
120+
corresponding key in the query: if (check[i] == TRUE) the i-th key of
122121
the query is present in the indexed value.
123122
</para>
124123
</listitem>
@@ -129,14 +128,14 @@
129128
</sect1>
130129

131130
<sect1 id="gin-tips">
132-
<title>GIN tips and trics</title>
131+
<title>GIN tips and tricks</title>
133132

134133
<variablelist>
135134
<varlistentry>
136135
<term>Create vs insert</term>
137136
<listitem>
138137
<para>
139-
In most cases, insertion into <acronym>GIN</acronym> index is slow
138+
In most cases, insertion into a <acronym>GIN</acronym> index is slow
140139
due to the likelihood of many keys being inserted for each value.
141140
So, for bulk insertions into a table it is advisable to to drop the GIN
142141
index and recreate it after finishing bulk insertion.
@@ -169,9 +168,9 @@
169168
the whole result set, chosen at random.
170169
</para>
171170
<para>
172-
"Soft" means that the actual number of returned results could slightly
173-
differ from the specified limit, depending on the query and the quality
174-
of the system's random number generator.
171+
<quote>Soft</quote> means that the actual number of returned results
172+
could slightly differ from the specified limit, depending on the query
173+
and the quality of the system's random number generator.
175174
</para>
176175
</listitem>
177176
</varlistentry>
@@ -184,16 +183,16 @@
184183

185184
<para>
186185
<acronym>GIN</acronym> doesn't support full index scans due to their
187-
extremely inefficiency: because there are often many keys per value,
186+
extreme inefficiency: because there are often many keys per value,
188187
each heap pointer will returned several times.
189188
</para>
190189

191190
<para>
192-
When extractQuery returns zero keys, <acronym>GIN</acronym> will emit a
193-
error: for different opclasses and strategies the semantic meaning of a void
194-
query may be different (for example, any array contains the void array,
195-
but they don't overlap the void array), and <acronym>GIN</acronym> can't
196-
suggest reasonable answer.
191+
When <function>extractQuery</function> returns zero keys,
192+
<acronym>GIN</acronym> will emit an error: for different opclasses and
193+
strategies the semantic meaning of a void query may be different (for
194+
example, any array contains the void array, but they don't overlap the
195+
void array), and <acronym>GIN</acronym> can't suggest a reasonable answer.
197196
</para>
198197

199198
<para>

0 commit comments

Comments
 (0)