| From: | PG Doc comments form <noreply(at)postgresql(dot)org> |
|---|---|
| To: | pgsql-docs(at)lists(dot)postgresql(dot)org |
| Cc: | matematica(dot)a3k(at)gmail(dot)com |
| Subject: | Improve "3.6. Inheritance" tutorial |
| Date: | 2026-10-01 18:55:15 |
| Message-ID: | 179088091522.1026193.3570337969572056877@wrigleys.postgresql.org |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-docs |
The following documentation comment has been logged on the website:
Page: https://www.postgresql.org/docs/18/tutorial-inheritance.html
Description:
I propose the following modifications:
- "... cities. If you're really clever you might invent some scheme like
this:"
I think it's a joke which didn't age well, "Suppose you invent..." should be
better.
- "This works OK as far as querying goes, but it gets ugly when you need to
update several rows, for one thing.
A better solution is this:"
"In this sense, a better solution is:" should be better.
- "In this case, a row of capitals inherits all columns (name, population,
and elevation) from its parent, cities. The type of the column name is text,
a native PostgreSQL type for variable length character strings. The capitals
table has an additional column, state, which shows its state abbreviation.
In PostgreSQL, a table can inherit from zero or more other tables."
This may be refactored into:
"In this case, a row of capitals inherits all columns (name, population, and
elevation) from its parent, cities. The capitals table has an additional
column, state, which shows its state abbreviation.
In PostgreSQL, a table can inherit from zero or more other tables, and a
query can reference either all rows of a table or all rows of a table plus
all of its descendant tables. The latter behavior is the default."
- "which returns:"
"Given the sample data from the PostgreSQL tutorial (see Section 2.1), this
returns::" should be clearer
- "Note
Although inheritance is frequently useful, it has not been integrated with
unique constraints or foreign keys, which limits its usefulness. See Section
5.11 for more detail."
"Inheritance has not been integrated with unique constraints or foreign
keys, which limits its usefulness. See Section 5.11 for a complete
description of the feature." should be more precise
Regards,
Rodrigo
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Matemática A3K | 2026-10-01 19:14:16 | Re: [Minor] Conflicting sentence in "2.4. Populating a Table With Rows" |
| Previous Message | David G. Johnston | 2026-10-01 15:02:21 | Re: [Minor] Conflicting sentence in "2.4. Populating a Table With Rows" |