Fix SQL issue: make event_variant field nullable.

Change-Id: I5937d4e2f6be1e3face7094dfd5cdf5414ab3007
This commit is contained in:
Andrew Garrett 2012-05-18 11:07:30 +10:00
parent 75301a8ed9
commit ed388e1916
3 changed files with 4 additions and 1 deletions

View file

@ -10,6 +10,8 @@ class EchoHooks {
$updater->modifyField( 'echo_event', 'event_agent',
"$dir/db_patches/patch-event_agent-split.sql", true );
$updater->modifyField( 'echo_event', 'event_variant',
"$dir/db_patches/patch-event_variant_nullability.sql", true );
return true;
}

View file

@ -0,0 +1 @@
ALTER TABLE /*_*/echo_event CHANGE COLUMN event_variant event_variant varchar(64) binary null;

View file

@ -16,7 +16,7 @@ CREATE TABLE /*_*/echo_event (
event_id int unsigned not null primary key auto_increment,
event_timestamp binary(14) not null,
event_type varchar(64) binary not null,
event_variant varchar(64) binary not null,
event_variant varchar(64) binary null,
event_agent_id int unsigned null, -- The user who triggered it, if any
event_agent_ip varchar(255) binary null, -- IP address who triggered it, if any
event_page_namespace int unsigned null,