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

Re: BUG #4002: Error when I attemp to make a query by prompt

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Bill Moran <wmoran(at)collaborativefusion(dot)com>
Cc: "Mario Plazas" <marioplazas(at)gmail(dot)com>, pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #4002: Error when I attemp to make a query by prompt
Date: 2008-02-29 18:51:33
Message-ID: 10360.1204311093@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-bugs
Bill Moran <wmoran(at)collaborativefusion(dot)com> writes:
> In response to "Mario Plazas" <marioplazas(at)gmail(dot)com>:
>> C:\Archivos de programa\PostgreSQL\8.3\bin>"C:\Archivos de
>> programa\PostgreSQL\8
>> .3\bin\psql.exe" DBASE superpostgres -C "SELECT * FROM companies;"
>> psql: warning: extra command-line argument "-C" ignored
>> psql: warning: extra command-line argument "SELECT * FROM companies;"
>> ignored

> I believe the problem is that you want -c, not -C (case is important).

The other problem is that -c and its argument need to come *before* the
non-switch arguments (database and user name).

>> It works fine on ver. 8.2.4-1 I think that this is a bug for the ver.
>> 8.3.0-1 .

It is not a bug.  Some versions of getopt() happen to be laxer about
argument order than others, but we don't promise that the non-documented
order will work.

			regards, tom lane

In response to

pgsql-bugs by date

Next:From: Peter EisentrautDate: 2008-02-29 19:30:10
Subject: Re: bug or not bug, xmlvalidate(xml, text) can read and show one line from file
Previous:From: Bill MoranDate: 2008-02-29 18:09:05
Subject: Re: BUG #4002: Error when I attemp to make a query by prompt

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