@@ -7,6 +7,7 @@ CREATE INDEX rumhashidx ON test_rum_hash USING rum (a rum_tsvector_hash_ops);
77CREATE INDEX failed_rumidx ON test_rum_hash USING rum (a rum_tsvector_addon_ops);
88ERROR: additional information attribute "a" is not found in index
99SET enable_seqscan=off;
10+ SET enable_indexscan=off;
1011explain (costs off)
1112SELECT count(*) FROM test_rum_hash WHERE a @@ to_tsquery('pg_catalog.english', 'ever|wrote');
1213 QUERY PLAN
@@ -34,12 +35,14 @@ ORDER BY a <=> to_tsquery('pg_catalog.english', 'ever|wrote');
3435explain (costs off)
3536SELECT count(*) FROM test_rum_hash WHERE a @@ to_tsquery('pg_catalog.english',
3637 'def <-> fgr');
37- QUERY PLAN
38- -----------------------------------------------------------
38+ QUERY PLAN
39+ -----------------------------------------------------------------
3940 Aggregate
40- -> Index Scan using rumhashidx on test_rum_hash
41- Index Cond: (a @@ '''def'' <-> ''fgr'''::tsquery)
42- (3 rows)
41+ -> Bitmap Heap Scan on test_rum_hash
42+ Recheck Cond: (a @@ '''def'' <-> ''fgr'''::tsquery)
43+ -> Bitmap Index Scan on rumhashidx
44+ Index Cond: (a @@ '''def'' <-> ''fgr'''::tsquery)
45+ (5 rows)
4346
4447SELECT count(*) FROM test_rum_hash WHERE a @@ to_tsquery('pg_catalog.english', 'ever|wrote');
4548 count
@@ -287,6 +290,7 @@ DELETE FROM tst_hash WHERE i = 5;
287290VACUUM tst_hash;
288291INSERT INTO tst_hash SELECT i%10, to_tsvector('simple', substr(md5(i::text), 1, 1)) FROM generate_series(14001,15000) i;
289292set enable_bitmapscan=off;
293+ SET enable_indexscan=on;
290294explain (costs off)
291295SELECT a <=> to_tsquery('pg_catalog.english', 'w:*'), *
292296 FROM test_rum_hash
0 commit comments