Index: openacs-4/packages/file-storage/sql/postgresql/upgrade/upgrade-4.2-4.6.sql =================================================================== RCS file: /usr/local/cvsroot/openacs-4/packages/file-storage/sql/postgresql/upgrade/upgrade-4.2-4.6.sql,v diff -u -r1.2 -r1.3 --- openacs-4/packages/file-storage/sql/postgresql/upgrade/upgrade-4.2-4.6.sql 30 Nov 2002 17:34:18 -0000 1.2 +++ openacs-4/packages/file-storage/sql/postgresql/upgrade/upgrade-4.2-4.6.sql 13 Jan 2005 13:58:11 -0000 1.3 @@ -667,6 +667,8 @@ -- JS: BEFORE DELETE TRIGGER to clean up CR entries (except root folder) + +drop function fs_package_items_delete_trig(); create or replace function fs_package_items_delete_trig () returns opaque as ' declare @@ -710,11 +712,12 @@ end;' language 'plpgsql'; -\i ../file-storage-simple-create.sql -\i ../file-storage-simple-package-create.sql +create trigger fs_package_items_delete_trig before delete +on fs_root_folders for each row +execute procedure fs_package_items_delete_trig (); -drop view fs_folders; -drop view fs_files; -drop view fs_folders_and_files; +drop view fs_folders cascade; +drop view fs_files cascade; +drop view fs_folders_and_files cascade; \i ../file-storage-views-create.sql