Re: Error messages on duplicate schema names

Michael Paquier <michael@paquier.xyz>

From: Michael Paquier <michael@paquier.xyz>
To: Andrus <kobruleht2@hot.ee>
Cc: pgsql-general@postgresql.org
Date: 2021-01-15T04:28:24Z
Lists: pgsql-general

Attachments

On Wed, Jan 06, 2021 at 07:15:24PM +0200, Andrus wrote:
> Should duplicate schema names accepted or should their usage throw better
> error messages.

This means that we are one call of CommandCounterIncrement() short for
such queries, and similar safeguards already exist in this area for
GRANT/REVOKE.  The spot where I would put this new CCI is at the end
of SetDefaultACL(), like in the attached with a test added to
privileges.sql.

Any thoughts from others?
--
Michael

Commits

  1. Fix ALTER DEFAULT PRIVILEGES with duplicated objects