Manual:Watchlist table

From MediaWiki.org
(Redirected from Watchlist table)
Jump to: navigation, search
Manual:Contents MediaWiki database layout Watchlist table


The watchlist table contains for each registered user his or her id and for all the pages the user watches, the namespace number, the page title without namespace, and a notification timestamp, used for page change notification.

Contents

[edit] Fields

[edit] wl_user

This is the key to user.user_id.

[edit] wl_namespace

This is the key to page_namespace.

[edit] wl_title

This is the key to page_title.

[edit] wl_notificationtimestamp

This is the timestamp when the user was last sent a notification e-mail; it is cleared when the user visits the page.

[edit] Schema summary

MediaWiki version: 1.4

"DESCRIBE watchlist;" in version 1.4 gives the following:

+------------------+---------------------+------+-----+---------+----------------+
| Field            | Type                | Null | Key | Default | Extra          |
+------------------+---------------------+------+-----+---------+----------------+
| wl_user          | int(5) unsigned     |      |     |         |                |
| wl_namespace     | tinyint(2) unsigned |      |     |    0    |                |
| wl_title         | varchar(255) binary |      |     |    ''   |                |
+------------------+---------------------+------+-----+---------+----------------+
MediaWiki version: 1.5

"DESCRIBE watchlist;" in version 1.5 gives the following:

+--------------------------+-----------------+------+-----+---------+-------+
| Field                    | Type            | Null | Key | Default | Extra |
+--------------------------+-----------------+------+-----+---------+-------+
| wl_user                  | int(5) unsigned | NO   | PRI |         |       |
| wl_namespace             | int(11)         | NO   | PRI | 0       |       |
| wl_title                 | varchar(255)    | NO   | PRI |         |       |
| wl_notificationtimestamp | varchar(14)     | NO   |     | 0       |       |
+--------------------------+-----------------+------+-----+---------+-------+
MediaWiki version: 1.8

"DESCRIBE watchlist;" in version 1.8 gives the following:

+--------------------------+-----------------+------+-----+---------+-------+
| Field                    | Type            | Null | Key | Default | Extra |
+--------------------------+-----------------+------+-----+---------+-------+
| wl_user                  | int(5) unsigned | NO   | PRI | NULL    |       |
| wl_namespace             | int(11)         | NO   | PRI | 0       |       |
| wl_title                 | varchar(255)    | NO   | PRI | NULL    |       |
| wl_notificationtimestamp | varchar(14)     | YES  |     | NULL    |       |
+--------------------------+-----------------+------+-----+---------+-------+
MediaWiki version: 1.9
mysql> describe mw_watchlist;
+--------------------------+-----------------+------+-----+---------+-------+
| Field                    | Type            | Null | Key | Default | Extra |
+--------------------------+-----------------+------+-----+---------+-------+
| wl_user                  | int(5) unsigned | NO   | PRI | NULL    |       |
| wl_namespace             | int(11)         | NO   | PRI | 0       |       |
| wl_title                 | varchar(255)    | NO   | PRI | NULL    |       |
| wl_notificationtimestamp | varchar(14)     | YES  |     | NULL    |       |
+--------------------------+-----------------+------+-----+---------+-------+
4 rows in set (0.01 sec)
MediaWiki version: 1.16

"DESCRIBE mw_watchlist;" in version 1.16 gives the following:

mysql> DESCRIBE mw_watchlist;
+--------------------------+------------------+------+-----+---------+-------+
| Field                    | Type             | Null | Key | Default | Extra |
+--------------------------+------------------+------+-----+---------+-------+
| wl_user                  | int(10) unsigned | NO   | PRI | NULL    |       |
| wl_namespace             | int(11)          | NO   | PRI | 0       |       |
| wl_title                 | varbinary(255)   | NO   | PRI |         |       |
| wl_notificationtimestamp | varbinary(14)    | YES  |     | NULL    |       |
+--------------------------+------------------+------+-----+---------+-------+
4 rows in set (0.00 sec)

Some of this information was adapted from schema.doc in the MediaWiki docs/ directory.

Language: English  • 日本語 • Polski
Personal tools
Namespaces
Variants
Actions
Site
Support
Download
Development
Communication
Print/export
Toolbox