Wiki 内で、すべての 内部リンク を追跡します。それぞれのエントリが、ソースページの ID と、そのソースページの中でリンクされている名前空間 (番号) と記事名 (テキスト) を格納しています。一つのソースページ ID に対して、複数の(最大でそのページに含まれる内部リンクと同数の)エントリが存在します。ただし、内部リンク一つにつき、高々一つのエントリしか存在しません。(さもなくば MYSQL が fatal error を発生させます)
ターゲットページは、存在しない可能性があることに注意してください。また、リネームや削除のため、元とは異なったページレコードを参照している可能性があることに注意してください。[1]
このテーブルは version 1.5 で新規に追加されました。これは version 1.4 において Links テーブル と Brokenlinks テーブル をマージした結果によります。Regenerating the pagelinks table always is possible using the rebuildall.php maintenance script.
pl_from [edit]
Key to the page_id of the page containing the link.
pl_namespace [edit]
Key to page_namespace/page_title of the target page. The target page may or may not exist, and due to renames and deletions may refer to different page records as time goes by.
pl_title [edit]
Key to page_namespace/page_title of the target page. The target page may or may not exist, and due to renames and deletions may refer to different page records as time goes by.
| MediaWiki バージョン: |
1.19 – 1.20 |
mysql> describe pagelinks;
+--------------+------------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+--------------+------------------+------+-----+---------+-------+
| pl_from | int(10) unsigned | NO | PRI | 0 | |
| pl_namespace | int(11) | NO | PRI | 0 | |
| pl_title | varbinary(255) | NO | PRI | | |
+--------------+------------------+------+-----+---------+-------+
DESCRIBE pagelinks; in version 1.18 gives the following:
+--------------+-----------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+--------------+-----------------+------+-----+---------+-------+
| pl_from | int(8) unsigned | NO | | 0 | |
| pl_namespace | int(11) | NO | | 0 | |
| pl_title | varbinary(255) | NO | | | |
+--------------+-----------------+------+-----+---------+-------+
+--------------+-----------------+------+-----+---------+-------+
| 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 | |
+--------------+-----------------+------+-----+---------+-------+
+--------------+------------------+------+-----+---------+-------+
| 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 | | |
+--------------+------------------+------+-----+---------+-------+
+--------------+-----------------+------+-----+---------+-------+
| 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 | |
+--------------+-----------------+------+-----+---------+-------+
+--------------+-----------------+------+-----+---------+-------+
| 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 | | |
+--------------+-----------------+------+-----+---------+-------+