From: | Andres Freund <andres(at)2ndquadrant(dot)com> |
---|---|
To: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Robert Haas <robertmhaas(at)gmail(dot)com>, "pgsql-hackers(at)postgreSQL(dot)org" <pgsql-hackers(at)postgreSQL(dot)org> |
Subject: | Re: Shouldn't pg_(sh)seclabel.provider be marked NOT NULL? |
Date: | 2014-06-20 21:06:34 |
Message-ID: | 20140620210634.GF30721@alap3.anarazel.de |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 2014-06-20 16:50:15 -0400, Alvaro Herrera wrote:
> Tom Lane wrote:
>
> > The idea I'm toying with right now is to additionally mark as not nullable
> > any column referenced in a DECLARE_UNIQUE_INDEX command in
> > catalog/indexing.h. But I've not looked through that set carefully; it's
> > conceivable that we actually have some indexed catalog columns that are
> > allowed to be null. A possibly better solution is to invent a new macro
> > that has the same semantics as DECLARE_UNIQUE_INDEX, plus forcing the
> > columns to be marked NOT NULL.
>
> I think most, if not all, the unique indexes declared are part of a
> syscache. I don't think we allow those to be null, so in effect those
> columns are already not nullable.
> Non-unique indexes in indexing.h
> already bear a standard comment that they are not used for syscache.
> The only exception was added recently in f01d1ae3a104019:
> DECLARE_INDEX(pg_class_tblspc_relfilenode_index, 3455, on pg_class using btree(reltablespace oid_ops, relfilenode oid_ops));
There's no NULLs in here. It can have duplicates, but in that it's far
from alone.
Greetings,
Andres Freund
--
Andres Freund http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Alvaro Herrera | 2014-06-20 21:23:10 | Re: Shouldn't pg_(sh)seclabel.provider be marked NOT NULL? |
Previous Message | Alvaro Herrera | 2014-06-20 20:50:15 | Re: Shouldn't pg_(sh)seclabel.provider be marked NOT NULL? |