maybe a type_sanity. sql bug - Mailing list pgsql-hackers

From jian he
Subject maybe a type_sanity. sql bug
Date
Msg-id CACJufxHhr58q-YoBeqnY5P-u8Xe2X5sMtsr3LYE1nQDwdqjB4w@mail.gmail.com
Whole thread Raw
Responses Re: maybe a type_sanity. sql bug
List pgsql-hackers
hi.
The test seems to assume the following sql query should return zero row.
but it does not. I don't know much about the "relreplident" column.

https://git.postgresql.org/cgit/postgresql.git/tree/src/test/regress/expected/type_sanity.out#n499
demo: https://dbfiddle.uk/QFM88S2e

test1=# \dt
Did not find any relations.
test1=# SELECT c1.oid, c1.relname, relkind, relpersistence, relreplident
FROM pg_class as c1
WHERE relkind NOT IN ('r', 'i', 'S', 't', 'v', 'm', 'c', 'f', 'p') OR
    relpersistence NOT IN ('p', 'u', 't') OR
    relreplident NOT IN ('d', 'n', 'f', 'i');
 oid | relname | relkind | relpersistence | relreplident
-----+---------+---------+----------------+--------------
(0 rows)

test1=# CREATE TABLE test_partition (
        id int4range,
        valid_at daterange,
        name text,
        CONSTRAINT test_partition_uq1 UNIQUE (id, valid_at )
) PARTITION BY LIST (id);
CREATE TABLE
test1=# SELECT c1.oid, c1.relname, relkind, relpersistence, relreplident
FROM pg_class as c1
WHERE relkind NOT IN ('r', 'i', 'S', 't', 'v', 'm', 'c', 'f', 'p') OR
    relpersistence NOT IN ('p', 'u', 't') OR
    relreplident NOT IN ('d', 'n', 'f', 'i');
   oid   |      relname       | relkind | relpersistence | relreplident
---------+--------------------+---------+----------------+--------------
 1034304 | test_partition_uq1 | I       | p              | n
(1 row)

test1=# select version();
                              version
--------------------------------------------------------------------
 PostgreSQL 16beta1 on x86_64-linux, compiled by gcc-11.3.0, 64-bit
(1 row)



pgsql-hackers by date:

Previous
From: Bharath Rupireddy
Date:
Subject: Re: A recent message added to pg_upgade
Next
From: Amit Kapila
Date:
Subject: Re: A recent message added to pg_upgade