From: Ildar Musin <i.musin@postgrespro.ru>
To: Sergei Kornilov <sk@zsrv.org>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Alvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Stephen Frost <sfrost@snowman.net>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: pgsql-hackers@postgresql.org <pgsql-hackers@postgresql.org>
Subject: Re: using index or check in ALTER TABLE SET NOT NULL
Date: Thu, 15 Mar 2018 17:31:50 +0300
Message-ID: <dbfac595-11a0-606f-b67d-ea4a0d542aae@postgrespro.ru> (raw)
In-Reply-To: <5376321520674521@web1j.yandex.ru>
References: <880511520351578@web5j.yandex.ru>
<20180306172528.xnelm3xcq2qeyd2g@alvherre.pgsql>
<1715451520361128@web26o.yandex.ru>
<1142.1520362313@sss.pgh.pa.us>
<082cf493-a989-dcd6-7baf-a94a40d07ea0@postgrespro.ru>
<2947361520607085@web26g.yandex.ru>
<5376321520674521@web1j.yandex.ru>
Hello Sergei,
On 10.03.2018 12:35, Sergei Kornilov wrote:
> Hello My patch does not apply after commit
> 5748f3a0aa7cf78ac6979010273bd9d50869bb8e. Here is update to current
> master. Not null constraint is immutable too, so here is no changes
> in PartConstraintImpliedByRelConstraint excepts rename and comments
> fix.
>
> In this patch version i also revert tests to v4 state: i use DEBUG
> ereport instead INFO and code path not tested. Please tell me if i
> must change tests some way.
>
> regards, Sergei
>
Ok, I can't think of any other ways to test it so I have to agree with
Tom Lane i.e. rely only on coverage. (There also were another suggestion
to use statistics [select seq_scan from pg_stat_user_tables where
relid='test'::regclass] which show number of table scans. But statistics
is collected by stat collector process with some latency and hence
cannot be reliable for tests).
Patch seems correct to me, it applies and compiles cleanly, docs
compiles as well, tests pass. Changed status to Ready for Committer.
--
Ildar Musin
i.musin@postgrespro.ru
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: i.musin@postgrespro.ru, sk@zsrv.org, tgl@sss.pgh.pa.us, alvherre@alvh.no-ip.org, sfrost@snowman.net, robertmhaas@gmail.com
Subject: Re: using index or check in ALTER TABLE SET NOT NULL
In-Reply-To: <dbfac595-11a0-606f-b67d-ea4a0d542aae@postgrespro.ru>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox