pg.ddx.io  pgsql-docs@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Xavier Fischer <xavier_fischer@hotmail.fr>
To: David G. Johnston <david.g.johnston@gmail.com>
To: Matemática A3K <matematica.a3k@gmail.com>
Cc: Daniel Gustafsson <daniel@yesql.se>
Cc: pgsql-docs@lists.postgresql.org <pgsql-docs@lists.postgresql.org>
Subject: RE: Introductory docs-hacking task: Example markup
Date: Thu, 12 Nov 2026 07:33:12 +0000
Message-ID: <AMBP193MB27424C3347F03DBD3CC4498094702@AMBP193MB2742.EURP193.PROD.OUTLOOK.COM> (raw)
In-Reply-To: <CAKFQuwbQw5t4q1Oo9cxn+amS0hssrObEzWNSfmBd0EbaCERbUQ@mail.gmail.com>
References: <0E2E08E5-B06F-4F40-ADAA-BD4DB2275F44@yesql.se>
	<CA+FDnhJ2iYxFi_5OyPWArQeNkm-kBjUap=iW+e6ufFVnxkofyw@mail.gmail.com>
	<CAKFQuwbQw5t4q1Oo9cxn+amS0hssrObEzWNSfmBd0EbaCERbUQ@mail.gmail.com>

On Wed, Nov 11, 2026 at 7:42 PM Matemática A3K <matematica.a3k@gmail.com<mailto:matematica.a3k@gmail.com>> wrote:
On Wed, Nov 11, 2026 at 9:29 AM Daniel Gustafsson <daniel@yesql.se<mailto:daniel@yesql.se>> wrote:
>
> I will argue that no markup should be used for examples. The goal of
> an example is to help readers understand a general functioning by
> seeing a particular one. As such, they should be part of the prose
> that explains the functioning, not an independent element to be
> indexed. The only value I currently see in having a delimited or
> encapsulated example is the ability to skip it if you already got it
> from the explanation prose.

I disagree with this: sometimes you want to search for examples of a construct, and having it indexed can avoid scrolling and makes clear that there's a dedicated section. I tend to do that when programming and it's useful to have a dedicated section to jump in directly.
There are some short examples in the middle of the main prose, not worth a section on their own. 

Here are some examples : 
Missing index: https://www.postgresql.org/docs/19/sql-altertable.html
Index not needed: examples are within the prose: https://www.postgresql.org/docs/19/functions-matching.html#FUNCTIONS-POSIX-REGEXP
Example without index for any section at all: https://www.postgresql.org/docs/current/sql-merge.html

I'll look for more examples


De : David G. Johnston <david.g.johnston@gmail.com>
Envoyé : jeudi 12 novembre 2026 03:56

>This seems unlikely to be accepted and is definitely not 'newcomer friendly'.  I'd suggest you, or 
> anyone who does think this is needed, provide at least three or four patch-quality examples of what 
> you are thinking on another thread first.

Noted. Still it's a good way to learn the docs in my opinion. I agree that this should be splitted as separate work (current examples markup, missing index examples, sections where examples lack).



view thread (12+ messages)  latest in thread

Message-ID: <AMBP193MB27424C3347F03DBD3CC4498094702@AMBP193MB2742.EURP193.PROD.OUTLOOK.COM>
Permalink:  ../AMBP193MB27424C3347F03DBD3CC4498094702@AMBP193MB2742.EURP193.PROD.OUTLOOK.COM/
Also on:    postgresql.org/message-id/AMBP193MB27424C3347F03DBD3CC4498094702@AMBP193MB2742.EURP193.PROD.OUTLOOK.COM

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-docs@postgresql.org
  Cc: xavier_fischer@hotmail.fr, david.g.johnston@gmail.com, matematica.a3k@gmail.com, daniel@yesql.se
  Subject: Re: Introductory docs-hacking task: Example markup
  In-Reply-To: <AMBP193MB27424C3347F03DBD3CC4498094702@AMBP193MB2742.EURP193.PROD.OUTLOOK.COM>
  References: <0E2E08E5-B06F-4F40-ADAA-BD4DB2275F44@yesql.se> <CA+FDnhJ2iYxFi_5OyPWArQeNkm-kBjUap=iW+e6ufFVnxkofyw@mail.gmail.com> <CAKFQuwbQw5t4q1Oo9cxn+amS0hssrObEzWNSfmBd0EbaCERbUQ@mail.gmail.com> <AMBP193MB27424C3347F03DBD3CC4498094702@AMBP193MB2742.EURP193.PROD.OUTLOOK.COM>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox