Re: pg14 psql broke \d datname.nspname.relname

Justin Pryzby <pryzby@telsasoft.com>

From: Justin Pryzby <pryzby@telsasoft.com>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, Mark Dilger <mark.dilger@enterprisedb.com>, Andres Freund <andres@anarazel.de>, Julien Rouhaud <rjuju123@gmail.com>, pgsql-hackers@postgresql.org, Stephen Frost <sfrost@snowman.net>, Peter Geoghegan <pg@bowt.ie>
Date: 2022-04-08T03:04:44Z
Lists: pgsql-hackers
On Thu, Apr 07, 2022 at 10:26:18PM -0400, Robert Haas wrote:
> +               pg_log_error("improper relation name (too many dotted names): %s", pattern);
> 
> Come to think of it, maybe the error text there could stand some
> bikeshedding, but AFAICS

AFAICT the error text deliberately matches this, which I mentioned seems to me
the strongest argument for supporting \d datname.nspname.relname

ts=# SELECT 'a.a.a.a'::regclass;
ERROR:  42601: improper relation name (too many dotted names): a.a.a.a
LINE 1: SELECT 'a.a.a.a'::regclass;
               ^
LOCATION:  makeRangeVarFromNameList, namespace.c:3129



Commits

  1. Remove some recently-added pg_dump test cases.

  2. Allow db.schema.table patterns, but complain about random garbage.

  3. Improve error handling of HMAC computations

  4. Factor pattern-construction logic out of processSQLNamePattern.