Re: nextval parameter is not clear

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Kirk Wolak <wolakk(at)gmail(dot)com>
Cc: Laurenz Albe <laurenz(dot)albe(at)cybertec(dot)at>, "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>, Bruce Momjian <bruce(at)momjian(dot)us>, ailjushkin(at)gmail(dot)com, pgsql-docs(at)lists(dot)postgresql(dot)org
Subject: Re: nextval parameter is not clear
Date: 2022-11-28 17:47:00
Message-ID: 635775.1669657620@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs

Kirk Wolak <wolakk(at)gmail(dot)com> writes:
> my goal is to get an "approach" accepted, this is the first. Ultimately, I
> would love to see
> the documentation of functions with examples like this everywhere.

I'm not for that. func.sgml is already massive, and doubling its size
with extensive examples doesn't seem like an improvement. Admittedly,
we probably don't need long examples for many of the functions, so maybe
we wouldn't end up with quite that much bloat; but it still seems like
the wrong approach. In my view, that chapter is more in the nature of
reference material, so extended examples ought to go somewhere else.

I could see adding a section about sequences and identity columns to
chapter 3 in the tutorial.

> Preferably where someone
> can copy/paste the example and see the results.

As far as that goes, there's already an idea that src/tutorial/
should contain SQL scripts that you can step-execute to follow
along with the tutorial docs. This hasn't been followed through
on very well --- chapter 2 is covered, but chapter 3 mostly not.
No time like the present to make it better, though. If your
ambition is to make self-contained working examples, making sure
that they execute as a script is good discipline.

regards, tom lane

In response to

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message Kirk Wolak 2022-11-28 19:22:02 Re: nextval parameter is not clear
Previous Message Kirk Wolak 2022-11-28 17:28:56 Re: nextval parameter is not clear