Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commite6facb1

Browse files
authored
Merge pull request#114 from shadforth/update-readme
Update README with small language tweaks
2 parents919c74f +775de3b commite6facb1

File tree

1 file changed

+34
-33
lines changed

1 file changed

+34
-33
lines changed

‎README.md

Lines changed: 34 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -8,38 +8,38 @@
88

99
##Introduction
1010

11-
The**rum** module provides access method to work with`RUM` index. It is based
12-
on the`GIN` accessmethods code.
11+
The**rum** module providesanaccess method to work with a`RUM` index. It is based
12+
on the`GIN` accessmethod's code.
1313

14-
`GIN` index allowsto performfast fulltext search using`tsvector` and
15-
`tsquery` types. But fulltext search with GIN index has several problems:
14+
A`GIN` index allowsperformingfast full-text search using`tsvector` and
15+
`tsquery` types. But full-text search with a GIN index has several problems:
1616

17-
- Slow ranking. Itis need positioninformation aboutlexems to ranking.`GIN`
18-
index doesn't store positions oflexems. So after indexscan we needadditional
19-
heap scan to retrievelexems positions.
20-
- Slow phrase search with`GIN` index. This problem relateswith previous
21-
problem. Itis need position information to perform phrase search.
22-
- Slow ordering by timestamp.`GIN` index can't store some related information
23-
in index with lexemes. So it is necessary to perform additional heap scan.
17+
- Slow ranking. Itneeds positionalinformation aboutlexemes todoranking. A`GIN`
18+
index doesn't store positions oflexemes. So after indexscanning, we needan
19+
additionalheap scan to retrievelexeme positions.
20+
- Slow phrase search witha`GIN` index. This problem relatesto the previous
21+
problem. Itneeds positional information to perform phrase search.
22+
- Slow ordering by timestamp.A`GIN` index can't store some related information
23+
intheindex with lexemes. So it is necessary to perform an additional heap scan.
2424

25-
`RUM` solvesthis problems by storing additional information in posting tree.
25+
`RUM` solvesthese problems by storing additional information in a posting tree.
2626
For example, positional information of lexemes or timestamps. You can get an
27-
idea of`RUM`by the followingpicture:
27+
idea of`RUM`with the followingdiagram:
2828

2929
![How RUM stores additional information](img/gin_rum.png)
3030

31-
Drawbackof`RUM` is that it has slower build and inserttime than`GIN`.
32-
It is because we need to store additional information besides keys and because
33-
`RUM` uses generic WAL records.
31+
A drawbackof`RUM` is that it has slower build and inserttimes than`GIN`.
32+
This is because we need to store additional information besides keys and because
33+
`RUM` uses genericWrite-Ahead Log (WAL) records.
3434

3535
##License
3636

37-
This module available under the[license](LICENSE) similar to
37+
This moduleisavailable under the[license](LICENSE) similar to
3838
[PostgreSQL](http://www.postgresql.org/about/licence/).
3939

4040
##Installation
4141

42-
Beforebuild andinstall**rum** you should ensure following:
42+
Beforebuilding andinstalling**rum**, you should ensure following are installed:
4343

4444
* PostgreSQL version is 9.6+.
4545

@@ -62,7 +62,7 @@ Typical installation procedure may look like this:
6262
6363
##Common operators and functions
6464

65-
**rum** module provides next operators.
65+
The**rum** module provides next operators.
6666

6767
| Operator | Returns | Description
6868
| -------------------- | ------- | ----------------------------------------------
@@ -71,19 +71,19 @@ Typical installation procedure may look like this:
7171
| timestamp<=| timestamp | float8 | Returns distance only for left timestamps.
7272
| timestamp|=> timestamp | float8 | Returns distance only for right timestamps.
7373

74-
Lastthree operations alsoworks for types timestamptz, int2, int4, int8, float4, float8,
74+
The lastthree operations alsowork for types timestamptz, int2, int4, int8, float4, float8,
7575
money and oid.
7676

7777
##Operator classes
7878

79-
**rum** providesnext operator classes.
79+
**rum** providesthe following operator classes.
8080

8181
###rum_tsvector_ops
8282

8383
For type:`tsvector`
8484

85-
This operator class stores`tsvector` lexemes with positional information.Supports
86-
ordering by`<=>` operator and prefix search.There isthe example.
85+
This operator class stores`tsvector` lexemes with positional information.It supports
86+
ordering bythe`<=>` operator and prefix search.Seethe example below.
8787

8888
Let us assume we have the table:
8989

@@ -140,8 +140,8 @@ SELECT t, a <=> to_tsquery('english', 'place | situation') AS rank
140140

141141
For type:`tsvector`
142142

143-
This operator class stores hash of`tsvector` lexemes with positional information.
144-
Supportsordering by`<=>` operator.But**doesn't** support prefix search.
143+
This operator class storesahash of`tsvector` lexemes with positional information.
144+
It supportsordering bythe`<=>` operator.It**doesn't** support prefix search.
145145

146146
###rum_TYPE_ops
147147

@@ -153,17 +153,18 @@ Supported operations: `<`, `<=`, `=`, `>=`, `>` for all types and
153153
`<=>`,`<=|` and`|=>` for int2, int4, int8, float4, float8, money, oid,
154154
timestamp and timestamptz types.
155155

156-
Supportsordering by`<=>`,`<=|` and`|=>` operators.Can be used with
156+
This operator supportsordering bythe`<=>`,`<=|` and`|=>` operators.It can be used with
157157
`rum_tsvector_addon_ops`,`rum_tsvector_hash_addon_ops' and`rum_anyarray_addon_ops` operator classes.
158158

159159
###rum_tsvector_addon_ops
160160

161161
For type:`tsvector`
162162

163-
This operator class stores`tsvector`lexems with any supported by module
164-
field.There isthe example.
163+
This operator class stores`tsvector`lexemes with any supported by module
164+
field.Seethe example below.
165165

166166
Let us assume we have the table:
167+
167168
```sql
168169
CREATETABLEtsts (idint, t tsvector, dtimestamp);
169170

@@ -202,16 +203,16 @@ SELECT id, d, d <=> '2016-05-16 14:21:25' FROM tsts WHERE t @@ 'wr&qh' ORDER BY
202203

203204
For type:`tsvector`
204205

205-
This operator class stores hash of`tsvector`lexems with any supported by module
206+
This operator class storesahash of`tsvector`lexemes with any supported by module
206207
field.
207208

208-
**Doesn't** support prefix search.
209+
It**doesn't** support prefix search.
209210

210211
###rum_tsquery_ops
211212

212213
For type:`tsquery`
213214

214-
Storesbranches of query tree in additional information. For example we have the table:
215+
It storesbranches of query tree in additional information. For example, we have the table:
215216
```sql
216217
CREATETABLEquery (q tsquery, tagtext);
217218

@@ -240,8 +241,8 @@ SELECT * FROM query
240241
For type:`anyarray`
241242

242243
This operator class stores`anyarray` elements with length of the array.
243-
Supportsoperators`&&`,`@>`,`<@`,`=`,`%` operators.Supports ordering by`<=>` operator.
244-
For example we have the table:
244+
It supportsoperators`&&`,`@>`,`<@`,`=`,`%` operators.It also supports ordering by`<=>` operator.
245+
For example, we have the table:
245246

246247
```sql
247248
CREATETABLEtest_array (i int2[]);

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp