Re: nextval parameter is not clear - Mailing list pgsql-docs

From Tom Lane
Subject Re: nextval parameter is not clear
Date
Msg-id 635775.1669657620@sss.pgh.pa.us
Whole thread Raw
In response to Re: nextval parameter is not clear  (Kirk Wolak <wolakk@gmail.com>)
Responses Re: nextval parameter is not clear  (Kirk Wolak <wolakk@gmail.com>)
List pgsql-docs
Kirk Wolak <wolakk@gmail.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



pgsql-docs by date:

Previous
From: Kirk Wolak
Date:
Subject: Re: nextval parameter is not clear
Next
From: Kirk Wolak
Date:
Subject: Re: nextval parameter is not clear