From: Derrell.Lipman@UnwiredUniverse.com
To: Bruce Momjian <pgman@candle.pha.pa.us>
Cc: pgsql-docs@postgresql.org
Subject: Re: "man psql" \set documentation error
Date: Mon, 25 Feb 2002 22:34:18 -0500
Message-ID: <g03oykzp.fsf@random.localnet.UnwiredUniverse.com> (raw)
In-Reply-To: <200202181742.g1IHg1x02806@candle.pha.pa.us>
References: <200202181742.g1IHg1x02806@candle.pha.pa.us>
Bruce Momjian <pgman@candle.pha.pa.us> writes:
> Derrell.Lipman@UnwiredUniverse.com wrote:
>> Running an application and \set'ing its output in a variable requires use of
>> the backtick '`' operator. Under the heading "SQL INTERPOLATION", the
>> examples should be as follows (the difference being use of backticks instead
>> of single quotes around the command to be executed):
>>
>> Current (wrong):
>> testdb=> \set content '\'' 'cat my_file.txt' '\''
>>
>> Correct:
>> testdb=> \set content '\'' `cat my_file.txt` '\''
>>
>>
>>
>> Current (wrong):
>> testdb=> \set content 'sed -e "s/'/\\\\\\'/g" < my_file.txt'
>>
>> Correct:
>> testdb=> \set content `sed -e "s/'/\\\\\\'/g" < my_file.txt`
>>
>
> I just checked and it looks fine in current sources. Does it look right
> in your browser:
>
> http://candle.pha.pa.us/main/writings/pgsql/sgml/app-psql.html
Yes, it looks correct in that html version; it just has the wrong character in
the nroff "man" version.
Cheers,
Derrell
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 using the --to and --cc options:
reply via email
To: pgsql-docs@postgresql.org
Cc: Derrell.Lipman@UnwiredUniverse.com, pgman@candle.pha.pa.us
Subject: Re: "man psql" \set documentation error
In-Reply-To: <g03oykzp.fsf@random.localnet.UnwiredUniverse.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