mirror of
https://github.com/Alfresco/alfresco-community-repo.git
synced 2025-08-14 17:58:59 +00:00
87804: ACE-2030: Retire jbpm-upgrade.sql including patches using it The from-to schema values match those of the 'patch.db-V3.2-Upgrade-JBPM' bean and they both referenced the same SQL file. Therefore, it was simply a duplicate with the V3.2 bean being the one doing the actual work. This bean is therefore joining the V3.2 version in retirement. The 'targetSchema' is for information purposes only and has been changed from 6001 to 2018, which is what it actually did. 87805: ACE-2030: Remove more patches introduced for upgrade to V3.2 87806: ACE-2030: Remove more patches introduced for upgrade to V3.3.x 87807: Move patch.migrateAttrDropOldTables out of the danger zone (ACE-2030) before continuing clean up. git-svn-id: https://svn.alfresco.com/repos/alfresco-enterprise/alfresco/HEAD/root@87812 c4b6b30b-aa2e-2d43-bbcb-ca4b014f7261
111 lines
3.7 KiB
SQL
111 lines
3.7 KiB
SQL
--
|
|
-- Title: Property Value tables
|
|
-- Database: MySQL InnoDB
|
|
-- Since: V3.2 Schema 3001
|
|
-- Author: Derek Hulley
|
|
--
|
|
-- Please contact support@alfresco.com if you need assistance with the upgrade.
|
|
--
|
|
|
|
CREATE TABLE alf_prop_class
|
|
(
|
|
id BIGINT NOT NULL AUTO_INCREMENT,
|
|
java_class_name VARCHAR(255) NOT NULL,
|
|
java_class_name_short VARCHAR(32) NOT NULL,
|
|
java_class_name_crc BIGINT NOT NULL,
|
|
UNIQUE INDEX idx_alf_propc_crc (java_class_name_crc, java_class_name_short),
|
|
INDEX idx_alf_propc_clas (java_class_name),
|
|
PRIMARY KEY (id)
|
|
) ENGINE=InnoDB;
|
|
|
|
CREATE TABLE alf_prop_date_value
|
|
(
|
|
date_value BIGINT NOT NULL,
|
|
full_year SMALLINT NOT NULL,
|
|
half_of_year TINYINT NOT NULL,
|
|
quarter_of_year TINYINT NOT NULL,
|
|
month_of_year TINYINT NOT NULL,
|
|
week_of_year TINYINT NOT NULL,
|
|
week_of_month TINYINT NOT NULL,
|
|
day_of_year SMALLINT NOT NULL,
|
|
day_of_month TINYINT NOT NULL,
|
|
day_of_week TINYINT NOT NULL,
|
|
INDEX idx_alf_propdt_dt (full_year, month_of_year, day_of_month),
|
|
PRIMARY KEY (date_value)
|
|
) ENGINE=InnoDB;
|
|
|
|
CREATE TABLE alf_prop_double_value
|
|
(
|
|
id BIGINT NOT NULL AUTO_INCREMENT,
|
|
double_value DOUBLE NOT NULL,
|
|
UNIQUE INDEX idx_alf_propd_val (double_value),
|
|
PRIMARY KEY (id)
|
|
) ENGINE=InnoDB;
|
|
|
|
-- Stores unique, case-sensitive string values --
|
|
CREATE TABLE alf_prop_string_value
|
|
(
|
|
id BIGINT NOT NULL AUTO_INCREMENT,
|
|
string_value TEXT NOT NULL,
|
|
string_end_lower VARCHAR(16) NOT NULL,
|
|
string_crc BIGINT NOT NULL,
|
|
INDEX idx_alf_props_str (string_value(32)),
|
|
UNIQUE INDEX idx_alf_props_crc (string_end_lower, string_crc),
|
|
PRIMARY KEY (id)
|
|
) ENGINE=InnoDB;
|
|
|
|
CREATE TABLE alf_prop_serializable_value
|
|
(
|
|
id BIGINT NOT NULL AUTO_INCREMENT,
|
|
serializable_value BLOB NOT NULL,
|
|
PRIMARY KEY (id)
|
|
) ENGINE=InnoDB;
|
|
|
|
CREATE TABLE alf_prop_value
|
|
(
|
|
id BIGINT NOT NULL AUTO_INCREMENT,
|
|
actual_type_id BIGINT NOT NULL,
|
|
persisted_type TINYINT NOT NULL,
|
|
long_value BIGINT NOT NULL,
|
|
INDEX idx_alf_propv_per (persisted_type, long_value),
|
|
UNIQUE INDEX idx_alf_propv_act (actual_type_id, long_value),
|
|
PRIMARY KEY (id)
|
|
) ENGINE=InnoDB;
|
|
|
|
CREATE TABLE alf_prop_root
|
|
(
|
|
id BIGINT NOT NULL AUTO_INCREMENT,
|
|
version SMALLINT NOT NULL,
|
|
PRIMARY KEY (id)
|
|
) ENGINE=InnoDB;
|
|
|
|
CREATE TABLE alf_prop_link
|
|
(
|
|
root_prop_id BIGINT NOT NULL,
|
|
prop_index BIGINT NOT NULL,
|
|
contained_in BIGINT NOT NULL,
|
|
key_prop_id BIGINT NOT NULL,
|
|
value_prop_id BIGINT NOT NULL,
|
|
CONSTRAINT fk_alf_propln_root FOREIGN KEY (root_prop_id) REFERENCES alf_prop_root (id) ON DELETE CASCADE,
|
|
CONSTRAINT fk_alf_propln_key FOREIGN KEY (key_prop_id) REFERENCES alf_prop_value (id) ON DELETE CASCADE,
|
|
CONSTRAINT fk_alf_propln_val FOREIGN KEY (value_prop_id) REFERENCES alf_prop_value (id) ON DELETE CASCADE,
|
|
INDEX idx_alf_propln_for (root_prop_id, key_prop_id, value_prop_id),
|
|
PRIMARY KEY (root_prop_id, contained_in, prop_index)
|
|
) ENGINE=InnoDB;
|
|
|
|
CREATE TABLE alf_prop_unique_ctx
|
|
(
|
|
id BIGINT NOT NULL AUTO_INCREMENT,
|
|
version SMALLINT NOT NULL,
|
|
value1_prop_id BIGINT NOT NULL,
|
|
value2_prop_id BIGINT NOT NULL,
|
|
value3_prop_id BIGINT NOT NULL,
|
|
prop1_id BIGINT NULL,
|
|
UNIQUE INDEX idx_alf_propuctx (value1_prop_id, value2_prop_id, value3_prop_id),
|
|
CONSTRAINT fk_alf_propuctx_v1 FOREIGN KEY (value1_prop_id) REFERENCES alf_prop_value (id) ON DELETE CASCADE,
|
|
CONSTRAINT fk_alf_propuctx_v2 FOREIGN KEY (value2_prop_id) REFERENCES alf_prop_value (id) ON DELETE CASCADE,
|
|
CONSTRAINT fk_alf_propuctx_v3 FOREIGN KEY (value3_prop_id) REFERENCES alf_prop_value (id) ON DELETE CASCADE,
|
|
CONSTRAINT fk_alf_propuctx_p1 FOREIGN KEY (prop1_id) REFERENCES alf_prop_root (id),
|
|
PRIMARY KEY (id)
|
|
) ENGINE=InnoDB;
|