pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@postgresql.org
Subject: pgsql: Fix ALTER OPERATOR to update dependencies properly.
Date: Thu, 31 Dec 2015 22:37:37 +0000
Message-ID: <E1aElqj-0004r2-Cc@gemulon.postgresql.org> (raw)
List-Unsubscribe:  <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>

Fix ALTER OPERATOR to update dependencies properly.

Fix an oversight in commit 321eed5f0f7563a0: replacing an operator's
selectivity functions needs to result in a corresponding update in
pg_depend.  We have a function that can handle that, but it was not
called by AlterOperator().

To fix this without enlarging pg_operator.h's #include list beyond
what clients can safely include, split off the function definitions
into a new file pg_operator_fn.h, similarly to what we've done for
some other catalog header files.  It's not entirely clear whether
any client-side code needs to include pg_operator.h, but it seems
prudent to assume that there is some such code somewhere.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/0dab5ef39b3d9d86e45bbbb2f6ea60b4f5517d9a

Modified Files
--------------
src/backend/catalog/pg_operator.c            |   35 +++++++-----
src/backend/commands/operatorcmds.c          |    5 +-
src/include/catalog/pg_operator.h            |   17 ------
src/include/catalog/pg_operator_fn.h         |   34 ++++++++++++
src/test/regress/expected/alter_operator.out |   73 +++++++++++++++++++++++---
src/test/regress/sql/alter_operator.sql      |   41 +++++++++++++--
6 files changed, 163 insertions(+), 42 deletions(-)


-- 
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers


Message-ID: <E1aElqj-0004r2-Cc@gemulon.postgresql.org>
Permalink:  ../E1aElqj-0004r2-Cc@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1aElqj-0004r2-Cc@gemulon.postgresql.org

 · 

reply

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 from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: tgl@sss.pgh.pa.us
  Subject: Re: pgsql: Fix ALTER OPERATOR to update dependencies properly.
  In-Reply-To: <E1aElqj-0004r2-Cc@gemulon.postgresql.org>
  References: <E1aElqj-0004r2-Cc@gemulon.postgresql.org>

* 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