Skip site navigation (1) Skip section navigation (2)

psql man page error?

From: "Simon Riggs" <simon(at)2ndquadrant(dot)com>
To: <pgsql-docs(at)postgresql(dot)org>
Subject: psql man page error?
Date: 2006-12-05 11:57:06
Message-ID: 1165319827.3839.146.camel@silverbirch.site (view raw or flat)
Thread:
Lists: pgsql-docs
On the psql man page there is an example of how to perform multiple line
psql script as part of the -c option description.

The example given is

	echo "\x \\ select * from foo;" | psql

which gives

	prompt> echo "\x \\ select * from foo;" | psql
	Expanded display is on.
	invalid command \

i.e. doesn't work on bash. With bash the command should be:

	echo -e "\x \n select * from foo;" | psql

which gives

	prompt> echo -e "\x \n select * from foo;" | psql
	Expanded display is on.
	ERROR:  relation "foo" does not exist

Does this mean there are multiple forms of the echo command, or is this
example just wrong?

-- 
  Simon Riggs             
  EnterpriseDB   http://www.enterprisedb.com



Responses

pgsql-docs by date

Next:From: Tom LaneDate: 2006-12-05 16:03:33
Subject: Re: FOR SHARE vs FOR UPDATE locks
Previous:From: IannspDate: 2006-12-05 02:05:36
Subject: Re: [DOCS] 8.2.0 pdf

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group