Re: misleading error message in ProcessUtilitySlow T_CreateStatsStmt

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Álvaro Herrera <alvherre@kurilemu.de>
Cc: Kirill Reshke <reshkekirill@gmail.com>, jian he <jian.universality@gmail.com>, PostgreSQL-development <pgsql-hackers@postgresql.org>
Date: 2025-08-22T15:50:52Z
Lists: pgsql-hackers

Commits

Same data as JSON: GET /api/v1/messages/:b64id/commits the thread's linked commits as JSON, with link sources. API reference →
  1. CREATE STATISTICS: improve misleading error message

  2. Glossary: improve definition of "relation"

  3. Extended statistics on expressions

=?utf-8?Q?=C3=81lvaro?= Herrera <alvherre@kurilemu.de> writes:
> Yeah, AFAIR I wrote it (or at least heavily edited the original to get
> to that), and I was trying to convey exactly those two ideas.  If you
> want to propose improvements, they're very welcome.

Hmmm ... maybe something like

    Mathematically, a "relation" is a set of tuples; this is the sense
    meant in the term "relational database".

    In Postgres, "relation" is commonly used to mean a database object
    that has a name and a list of attributes defined in a specific
    order. Tables, sequences, views, foreign tables, materialized
    views, composite types, and indexes are all relations. A relation
    in this sense is a container or descriptor for a set of tuples.

    "Class" is an alternative but archaic term.  The system catalog
    pg_class holds an entry for each Postgres relation.

			regards, tom lane