Search Postgresql Archives

Re: -c argument not recognized

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 2009-11-10, Antonio Ruggiero <aruggiero02@xxxxxxxxx> wrote:
> I am running PostgresSQL 8.3.8 on windows XP-64Bit.  I am using psql
> client from the PostgreSQL installation and not the Cygwin client.
>
> My issue is that the command line argument "-c command" is not
> recognized. For example, if I run (from Cygwin)
>
> psql -h localhost -p 5432 -d $database postgres -c "select count(*)
> from  $table_name"

On windows you must put the command line arguments in the correct order
(see the documentation for details of correct order)

On linux (and I assume other POSIX) the order is not critical.

windows command-line sucks anyway, so using pipes or temporary files
for the commands is probably a better solution, especially if the
commands are determined at runtime.





-- 
Sent via pgsql-general mailing list (pgsql-general@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux