Skip to content

Commit 7866a76

Browse files
committed
README fixes
1 parent 0cdc098 commit 7866a76

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

README.md

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@ The **rum** module provides the access method **rum** and the operator class
3232

3333
The module provides new operators.
3434

35-
| Operator | Returns | Description
36-
| ------------------- | ------- | ----------------------------------------------
37-
| tsvector >< tsquery | float4 | Returns distance between tsvector and tsquery.
35+
| Operator | Returns | Description
36+
| -------------------- | ------- | ----------------------------------------------
37+
| tsvector <-> tsquery | float4 | Returns distance between tsvector and tsquery.
3838

3939
## Examples
4040

@@ -67,15 +67,21 @@ CREATE INDEX rumidx ON test_rum USING rum (a rum_tsvector_ops);
6767
And we can execute the following queries:
6868

6969
```sql
70-
=# SELECT t, a >< to_tsquery('english', 'beautiful | place') AS rank FROM test_rum WHERE a @@ to_tsquery('english', 'beautiful | place') order by a >< to_tsquery('english', 'beautiful | place');
70+
=# SELECT t, a <-> to_tsquery('english', 'beautiful | place') AS rank
71+
FROM test_rum
72+
WHERE a @@ to_tsquery('english', 'beautiful | place')
73+
ORDER BY a <-> to_tsquery('english', 'beautiful | place');
7174
t | rank
7275
---------------------------------+-----------
7376
The situation is most beautiful | 0.0303964
7477
It is a beautiful | 0.0303964
7578
It looks like a beautiful place | 0.0607927
7679
(3 rows)
7780

78-
=# SELECT t, a >< to_tsquery('english', 'place | situation') AS rank FROM test_rum WHERE a @@ to_tsquery('english', 'place | situation') order by a >< to_tsquery('english', 'place | situation');
81+
=# SELECT t, a <-> to_tsquery('english', 'place | situation') AS rank
82+
FROM test_rum
83+
WHERE a @@ to_tsquery('english', 'place | situation')
84+
ORDER BY a <-> to_tsquery('english', 'place | situation');
7985
t | rank
8086
---------------------------------+-----------
8187
The situation is most beautiful | 0.0303964

0 commit comments

Comments
 (0)