Re: wrong relkind error messages

From: Alvaro Herrera <alvherre(at)alvh(dot)no-ip(dot)org>
To: Peter Eisentraut <peter(dot)eisentraut(at)enterprisedb(dot)com>
Cc: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: wrong relkind error messages
Date: 2021-07-02 16:10:29
Message-ID: 202107021610.fv2n3ehw4yu7@alvherre.pgsql
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2021-Jun-24, Peter Eisentraut wrote:

> There might be room for some wordsmithing in a few places, but generally I
> think this is complete.

This looks good to me. I am +0.1 on your proposal of "cannot have
triggers" vs Michael's "cannot create triggers", but really I could go
with either. Michael's idea has the disadvantage that if the user fails
to see the trailing "s" in "triggers" they could get the idea that it's
possible to create some other trigger; that seems impossible to miss
with your wording. But it's not that bad either.

It seemed odd to me at first that errdetail_relkind_not_supported()
returns int, but I realized that it's a trick to let you write "return
errdetail()" so you don't have to have "break" which would require one
extra line. Looks fine.

--
Álvaro Herrera PostgreSQL Developer — https://www.EnterpriseDB.com/

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2021-07-02 16:29:45 Re: Signed vs. Unsigned (some)
Previous Message Tom Lane 2021-07-02 15:20:17 Re: Preventing abort() and exit() calls in libpq