|
1 | 1 | CREATE TABLE test_hash (a int, b text);
|
2 | 2 | INSERT INTO test_hash VALUES (1, 'one');
|
3 | 3 | CREATE INDEX test_hash_a_idx ON test_hash USING hash (a);
|
| 4 | +CREATE TABLE test_hash_part (a int, b int) PARTITION BY RANGE (a); |
| 5 | +CREATE INDEX test_hash_part_idx ON test_hash_part USING hash(b); |
4 | 6 | \x
|
5 | 7 | SELECT hash_page_type(get_raw_page('test_hash_a_idx', 0));
|
6 | 8 | -[ RECORD 1 ]--+---------
|
@@ -44,6 +46,8 @@ SELECT * FROM hash_bitmap_info('test_hash_a_idx', 5);
|
44 | 46 | ERROR: invalid overflow block number 5
|
45 | 47 | SELECT * FROM hash_bitmap_info('test_hash_a_idx', 6);
|
46 | 48 | ERROR: block number 6 is out of range for relation "test_hash_a_idx"
|
| 49 | +SELECT * FROM hash_bitmap_info('test_hash_part_idx', 1); -- error |
| 50 | +ERROR: "test_hash_part_idx" is not a hash index |
47 | 51 | SELECT magic, version, ntuples, bsize, bmsize, bmshift, maxbucket, highmask,
|
48 | 52 | lowmask, ovflpoint, firstfree, nmaps, procid, spares, mapp FROM
|
49 | 53 | hash_metapage_info(get_raw_page('test_hash_a_idx', 0));
|
@@ -203,3 +207,4 @@ SELECT hash_page_type(decode(repeat('00', :block_size), 'hex'));
|
203 | 207 | hash_page_type | unused
|
204 | 208 |
|
205 | 209 | DROP TABLE test_hash;
|
| 210 | +DROP TABLE test_hash_part; |
0 commit comments