Index: openacs-4/packages/notifications/notifications.info
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/notifications/notifications.info,v
diff -u -N -r1.11.2.6 -r1.11.2.7
--- openacs-4/packages/notifications/notifications.info 29 Dec 2002 02:45:23 -0000 1.11.2.6
+++ openacs-4/packages/notifications/notifications.info 1 Feb 2003 00:14:04 -0000 1.11.2.7
@@ -7,7 +7,7 @@
f
t
-
+
oracle
postgresql
@@ -16,7 +16,7 @@
Notification Management
2002-08-19
-
+
@@ -33,6 +33,8 @@
+
+
@@ -46,6 +48,8 @@
+
+
Index: openacs-4/packages/notifications/sql/oracle/notifications-core-create.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/notifications/sql/oracle/notifications-core-create.sql,v
diff -u -N -r1.8.2.1 -r1.8.2.2
--- openacs-4/packages/notifications/sql/oracle/notifications-core-create.sql 6 Dec 2002 21:03:57 -0000 1.8.2.1
+++ openacs-4/packages/notifications/sql/oracle/notifications-core-create.sql 1 Feb 2003 00:14:25 -0000 1.8.2.2
@@ -151,6 +151,12 @@
notif_html clob
);
+-- RI indexes
+create index notifications_type_id_idx ON notifications(type_id);
+create index notifications_response_id_idx ON notifications(response_id);
+create index notifications_object_id_idx ON notifications(object_id);
+
+
-- who has received this notification?
create table notification_user_map (
notification_id constraint notif_user_map_notif_id_fk
@@ -164,6 +170,9 @@
sent_date date
);
+-- RI Indexes
+create index notification_user_map_user_idx ON notification_user_map(user_id);
+
--
-- Object Types
--
Index: openacs-4/packages/notifications/sql/oracle/notifications-replies-create.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/notifications/sql/oracle/notifications-replies-create.sql,v
diff -u -N -r1.2 -r1.2.2.1
--- openacs-4/packages/notifications/sql/oracle/notifications-replies-create.sql 9 Aug 2002 20:51:49 -0000 1.2
+++ openacs-4/packages/notifications/sql/oracle/notifications-replies-create.sql 1 Feb 2003 00:14:26 -0000 1.2.2.1
@@ -27,6 +27,10 @@
reply_date date
);
+-- RI indexes
+create index notif_repl_from_user_idx ON notification_replies(from_user);
+create index notif_repl_type_id_idx ON notification_replies(type_id);
+create index notif_repl_object_id_idx ON notification_replies(object_id);
declare
begin
Index: openacs-4/packages/notifications/sql/oracle/upgrade/upgrade-0.2d-0.3d.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/notifications/sql/oracle/upgrade/upgrade-0.2d-0.3d.sql,v
diff -u -N
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ openacs-4/packages/notifications/sql/oracle/upgrade/upgrade-0.2d-0.3d.sql 1 Feb 2003 00:14:38 -0000 1.1.2.1
@@ -0,0 +1 @@
+-- no data model change, rbm added a parameter.
\ No newline at end of file
Index: openacs-4/packages/notifications/sql/oracle/upgrade/upgrade-0.3d-0.4d.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/notifications/sql/oracle/upgrade/upgrade-0.3d-0.4d.sql,v
diff -u -N
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ openacs-4/packages/notifications/sql/oracle/upgrade/upgrade-0.3d-0.4d.sql 1 Feb 2003 00:14:38 -0000 1.1.2.1
@@ -0,0 +1,23 @@
+-- Indexes for foreign key constraints.
+
+-- the comment after is the referenced table.
+
+create index notifications_type_id_idx ON notifications(type_id); -- notification_types.type_id
+create index notifications_response_id_idx ON notifications(response_id); -- acs_objects.object_id
+create index notifications_object_id_idx ON notifications(object_id); -- acs_objects.object_id
+
+create index notif_requests_typ_delmeth_ix ON notification_requests(type_id, delivery_method_id); -- notification_types_del_methods.type_id delivery_method_id
+create index notif_requests_typ_intvl_idx ON notification_requests(type_id, interval_id); -- notification_types_intervals.type_id interval_id
+create index notif_requests_object_id_idx ON notification_requests(object_id); -- acs_objects.object_id
+create index notif_requests_user_id_idx ON notification_requests(user_id); -- users.user_id
+
+create index notification_user_map_user_idx ON notification_user_map(user_id); -- users.user_id
+
+-- We are not creating these even though they reference fks since the
+-- table and the parent tables are static. Might want to revist this though.
+
+-- create index notification_delivery_methods_sc_impl_id_idx ON notification_delivery_methods(sc_impl_id); acs_sc_impls.impl_id
+-- create index notification_types_sc_impl_id_idx ON notification_types(sc_impl_id); acs_sc_impls.impl_id
+-- create index notification_types_del_methods_delivery_method_id_idx ON notification_types_del_methods(delivery_method_id); notification_delivery_methods.delivery_method_id
+-- create index notification_types_intervals_interval_id_idx ON notification_types_intervals(interval_id); notification_intervals.interval_id
+
Index: openacs-4/packages/notifications/sql/postgresql/notifications-core-create.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/notifications/sql/postgresql/notifications-core-create.sql,v
diff -u -N -r1.7.2.1 -r1.7.2.2
--- openacs-4/packages/notifications/sql/postgresql/notifications-core-create.sql 6 Dec 2002 21:04:09 -0000 1.7.2.1
+++ openacs-4/packages/notifications/sql/postgresql/notifications-core-create.sql 1 Feb 2003 00:14:51 -0000 1.7.2.2
@@ -171,6 +171,11 @@
notif_html text
);
+-- RI indexes
+create index notifications_type_id_idx ON notifications(type_id);
+create index notifications_response_id_idx ON notifications(response_id);
+create index notifications_object_id_idx ON notifications(object_id);
+
-- who has received this notification?
create table notification_user_map (
notification_id integer
@@ -186,6 +191,10 @@
sent_date timestamp
);
+-- RI Indexes
+create index notification_user_map_user_idx ON notification_user_map(user_id);
+
+
--
-- Object Types
--
Index: openacs-4/packages/notifications/sql/postgresql/notifications-replies-create.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/notifications/sql/postgresql/notifications-replies-create.sql,v
diff -u -N -r1.2 -r1.2.2.1
--- openacs-4/packages/notifications/sql/postgresql/notifications-replies-create.sql 9 Aug 2002 20:51:50 -0000 1.2
+++ openacs-4/packages/notifications/sql/postgresql/notifications-replies-create.sql 1 Feb 2003 00:14:51 -0000 1.2.2.1
@@ -27,7 +27,12 @@
reply_date timestamp
);
+-- RI indexes
+create index notif_repl_from_user_idx ON notification_replies(from_user);
+create index notif_repl_type_id_idx ON notification_replies(type_id);
+create index notif_repl_object_id_idx ON notification_replies(object_id);
+
select acs_object_type__create_type (
'notification_reply',
'Notification Reply',
Index: openacs-4/packages/notifications/sql/postgresql/upgrade/upgrade-0.2d-0.3d.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/notifications/sql/postgresql/upgrade/upgrade-0.2d-0.3d.sql,v
diff -u -N
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ openacs-4/packages/notifications/sql/postgresql/upgrade/upgrade-0.2d-0.3d.sql 1 Feb 2003 00:15:03 -0000 1.1.2.1
@@ -0,0 +1 @@
+-- no data model change, rbm added a parameter.
\ No newline at end of file
Index: openacs-4/packages/notifications/sql/postgresql/upgrade/upgrade-0.3d-0.4d.sql
===================================================================
RCS file: /usr/local/cvsroot/openacs-4/packages/notifications/sql/postgresql/upgrade/upgrade-0.3d-0.4d.sql,v
diff -u -N
--- /dev/null 1 Jan 1970 00:00:00 -0000
+++ openacs-4/packages/notifications/sql/postgresql/upgrade/upgrade-0.3d-0.4d.sql 1 Feb 2003 00:15:03 -0000 1.1.2.1
@@ -0,0 +1,23 @@
+-- Indexes for foreign key constraints.
+
+-- the comment after is the referenced table.
+
+create index notifications_type_id_idx ON notifications(type_id); -- notification_types.type_id
+create index notifications_response_id_idx ON notifications(response_id); -- acs_objects.object_id
+create index notifications_object_id_idx ON notifications(object_id); -- acs_objects.object_id
+
+create index notif_requests_typ_delmeth_ix ON notification_requests(type_id, delivery_method_id); -- notification_types_del_methods.type_id delivery_method_id
+create index notif_requests_typ_intvl_idx ON notification_requests(type_id, interval_id); -- notification_types_intervals.type_id interval_id
+create index notif_requests_object_id_idx ON notification_requests(object_id); -- acs_objects.object_id
+create index notif_requests_user_id_idx ON notification_requests(user_id); -- users.user_id
+
+create index notification_user_map_user_idx ON notification_user_map(user_id); -- users.user_id
+
+-- We are not creating these even though they reference fks since the
+-- table and the parent tables are static. Might want to revist this though.
+
+-- create index notification_delivery_methods_sc_impl_id_idx ON notification_delivery_methods(sc_impl_id); acs_sc_impls.impl_id
+-- create index notification_types_sc_impl_id_idx ON notification_types(sc_impl_id); acs_sc_impls.impl_id
+-- create index notification_types_del_methods_delivery_method_id_idx ON notification_types_del_methods(delivery_method_id); notification_delivery_methods.delivery_method_id
+-- create index notification_types_intervals_interval_id_idx ON notification_types_intervals(interval_id); notification_intervals.interval_id
+