upgrade.sql
changeset 256 f8356d9c3481
parent 244 7e094a04d84e
child 285 e72bf2c24875
equal deleted inserted replaced
255:c74736571f43 256:f8356d9c3481
     1 -- Enano CMS - upgrade SQL
     1 -- Enano CMS - upgrade SQL
     2 -- Variables are in the format {{VAR_NAME}}
     2 -- Variables are in the format {{VAR_NAME}}
     3 -- ALL NON-SQL LINES, even otherwise blank lines, must start with "--" or they will get sent to MySQL!
     3 -- ALL NON-SQL LINES, even otherwise blank lines, must start with "--" or they will get sent to MySQL!
     4 -- Common tasks (version numbers)
     4 -- Common tasks (version numbers)
     5 DELETE FROM {{TABLE_PREFIX}}config WHERE config_name='enano_version' OR config_name='enano_beta_version' OR config_name='enano_alpha_version' OR config_name='enano_rc_version';
     5 DELETE FROM {{TABLE_PREFIX}}config WHERE config_name='enano_version' OR config_name='enano_beta_version' OR config_name='enano_alpha_version' OR config_name='enano_rc_version';
     6 INSERT INTO {{TABLE_PREFIX}}config (config_name, config_value) VALUES( 'enano_version', '1.0.2' );
     6 INSERT INTO {{TABLE_PREFIX}}config (config_name, config_value) VALUES( 'enano_version', '1.0.3' );
       
     7 ---BEGIN 1.0.2---
       
     8 -- No DB changes in this release
       
     9 ---END 1.0.2---
     7 ---BEGIN 1.0.2b1---
    10 ---BEGIN 1.0.2b1---
     8 -- This is really optional, but could reduce confusion if regex page groups get truncated for no apparent reason.
    11 -- This is really optional, but could reduce confusion if regex page groups get truncated for no apparent reason.
     9 ALTER TABLE {{TABLE_PREFIX}}page_groups MODIFY COLUMN pg_target text DEFAULT NULL;
    12 ALTER TABLE {{TABLE_PREFIX}}page_groups MODIFY COLUMN pg_target text DEFAULT NULL;
    10 -- I have no idea how or why, but the f'ing index didn't get created for who-knows-how-many releases.
    13 -- I have no idea how or why, but the f'ing index didn't get created for who-knows-how-many releases.
    11 -- We'll attempt to create it here, but don't die if it fails
    14 -- We'll attempt to create it here, but don't die if it fails