From 32dfe9106d6dfb07f6cf45b765d1b660dda606ac Mon Sep 17 00:00:00 2001 From: jensp Date: Tue, 29 Oct 2013 08:07:53 +0000 Subject: [PATCH] =?UTF-8?q?Kleinere=20=C3=9Cberarbeitungen=20der=20Upgrade?= =?UTF-8?q?-Scripts=20f=C3=BCr=20ccm-ldn-types-esdservice=206.6.0=20auf=20?= =?UTF-8?q?6.6.1,=20prim=C3=A4r=20Formatierungen?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit git-svn-id: https://svn.libreccm.org/ccm/trunk@2395 8810af33-2d31-482b-a856-94f89814c4df --- ..._table.sql => rename_esdservice_table.sql} | 2 +- .../default/6.6.0-6.6.1/upd_system_tables.sql | 90 ------------------- .../6.6.0-6.6.1/update_system_tables.sql | 89 ++++++++++++++++++ .../upgrade/oracle-se-6.6.0-6.6.1.sql | 4 +- .../upgrade/postgres-6.6.0-6.6.1.sql | 4 +- 5 files changed, 94 insertions(+), 95 deletions(-) rename ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/{ren_esdservice_table.sql => rename_esdservice_table.sql} (96%) delete mode 100644 ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/upd_system_tables.sql create mode 100644 ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/update_system_tables.sql diff --git a/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/ren_esdservice_table.sql b/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/rename_esdservice_table.sql similarity index 96% rename from ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/ren_esdservice_table.sql rename to ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/rename_esdservice_table.sql index b945f0c28..caebe95c0 100644 --- a/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/ren_esdservice_table.sql +++ b/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/rename_esdservice_table.sql @@ -26,7 +26,7 @@ -- alter table ct_esdservice drop constraint ... ; -- alter table ct_esdservice drop constraint ... ; -alter table ct_esdservice RENAME TO ct_ldn_esdservice ; +ALTER TABLE ct_esdservice RENAME TO ct_ldn_esdservice ; -- alter table ct_ldn_esdservice -- add constraint ct_ldn_esdserv_serv_id_p_5dac0 PRIMARY KEY(service_id); diff --git a/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/upd_system_tables.sql b/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/upd_system_tables.sql deleted file mode 100644 index 34c6eaecd..000000000 --- a/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/upd_system_tables.sql +++ /dev/null @@ -1,90 +0,0 @@ --- --- Copyright (C) 2012 Peter Boy All Rights Reserved. --- --- This library is free software; you can redistribute it and/or --- modify it under the terms of the GNU Lesser General Public License --- as published by the Free Software Foundation; either version 2.1 of --- the License, or (at your option) any later version. --- --- This library is distributed in the hope that it will be useful, --- but WITHOUT ANY WARRANTY; without even the implied warranty of --- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU --- Lesser General Public License for more details. --- --- You should have received a copy of the GNU Lesser General Public --- License along with this library; if not, write to the Free Software --- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA --- --- $Id: upd_system_tables.sql pboy $ - --- rename ccm-cms-types-contact to ccm-ldn-types-contact --- adjust various system tables to the new name of content type - -alter table init_requirements drop constraint init_requirements_init_f_cmmdn ; -alter table init_requirements drop constraint init_require_requ_init_f_i6rgg ; - -update inits - set class_name='com.arsdigita.london.contenttypes.ESDServiceInitializer' - where class_name='com.arsdigita.cms.contenttypes.ESDServiceInitializer' ; - -update init_requirements - set init='com.arsdigita.london.contenttypes.ESDServiceInitializer' - where init='com.arsdigita.cms.contenttypes.ESDServiceInitializer' ; - -ALTER TABLE init_requirements - ADD CONSTRAINT init_requirements_init_f_cmmdn FOREIGN KEY (init) - REFERENCES inits (class_name) MATCH SIMPLE - ON UPDATE NO ACTION ON DELETE NO ACTION; -ALTER TABLE init_requirements - ADD CONSTRAINT init_require_requ_init_f_i6rgg FOREIGN KEY (required_init) - REFERENCES inits (class_name) MATCH SIMPLE - ON UPDATE NO ACTION ON DELETE NO ACTION; - - -update content_types - set object_type='com.arsdigita.london.contenttypes.ESDService', - label='ESD Service', - description='An ESDService', - classname='com.arsdigita.london.contenttypes.ESDService' - where classname='com.arsdigita.cms.contenttypes.ESDService' ; - -update authoring_steps - set label_key='ESD Service Properties', - label_bundle='com.arsdigita.london.contenttypes.ESDServiceResources', - description_key='Edit the basic ESDService properties', - description_bundle='com.arsdigita.london.contenttypes.ESDServiceResources', - component='com.arsdigita.london.contenttypes.ui.ESDServicePropertiesStep' - where component='com.arsdigita.cms.contenttypes.ui.ESDServicePropertiesStep' ; - -update authoring_steps - set label_key='ESD Service Contact', - label_bundle='com.arsdigita.london.contenttypes.ESDServiceResources', - description_key='Edit/Choose the associated Contact object', - description_bundle='com.arsdigita.london.contenttypes.ESDServiceResources', - component='com.arsdigita.london.contenttypes.ui.ESDServiceChooseContactStep' - where component='com.arsdigita.cms.contenttypes.ui.ESDServiceChooseContactStep' ; - - - -update acs_objects - set (object_type,default_domain_class) = - ('com.arsdigita.london.contenttypes.ESDService' , - 'com.arsdigita.london.contenttypes.ESDService' ) - where default_domain_class like 'com.arsdigita.cms.contenttypes.ESDService' ; - -update lucene_docs - set type='com.arsdigita.london.contenttypes.ESDService' - where type='com.arsdigita.cms.contenttypes.ESDService' ; - -update vcx_generic_operations - set value=replace(value,'cms.contenttypes.ESDService', 'london.contenttypes.ESDService') - where value like '%cms.contenttypes.ESDService%'; - -update vcx_obj_changes - set obj_id=replace(obj_id,'cms.contenttypes.ESDService', 'london.contenttypes.ESDService') - where obj_id like '%cms.contenttypes.ESDService%'; - -update vcx_tags - set tagged_oid=replace(tagged_oid,'cms.contenttypes.ESDService', 'london.contenttypes.ESDService') - where tagged_oid like '%cms.contenttypes.ESDService%'; - diff --git a/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/update_system_tables.sql b/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/update_system_tables.sql new file mode 100644 index 000000000..b0c29f4c9 --- /dev/null +++ b/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/default/6.6.0-6.6.1/update_system_tables.sql @@ -0,0 +1,89 @@ +-- +-- Copyright (C) 2012 Peter Boy All Rights Reserved. +-- +-- This library is free software; you can redistribute it and/or +-- modify it under the terms of the GNU Lesser General Public License +-- as published by the Free Software Foundation; either version 2.1 of +-- the License, or (at your option) any later version. +-- +-- This library is distributed in the hope that it will be useful, +-- but WITHOUT ANY WARRANTY; without even the implied warranty of +-- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +-- Lesser General Public License for more details. +-- +-- You should have received a copy of the GNU Lesser General Public +-- License along with this library; if not, write to the Free Software +-- Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA +-- +-- $Id: upd_system_tables.sql pboy $ + +-- rename ccm-cms-types-contact to ccm-ldn-types-contact +-- adjust various system tables to the new name of content type + +ALTER TABLE init_requirements DROP CONSTRAINT init_requirements_init_f_cmmdn ; +ALTER TABLE init_requirements DROP CONSTRAINT init_require_requ_init_f_i6rgg ; + +UPDATE inits + SET class_name = 'com.arsdigita.london.contenttypes.ESDServiceInitializer' + WHERE class_name = 'com.arsdigita.cms.contenttypes.ESDServiceInitializer' ; + +UPDATE init_requirements + SET init = 'com.arsdigita.london.contenttypes.ESDServiceInitializer' + WHERE init = 'com.arsdigita.cms.contenttypes.ESDServiceInitializer' ; + +ALTER TABLE init_requirements + ADD CONSTRAINT init_requirements_init_f_cmmdn FOREIGN KEY (init) + REFERENCES inits (class_name) MATCH SIMPLE + ON UPDATE NO ACTION ON DELETE NO ACTION; +ALTER TABLE init_requirements + ADD CONSTRAINT init_require_requ_init_f_i6rgg FOREIGN KEY (required_init) + REFERENCES inits (class_name) MATCH SIMPLE + ON UPDATE NO ACTION ON DELETE NO ACTION; + + +UPDATE content_types + SET object_type = 'com.arsdigita.london.contenttypes.ESDService', + label = 'ESD Service', + description = 'An ESDService', + classname = 'com.arsdigita.london.contenttypes.ESDService' + WHERE classname = 'com.arsdigita.cms.contenttypes.ESDService' ; + +UPDATE authoring_steps + SET label_key = 'ESD Service Properties', + label_bundle = 'com.arsdigita.london.contenttypes.ESDServiceResources', + description_key = 'Edit the basic ESDService properties', + description_bundle = 'com.arsdigita.london.contenttypes.ESDServiceResources', + component = 'com.arsdigita.london.contenttypes.ui.ESDServicePropertiesStep' + WHERE component = 'com.arsdigita.cms.contenttypes.ui.ESDServicePropertiesStep' ; + +UPDATE authoring_steps + SET label_key = 'ESD Service Contact', + label_bundle = 'com.arsdigita.london.contenttypes.ESDServiceResources', + description_key = 'Edit/Choose the associated Contact object', + description_bundle = 'com.arsdigita.london.contenttypes.ESDServiceResources', + component = 'com.arsdigita.london.contenttypes.ui.ESDServiceChooseContactStep' + WHERE component = 'com.arsdigita.cms.contenttypes.ui.ESDServiceChooseContactStep' ; + + + +UPDATE acs_objects + SET (object_type,default_domain_class) = ('com.arsdigita.london.contenttypes.ESDService' , + 'com.arsdigita.london.contenttypes.ESDService' ) + WHERE default_domain_class = 'com.arsdigita.cms.contenttypes.ESDService' ; + +UPDATE lucene_docs + SET type = 'com.arsdigita.london.contenttypes.ESDService' + WHERE type = 'com.arsdigita.cms.contenttypes.ESDService' ; + +UPDATE vcx_generic_operations + SET value = replace(value, 'cms.contenttypes.ESDService', 'london.contenttypes.ESDService') + WHERE value LIKE '%cms.contenttypes.ESDService%'; + +UPDATE vcx_obj_changes + SET obj_id = REPLACE(obj_id,'cms.contenttypes.ESDService', 'london.contenttypes.ESDService') + WHERE obj_id LIKE '%cms.contenttypes.ESDService%'; + +UPDATE vcx_tags + SET tagged_oid = REPLACE(tagged_oid,'cms.contenttypes.ESDService', 'london.contenttypes.ESDService') + WHERE tagged_oid LIKE '%cms.contenttypes.ESDService%'; + diff --git a/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/oracle-se-6.6.0-6.6.1.sql b/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/oracle-se-6.6.0-6.6.1.sql index 26aa9a822..4e3c1a526 100644 --- a/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/oracle-se-6.6.0-6.6.1.sql +++ b/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/oracle-se-6.6.0-6.6.1.sql @@ -17,5 +17,5 @@ -- -- $Id: oracle-se-6.6.0-6.6.1.sql pboy $ -@@ default/6.6.0-6.6.1/ren_esdservice_table.sql -@@ default/6.6.0-6.6.1/upd_system_tables.sql +@@ default/6.6.0-6.6.1/rename_esdservice_table.sql +@@ default/6.6.0-6.6.1/update_system_tables.sql diff --git a/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/postgres-6.6.0-6.6.1.sql b/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/postgres-6.6.0-6.6.1.sql index 1a31cd34a..8a2266140 100644 --- a/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/postgres-6.6.0-6.6.1.sql +++ b/ccm-ldn-types-esdservice/sql/ccm-ldn-types-esdservice/upgrade/postgres-6.6.0-6.6.1.sql @@ -21,7 +21,7 @@ begin; -\i default/6.6.0-6.6.1/ren_esdservice_table.sql -\i default/6.6.0-6.6.1/upd_system_tables.sql +\i default/6.6.0-6.6.1/rename_esdservice_table.sql +\i default/6.6.0-6.6.1/update_system_tables.sql commit;