Re: docs: psql and variable interpolation

2020-07-20 Thread Bruce Momjian
On Wed, Jul 15, 2020 at 11:49:44AM -0400, Tom Lane wrote: > Philippe Beaudoin 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

Re: docs: psql and variable interpolation

2020-07-15 Thread Tom Lane
Philippe Beaudoin 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

Re: docs: psql and variable interpolation

2020-07-15 Thread Philippe Beaudoin
Le 13/07/2020 à 17:45, David G. Johnston a écrit : On Monday, July 13, 2020, Philippe Beaudoin mailto:philippe.beaud...@dalibo.com>> wrote: The first sentence of this SQL interpolation chapter says "A key feature of psql variables is that you can substitute (“interpolate”) them in

Re: docs: psql and variable interpolation

2020-07-13 Thread David G. Johnston
On Monday, July 13, 2020, Philippe Beaudoin wrote: > > The first sentence of this SQL interpolation chapter says "A key feature > of psql variables is that you can substitute (“interpolate”) them into > regular SQL statements, as well as the arguments of meta-commands." But > nothing in this chapt

Re: docs: psql and variable interpolation

2020-07-13 Thread Pavel Stehule
po 13. 7. 2020 v 15:09 odesílatel Philippe Beaudoin < philippe.beaud...@dalibo.com> napsal: > Hi all, > > I recently used the nice variable capabilities in psql, after having read > the "SQL Interpolation" chapter in the psql page ( > https://www.postgresql.org/docs/12/app-psql.html). > > But I sp

docs: psql and variable interpolation

2020-07-13 Thread Philippe Beaudoin
Hi all, I recently used the nice variable capabilities in psql, after having read the "SQL Interpolation" chapter in the psql page (https://www.postgresql.org/docs/12/app-psql.html). But I spent a lot of time trying to understand why using a variable in a \copy command failed ... until a col