public inbox for [email protected]  
help / color / mirror / Atom feed
From: Bruce Momjian <[email protected]>
To: Tom Lane <[email protected]>
Cc: Simon Riggs <[email protected]>
Cc: [email protected]
Subject: Re: psql man page error?
Date: Tue, 5 Dec 2006 18:16:52 -0500 (EST)
Message-ID: <[email protected]> (raw)
In-Reply-To: <[email protected]>

Tom Lane wrote:
> Bruce Momjian <[email protected]> writes:
> > I think the proper fix is:
> 
> >       <application>psql</application>, like this: <literal>echo -e
> >       "\\x\nSELECT * FROM foo;" | psql</literal>.
> 
> > I think all modern operating systems understand echo -e at this point.
> 
> No, they don't, and neither does the Single Unix Spec:
> http://www.opengroup.org/onlinepubs/007908799/xcu/echo.html
> 
> So your version of the example depends on non-standards-compliant
> echo behavior, which is not better than before.

Well, at least my example works on _some_ operating systems, while the
previous worked on none of them, so it is _better_.

I can't think of a good way to do this except converting the example to
a <programlisting> block that will not change newlines:

	echo '\x
	SELECT * FROM foo;' | psql

Is that what people want?

-- 
  Bruce Momjian   [email protected]
  EnterpriseDB    http://www.enterprisedb.com

  + If your life is a hard drive, Christ can be your backup. +



view thread (17+ messages)  latest in thread

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 using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected]
  Subject: Re: psql man page error?
  In-Reply-To: <[email protected]>

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

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