From 8e037f644fcc090ab455cfecef6c2f26f738b1c0 Mon Sep 17 00:00:00 2001 From: Julio Montoya Date: Thu, 12 Jan 2012 12:45:54 +0100 Subject: [PATCH] default_value changed from tinytext to text --- main/install/db_stats.sql | 2 +- main/install/migrate-db-1.8.8-1.9.0-pre.sql | 9 ++------- 2 files changed, 3 insertions(+), 8 deletions(-) diff --git a/main/install/db_stats.sql b/main/install/db_stats.sql index 383e68b266..3349e334dd 100644 --- a/main/install/db_stats.sql +++ b/main/install/db_stats.sql @@ -77,7 +77,7 @@ CREATE TABLE track_e_default ( default_date datetime NOT NULL default '0000-00-00 00:00:00', default_event_type varchar(20) NOT NULL default '', default_value_type varchar(20) NOT NULL default '', - default_value tinytext NOT NULL, + default_value text NOT NULL, PRIMARY KEY (default_id) ); diff --git a/main/install/migrate-db-1.8.8-1.9.0-pre.sql b/main/install/migrate-db-1.8.8-1.9.0-pre.sql index 4d285efccc..cfd3a01e5d 100755 --- a/main/install/migrate-db-1.8.8-1.9.0-pre.sql +++ b/main/install/migrate-db-1.8.8-1.9.0-pre.sql @@ -90,20 +90,16 @@ ALTER TABLE group_rel_group ADD INDEX ( group_id ); ALTER TABLE group_rel_group ADD INDEX ( subgroup_id ); ALTER TABLE group_rel_group ADD INDEX ( relation_type ); - INSERT INTO settings_current (variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable) VALUES ('allow_teacher_change_gradebook_grading_model', NULL, 'radio', 'Gradebook', 'false', 'AllowTeacherChangeGradebookGradingModelTitle', 'AllowTeacherChangeGradebookGradingModelComment', NULL, NULL, 1); INSERT INTO settings_options (variable, value, display_text) VALUES ('allow_teacher_change_gradebook_grading_model', 'true', 'Yes'); INSERT INTO settings_options (variable, value, display_text) VALUES ('allow_teacher_change_gradebook_grading_model', 'false', 'No'); - INSERT INTO settings_current (variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable) VALUES ('grading_model', 'grading_model', 'custom', 'Gradebook', 'false', 'GradingModelTitle', 'GradingModelComment', NULL, NULL, 1); - INSERT INTO settings_options (variable, value, display_text) VALUES ('grading_model', '1*X+1*X', 'Model 1'); INSERT INTO settings_options (variable, value, display_text) VALUES ('grading_model', '1*X+1*X+1*X/3', 'Model 2'); INSERT INTO settings_options (variable, value, display_text) VALUES ('grading_model', '1*X+1*X+1*X+1*X/4', 'Model 3'); INSERT INTO settings_options (variable, value, display_text) VALUES ('grading_model', '1*X+2*X+1*X+2*X/6', 'Model 4'); - INSERT INTO settings_current (variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable) VALUES ('allow_users_to_change_email_with_no_password', NULL, 'radio', 'User', 'false', 'AllowUsersToChangeEmailWithNoPasswordTitle', 'AllowUsersToChangeEmailWithNoPasswordComment', NULL, NULL, 0); INSERT INTO settings_options (variable, value, display_text) VALUES ('allow_users_to_change_email_with_no_password', 'true', 'Yes'); INSERT INTO settings_options (variable, value, display_text) VALUES ('allow_users_to_change_email_with_no_password', 'false', 'No'); @@ -125,18 +121,15 @@ INSERT INTO settings_options (variable, value, display_text) VALUES ('allow_hr_s INSERT INTO settings_options (variable, value, display_text) VALUES ('allow_hr_skills_management', 'false', 'No'); INSERT INTO settings_current (variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable) VALUES ('show_admin_toolbar', NULL, 'radio', 'Platform', 'show_to_admin', 'ShowAdminToolbarTitle', 'ShowAdminToolbarComment', NULL, NULL, 1); - INSERT INTO settings_options (variable, value, display_text) VALUES ('show_admin_toolbar', 'do_not_show', 'DoNotShow'); INSERT INTO settings_options (variable, value, display_text) VALUES ('show_admin_toolbar', 'show_to_admin', 'ShowToAdminsOnly'); INSERT INTO settings_options (variable, value, display_text) VALUES ('show_admin_toolbar', 'show_to_admin_and_teachers', 'ShowToAdminsAndTeachers'); INSERT INTO settings_options (variable, value, display_text) VALUES ('show_admin_toolbar', 'show_to_all', 'ShowToAllUsers'); - INSERT INTO settings_current (variable, subkey, type, category, selected_value, title, comment, scope, subkeytext, access_url_changeable) VALUES ('allow_global_chat', NULL, 'radio', 'Platform', 'true', 'AllowGlobalChatTitle', 'AllowGlobalChatComment', NULL, NULL, 1); INSERT INTO settings_options (variable, value, display_text) VALUES ('allow_global_chat', 'true', 'Yes'); INSERT INTO settings_options (variable, value, display_text) VALUES ('allow_global_chat', 'false', 'No'); - CREATE TABLE chat (id INTEGER UNSIGNED NOT NULL AUTO_INCREMENT, from_user INTEGER, to_user INTEGER, message TEXT NOT NULL, sent DATETIME NOT NULL DEFAULT '0000-00-00 00:00:00', recd INTEGER UNSIGNED NOT NULL DEFAULT 0, PRIMARY KEY (id)); ALTER TABLE chat ADD INDEX idx_chat_to_user (to_user); ALTER TABLE chat ADD INDEX idx_chat_from_user (from_user); @@ -156,6 +149,8 @@ ALTER TABLE user_course_vote ADD INDEX idx_ucv_cid (c_id); ALTER TABLE user_course_vote ADD INDEX idx_ucv_uid (user_id); ALTER TABLE user_course_vote ADD INDEX idx_ucv_cuid (user_id, c_id); +ALTER TABLE track_e_default MODIFY COLUMN default_value TEXT; + -- Do not move this query UPDATE settings_current SET selected_value = '1.9.0.16427' WHERE variable = 'chamilo_database_version';