I found a couple of "gotchas" with installing Drupal using a PostgreSQL backend. Otherwise it's fairly straight forward.
The first problem you're likely to encounter is that your new database won't have the "plpgsql" language defined, so the creation script will fail. You simply need to "CREATE LANGUAGE 'plpgsql';
" or create the language through your admin tool before running the database.pgsql
script. You must create the language using a superuser account, which brings us to Likely Problem 2.
Most people will create a "normal" Drupal user account to access their Drupal database. This user can't CREATE LANGUAGE
like superusers can. So you might be tempted to run the creation script via a superuser account (like postgres
).
Don't. CREATE TABLE
commands assign ownership to the user that created them, and Drupal creates 54 tables. This means that your Drupal user will be denied access by default to the Drupal tables, since it's not the owner.
So instead, log in as a superuser. Create the database, the Drupal user, and the new language. Log out, and then back in as your Drupal user, and then run the creation script. You'll save yourself a lot of hastle, wondering why your Drupal user can't access tables in a database it owns.