Index: openacs-4/packages/acs-kernel/sql/postgresql/acs-relationships-create.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/acs-kernel/sql/postgresql/acs-relationships-create.sql,v
diff -u -r1.18.2.4 -r1.18.2.5
--- openacs-4/packages/acs-kernel/sql/postgresql/acs-relationships-create.sql	12 Oct 2005 18:23:04 -0000	1.18.2.4
+++ openacs-4/packages/acs-kernel/sql/postgresql/acs-relationships-create.sql	14 Dec 2005 22:11:04 -0000	1.18.2.5
@@ -360,6 +360,32 @@
  acs_attributes.
 ';
 
+
+----------------------------
+-- Application Data Links --
+----------------------------
+
+create sequence acs_data_links_seq start with 1;
+
+create table acs_data_links (
+        rel_id          integer not null
+                        constraint acs_data_links_pk primary key,
+        object_id_one   integer not null
+                        constraint acs_data_links_one_fk
+                        references acs_objects (object_id)
+                        on delete cascade,
+        object_id_two   integer not null
+                        constraint acs_data_links_two_fk
+                        references acs_objects (object_id)
+                        on delete cascade,
+        constraint acs_data_links_un unique
+        (object_id_one, object_id_two)
+);
+
+create index acs_data_links_id_one_idx on acs_data_links (object_id_one);
+create index acs_data_links_id_two_idx on acs_data_links (object_id_two);
+
+
 --------------
 -- TRIGGERS --
 --------------
