Re: docs: psql and variable interpolation

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Philippe Beaudoin <philippe(dot)beaudoin(at)dalibo(dot)com>
Cc: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>, "pgsql-docs(at)lists(dot)postgresql(dot)org" <pgsql-docs(at)lists(dot)postgresql(dot)org>
Subject: Re: docs: psql and variable interpolation
Date: 2020-07-15 15:49:44
Message-ID: 3077670.1594828184@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-docs

Philippe Beaudoin <philippe(dot)beaudoin(at)dalibo(dot)com> writes:
> Le 13/07/2020 à 17:45, David G. Johnston a écrit :
>> If it is only \copy that is an exception I’d rather just say (except
>> \copy} and not have the user meticulously read each item for the
>> single exception. This extends to if there are a few.

> As far as I know, the \! metacommand is another exception. But I don't
> know if there are some others.

Looking at the psql source code, the commands that use OT_WHOLE_LINE
argument parsing are

\copy
\ef, \ev
\sf, \sv
\help
\!

There's also OT_FILEPIPE argument parsing, which acts like WHOLE_LINE
if the argument starts with "|" (and otherwise is normal AFAICS).
That's used by

\g, \gx
\o
\w

regards, tom lane

In response to

Responses

Browse pgsql-docs by date

  From Date Subject
Next Message Michael Christofides 2020-07-15 22:15:09 Re: List of pages from versions 9, 10, and 11 that don't exist in "current"
Previous Message Philippe Beaudoin 2020-07-15 15:36:34 Re: docs: psql and variable interpolation