The table outline_nodes does not get created when Outline is installed for Postgresql. There's a missing right parenthesis on the line for Primary key. To close the open parenthesis in the CREATE TABLES statement the code should read:

PRIMARY KEY (nid))

rather than

PRIMARY KEY (nid)

Thanks.

Comments

gwolf’s picture

Title: Error in Postgres code of outline.install for creating table outline_nodes » Couple of errors in the PostgreSQL table creation script
Version: 5.x-1.x-dev » 5.x-1.0
Status: Active » Reviewed & tested by the community

Besides the already mentioned missing parenthesis, there are two other problems with the PostgreSQL install script:
- The sequence 'volume_id_seq' is not created, and Drupal expects it to be there (and with that name - normally, I'd just change outline_volume.volume_id from int_unsigned to serial, but Drupal explicitly wants to use volume_id_seq)
- The 'weight' column is not created

The patch is really trivial:

--- drupal5-outline-1.0.orig/outline.install
+++ drupal5-outline-1.0/outline.install
@@ -39,13 +39,15 @@
child_type varchar(32) NOT NULL default '',
toc_depth smallint NOT NULL default '1',
PRIMARY KEY (nid)
- ");
+ )");
db_query("CREATE INDEX {outline_nodes}_volume_id_idx ON {outline_nodes} (volume_id)");
db_query("CREATE INDEX {outline_nodes}_parent_idx ON {outline_nodes} (parent)");
db_query("CREATE INDEX {outline_nodes}_child_type_idx ON {outline_nodes} (substr (child_type, 1, 4))");
+ db_query("CREATE SEQUENCE volume_id_seq");
db_query("CREATE TABLE {outline_volume} (
volume_id int_unsigned NOT NULL default '0',
title varchar(128) NOT NULL default '',
+ weight smallint NOT NULL default '0',
default_toc_depth smallint NOT NULL default '1',
default_child_type varchar(32) NOT NULL default '',
PRIMARY KEY (volume_id),

beginner’s picture

Status: Reviewed & tested by the community » Active

no patch attached.

captaindav’s picture

Issue summary: View changes
Status: Active » Closed (won't fix)