Re: Variable substitution in psql backtick expansion

Pavel Stehule <pavel.stehule@gmail.com>

From: Pavel Stehule <pavel.stehule@gmail.com>
To: Fabien COELHO <coelho@cri.ensmp.fr>
Cc: Tom Lane <tgl@sss.pgh.pa.us>, Corey Huinker <corey.huinker@gmail.com>, Daniel Verite <daniel@manitou-mail.org>, PostgreSQL Developers <pgsql-hackers@postgresql.org>
Date: 2017-05-21T05:30:14Z
Lists: pgsql-hackers
Hi

2017-04-02 21:57 GMT+02:00 Fabien COELHO <coelho@cri.ensmp.fr>:

>
> More to the point, we already have that.  See c.h:
>>
>> #define CppAsString(identifier) #identifier
>> #define CppAsString2(x)                 CppAsString(x)
>>
>
> Thanks for the pointer. I grepped for them without success. Here is a v4.


I am sending a review of this patch.

This patch has trivial implementation - and there are not any objection to
used new variable names.

1. there was not any problem with patching, compiling
2. all regress tests passed
3. no problems with doc build

I'll mark this patch as ready for commiters

Regards

Pavel


>
> --
> Fabien

Commits

  1. Add psql variables showing server version and psql version.

  2. Reformat psql's --help=variables output.

  3. Remove reinvention of stringify macro.

  4. Allow psql variable substitution to occur in backtick command strings.