$Id: db_hints.txt,v 1.1 2002/08/12 01:40:16 als Exp $

Some hints for setting up the database:

First, su to the postgresql user on your system, this is usually
"postgres" on Linux or "pgsql" on FreeBSD, do all commands below as this 
user on the machine hosting the running PostgreSQL instance.

To create a database from the shell use:

 createdb $DBNAME

where $DBNAME is the name of the database you wish to create


To enable the use of the procedural languages "plperl" and/or "plpgsql"
on a database (for stored procedures) from the shell, use:

createlang --pglib=$POSTGRESLIB plperl $DBNAME
createlang --pglib=$POSTGRESLIB plpgsql $DBNAME

where $DBNAME is the name of the database you wish to enable the use of 
these languages on an $POSTGRESLIB is the library directory of your PostgreSQL
installation (highly depending on how PostgreSQL is installed on your
system, look somewhere under /usr/local/pgsql/lib on FreeBSD, under
/usr/postgres/lib or even /opt/postgres/lib).

To create a database user from the shell, use:

createuser --no-createdb --no-adduser --pwprompt $USERNAME

where $USERNAME is the username you wish to create. The command will prompt
you for the password for this user.

