postgres.git / summary / log / commit / refs

commit    8364ef925c59485bc01b36230e9e0099d46ea186
Author:   Amit Kapila <akapila@postgresql.org>
Date:     Wed Sep 18 03:44:26 2019 +0000
First released in: 13.0, 9.4.25, 9.5.20, 9.6.16, 10.11, 11.6, 12.0

    Fix oversight in commit 4429f6a9e3e12bb4af6e3677fbc78cd80f160252.
    
    The test name and the following test cases suggest the index created
    should be hash index, but it forgot to add 'using hash' in the test case.
    This in itself won't improve code coverage as there were some other tests
    which were covering the corresponding code.  However, it is better if the
    added tests serve their actual purpose.
    
    Reported-by: Paul A Jungwirth
    Author: Paul A Jungwirth
    Reviewed-by: Mahendra Singh
    Backpatch-through: 9.4
    Discussion: https://postgr.es/m/CA+renyV=Us-5XfMC25bNp-uWSj39XgHHmGE9Rh2cQKMegSj52g@mail.gmail.com


src/test/regress/expected/rangetypes.out | 3 ++- src/test/regress/sql/rangetypes.sql | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/test/regress/expected/rangetypes.out b/src/test/regress/expected/rangetypes.out index 6756a2151b9..130604b37d0 100644 --- a/src/test/regress/expected/rangetypes.out +++ b/src/test/regress/expected/rangetypes.out @@ -519,7 +519,8 @@ select numrange(1.0, 2.0) * numrange(2.5, 3.0); (1 row) create table numrange_test2(nr numrange); -create index numrange_test2_hash_idx on numrange_test2 (nr); +create index numrange_test2_hash_idx on numrange_test2 using hash (nr); +WARNING: hash indexes are not WAL-logged and their use is discouraged INSERT INTO numrange_test2 VALUES('[, 5)'); INSERT INTO numrange_test2 VALUES(numrange(1.1, 2.2)); INSERT INTO numrange_test2 VALUES(numrange(1.1, 2.2)); diff --git a/src/test/regress/sql/rangetypes.sql b/src/test/regress/sql/rangetypes.sql index 62cb474a423..0793a8235a1 100644 --- a/src/test/regress/sql/rangetypes.sql +++ b/src/test/regress/sql/rangetypes.sql @@ -119,7 +119,7 @@ select numrange(1.0, 2.0) * numrange(1.5, 3.0); select numrange(1.0, 2.0) * numrange(2.5, 3.0); create table numrange_test2(nr numrange); -create index numrange_test2_hash_idx on numrange_test2 (nr); +create index numrange_test2_hash_idx on numrange_test2 using hash (nr); INSERT INTO numrange_test2 VALUES('[, 5)'); INSERT INTO numrange_test2 VALUES(numrange(1.1, 2.2)); [parent: 65cddf70aafc]