--
CREATE TABLE /*_*/external_user (
-- Foreign key to user_id
- eu_wiki_id int unsigned NOT NULL PRIMARY KEY,
+ eu_local_id int unsigned NOT NULL PRIMARY KEY,
-- Some opaque identifier provided by the external database
eu_external_id varchar(255) binary NOT NULL
CREATE TABLE /*_*/transcache (
tc_url varbinary(255) NOT NULL,
tc_contents text,
- tc_time int NOT NULL
+ tc_time binary(14) NOT NULL
) /*$wgDBTableOptions*/;
CREATE UNIQUE INDEX /*i*/tc_url_idx ON /*_*/transcache (tc_url);
-- A table to track tags for revisions, logs and recent changes.
CREATE TABLE /*_*/change_tag (
- ct_rc_id int NULL, -- RCID for the change
- ct_log_id int NULL, -- LOGID for the change
- ct_rev_id int NULL, -- REVID for the change
- ct_tag varchar(255) NOT NULL, -- Tag applied
- ct_params blob NULL -- Parameters for the tag, presently unused.
+ -- RCID for the change
+ ct_rc_id int NULL,
+ -- LOGID for the change
+ ct_log_id int NULL,
+ -- REVID for the change
+ ct_rev_id int NULL,
+ -- Tag applied
+ ct_tag varchar(255) NOT NULL,
+ -- Parameters for the tag, presently unused
+ ct_params blob NULL
) /*$wgDBTableOptions*/;
CREATE UNIQUE INDEX /*i*/change_tag_rc_tag ON /*_*/change_tag (ct_rc_id,ct_tag);
-- Rollup table to pull a LIST of tags simply without ugly GROUP_CONCAT
-- that only works on MySQL 4.1+
CREATE TABLE /*_*/tag_summary (
- ts_rc_id int NULL, -- RCID for the change
- ts_log_id int NULL, -- LOGID for the change
- ts_rev_id int NULL, -- REVID for the change
- ts_tags blob NOT NULL -- Comma-separated list of tags.
+ -- RCID for the change
+ ts_rc_id int NULL,
+ -- LOGID for the change
+ ts_log_id int NULL,
+ -- REVID for the change
+ ts_rev_id int NULL,
+ -- Comma-separated list of tags
+ ts_tags blob NOT NULL
) /*$wgDBTableOptions*/;
CREATE UNIQUE INDEX /*i*/tag_summary_rc_id ON /*_*/tag_summary (ts_rc_id);