Manual:Pagelinks table

From MediaWiki.org

(Redirected from Pagelinks table)
Jump to: navigation, search
Manual:Contents MediaWiki database layout Pagelinks table


Tracks all internal links in the Wiki. Each entry contains the source page's ID, and the namespace (number) and article name (in text) that is being linked to within that source page. There may be many instances of the source page's ID, as many as the internal links within it, but there can be only one entry per internal link for any page ID (or MYSQL will yell out a fatal error).

Note that the target page may or may not exist, and due to renames and deletions may refer to different page records as time goes by.[1]


MediaWiki version: 1.5

The table is new to version 1.5. It is the result of merging the links table and the brokenlinks table of version 1.4.

DESCRIBE pagelinks;

+--------------+-----------------+------+-----+---------+-------+
| Field        | Type            | Null | Key | Default | Extra |
+--------------+-----------------+------+-----+---------+-------+
| pl_from      | int(8) unsigned | NO   | PRI | 0       |       |
| pl_namespace | int(11)         | NO   | PRI | 0       |       |
| pl_title     | varchar(255)    | NO   | PRI |         |       |
+--------------+-----------------+------+-----+---------+-------+
MediaWiki version: 1.9
MediaWiki version: 1.8
+--------------+-----------------+------+-----+---------+-------+
| Field        | Type            | Null | Key | Default | Extra |
+--------------+-----------------+------+-----+---------+-------+
| pl_from      | int(8) unsigned | NO   | PRI | 0       |       |
| pl_namespace | int(11)         | NO   | PRI | 0       |       |
| pl_title     | varchar(255)    | NO   | PRI | NULL    |       |
+--------------+-----------------+------+-----+---------+-------+
MediaWiki version: 1.11
+--------------+------------------+------+-----+---------+-------+
| Field        | Type             | Null | Key | Default | Extra |
+--------------+------------------+------+-----+---------+-------+
| pl_from      | int(10) unsigned | NO   | PRI | 0       |       |
| pl_namespace | int(11)          | NO   | PRI | 0       |       |
| pl_title     | varchar(255)     | NO   | PRI |         |       |
+--------------+------------------+------+-----+---------+-------+
MediaWiki version: 1.12
+--------------+-----------------+------+-----+---------+-------+
| Field        | Type            | Null | Key | Default | Extra |
+--------------+-----------------+------+-----+---------+-------+
| pl_from      | int(8) unsigned | NO   | PRI | 0       |       |
| pl_namespace | int(11)         | NO   | PRI | 0       |       |
| pl_title     | varchar(255)    | NO   | PRI | NULL    |       |
+--------------+-----------------+------+-----+---------+-------+