BUG #16770: PostgreSQL software V11 does not eliminate this recheck_on_update option?

Started by PG Bug reporting formover 5 years ago2 messagesbugs
Jump to latest
#1PG Bug reporting form
noreply@postgresql.org

The following bug has been logged on the website:

Bug reference: 16770
Logged by: yanliang lei
Email address: leiyanliang@highgo.com
PostgreSQL version: 11.10
Operating system: CentOS7.6
Description:

in pg11 create index statement have recheck_on_update option,but this option
do not exist in the documents
in the pg11.1 releasenote,recheck_on_update optimization is
disabled(https://www.postgresql.org/docs/11/release-11-1.html)
and in the pg11 create index
document(https://www.postgresql.org/docs/current/sql-createindex.html#SQL-CREATEINDEX-STORAGE-PARAMETERS),there
is nothing about recheck_on_update

but the create index sql with recheck_on_update='on' execute succuessfully,
why? PostgreSQL software V11 does not eliminate this recheck_on_update
option?

postgres=# CREATE INDEX idx1_t_tab_x ON t_tab_x(upper(c4)) WITH
(recheck_on_update = on) ;
CREATE INDEX
postgres=# \d+ t_tab_x
Table "public.t_tab_x"
Column | Type | Collation | Nullable | Default | Storage
| Stats target | Description
--------+-----------------------+-----------+----------+---------+----------+--------------+-------------
c1 | integer | | not null | | plain
| |
c2 | integer | | not null | | plain
| |
c3 | integer | | | | plain
| |
c4 | character varying(10) | | | | extended
| |
Indexes:
"t_tab_x_pkey" PRIMARY KEY, btree (c1, c2) INCLUDE (c3)
"idx1_t_tab_x" btree (upper(c4::text)) WITH (recheck_on_update='on')

postgres=# \d+ idx_t_tab_x
Did not find any relation named "idx_t_tab_x".
postgres=# \d+ idx1_t_tab_x
Index "public.idx1_t_tab_x"
Column | Type | Key? | Definition | Storage | Stats target
--------+------+------+-----------------+----------+--------------
upper | text | yes | upper(c4::text) | extended |
btree, for table "public.t_tab_x"
Options: recheck_on_update=on

postgres=#
postgres=# select version();
version

----------------------------------------------------------------------------------------------------------
PostgreSQL 11.10 on x86_64-pc-linux-gnu, compiled by gcc (GCC) 4.8.5
20150623 (Red Hat 4.8.5-39), 64-bit
(1 row)

postgres=#

In reply to: PG Bug reporting form (#1)
Re: BUG #16770: PostgreSQL software V11 does not eliminate this recheck_on_update option?

Hello

It's related to commits:
https://git.postgresql.org/pg/commitdiff/c203d6cf81b4d7e43edb2b75ec1b741ba48e04e0
https://git.postgresql.org/pg/commitdiff/5d28c9bd73e29890cccd3f6b188b86f81031f671
https://git.postgresql.org/pg/commitdiff/1c53c4dec3985512f7f2f53c9d76a5295cd0a2dd

Feature was reverted in master. Remains present in pg11, but nonfunctional and undocumented to avoid an ABI break for code touching relcache entries.

regards, Sergei