Thread: Getting the command line to work

Getting the command line to work

From
"Paul Jordan"
Date:
Hi. Perhaps this isn't the proper place to send this, but it's the only
address I have. I've installed postgres and I'm trying to use the
command prompt to create a database (PGAdmin III having failed miserably
at the task). The documentation I'm working with, created by people I
trust know what they're doing, says that I should enter the following:
=20
"createdb qf_local -U postgres -W -h localhost"
=20
But when I do that, it tells me that there are too many command line
arguments and it fails.
=20
What am I doing wrong? I've never worked with DOS before, so my error
might even be blindingly obvious, but I have no idea what it is. Any
help you could give me in getting postgres to do what it's supposed to
do would be marvelous.
=20
Many thanks,
=20
Paul Jordan
Digital Archivist
Occidental College

Re: Getting the command line to work

From
"Dave Page"
Date:
On Wed, May 21, 2008 at 6:43 PM, Paul Jordan <pjordan@oxy.edu> wrote:
> Hi. Perhaps this isn't the proper place to send this, but it's the only
> address I have. I've installed postgres and I'm trying to use the command
> prompt to create a database (PGAdmin III having failed miserably at the
> task).

Please define "failed miserably". pgAdmin should only ever fail if you
have a problem such as lack of privileges or disk space or similar,
and then should give you an appropriate error message.

> The documentation I'm working with, created by people I trust know
> what they're doing, says that I should enter the following:
>
> "createdb qf_local -U postgres -W -h localhost"

Unfortunately it seems they don't know what they're doing. Try:

createdb -U postgres -W -h localhost qf_local

Per the docs at http://www.postgresql.org/docs/8.3/interactive/app-createdb.html


--
Dave Page
EnterpriseDB UK: http://www.enterprisedb.com