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

Re: Windows XP PostgreSQL usage

From: John DeSoi <desoi(at)pgedit(dot)com>
To: Danny Gaethofs <dgaethofs(at)yahoo(dot)com>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: Windows XP PostgreSQL usage
Date: 2005-04-19 02:55:23
Message-ID: 798A4018-B07E-11D9-824B-000A95B03262@pgedit.com (view raw or flat)
Thread:
Lists: pgsql-novice
On Apr 18, 2005, at 8:53 AM, Danny Gaethofs wrote:

> I have a few questions:
> 1. during installation I cannot change the directory
> where the database should be created. Is there a way
> to have the postgresql database stored on another
> partition of my hard disk.

Are you sure you can't change the directory? Looks like there is an 
option for it here:

http://pginstaller.projects.postgresql.org/


>
> 2. do i still have to run initdb after installation
> using the msi installer

Only if you don't have the installer setup the data directory.

>
> 3. I want to create a database which of the tools can
> I use:
>
> I noticed pgadminiii provides functionality for
> creating a database.

Yes.

>
> I could also open a command window using runas
> /noprofile /user:postgres cmd and try to create a
> database there.
>

initdb sets up the "cluster" which can have many databases. Once the 
cluster is setup (with the installer or initdb), you can create a new 
database using the SQL command CREATE DATABASE. You can also use the 
createdb command line tool. You don't need to use runas for this. You 
just need to authenticate as a database user that has privileges to 
create databases.


> 4. Can I use a template ? I noticed there is a command
> psql to template1, but I read somewhere the template1
> is used as the basis for new ... databases or tables
> being created. What can I do with templates?
>


You can modify template1 so that any new database created starts as a 
copy of template1.


John DeSoi, Ph.D.
http://pgedit.com/
Power Tools for PostgreSQL


In response to

Responses

pgsql-novice by date

Next:From: John DeSoiDate: 2005-04-19 03:11:33
Subject: Re: text parsing function
Previous:From: brewDate: 2005-04-19 00:44:21
Subject: Re: Storing Large Objects

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