mediawiki-extensions-Echo/db_patches/echo_target_page.sql
bsitu 029668423d Add TargetPage model and mapper to notifications
This will be used for marking a notificaiton as read when
a user visits a target page. The new table should keep the
volume as low as possible for fast data loopup. records
should be removed from the table once it's marked as read.

Change-Id: I605cbc79adfc12d22bd889c5bb513d05c479fe6e
2014-08-13 00:48:07 +00:00

9 lines
402 B
SQL

CREATE TABLE /*_*/echo_target_page (
etp_user int unsigned not null default 0,
etp_page int unsigned not null default 0,
etp_event int unsigned not null default 0
) /*$wgDBTableOptions*/;
CREATE UNIQUE INDEX /*i*/echo_target_page_user_event ON /*_*/echo_target_page (etp_user, etp_event);
CREATE INDEX /*i*/echo_target_page_user_page_event ON /*_*/echo_target_page (etp_user, etp_page, etp_event);