Manual:templatelinks table

From MediaWiki.org
(Redirected from Templatelinks table)
Jump to: navigation, search
Translate this page; This page contains changes which are not marked for translation.

Other languages:
English • ‎日本語 • ‎polski
Manual:ContentsManual:Contents MediaWiki database layoutManual:Database layout templatelinks table


MediaWiki version: 1.6

Contains for each current page inclusion the id of the host page, the namespace number of the included page, and its title without namespace.

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]

Fields[edit]

tl_from[edit]

Key to the page_idManual:Page table#page_id of the page containing the link.

tl_from_namespace[edit]

MediaWiki version: 1.24

page_namespaceManual:Page table#page_namespace of the page containing the link.

tl_namespace[edit]

Key to page_namespaceManual:Page table#page_namespace of the target page. Used in conjunction with tl_title.

tl_title[edit]

Key to page_titleManual:Page table#page_title of the target page. Used in conjunction with tl_namespace.

Schema summary[edit]

MediaWiki version: 1.26

DESCRIBE templatelinks;

+-------------------+---------------------+------+-----+-----------+-------+
| Field             | Type                | Null | Key | Default   | Extra |
+-------------------+---------------------+------+-----+-----------+-------+
| tl_from           | int(10) unsigned    | NO   | PRI | 0         |       |
| tl_from_namespace | int(11)             | NO   | MUL | 0         |       |
| tl_namespace      | int(11)             | NO   | PRI | 0         |       |
| tl_title          | varchar(255) binary | NO   | PRI | 0         |       |
+-------------------+---------------------+------+-----+-----------+-------+


MediaWiki versions: 1.24 – 1.25

DESCRIBE templatelinks;

+-------------------+---------------------+------+-----+-----------+-------+
| Field             | Type                | Null | Key | Default   | Extra |
+-------------------+---------------------+------+-----+-----------+-------+
| tl_from           | int(10) unsigned    | NO   | PRI | 0         |       |
| tl_from_namespace | int(11)             | NO   |     | 0         |       |
| tl_namespace      | int(11)             | NO   | PRI | 0         |       |
| tl_title          | varchar(255) binary | NO   | PRI | 0         |       |
+-------------------+---------------------+------+-----+-----------+-------+


MediaWiki versions: 1.10 – 1.23

DESCRIBE templatelinks;

+---------------+---------------------+------+-----+-----------+-------+
| Field         | Type                | Null | Key | Default   | Extra |
+---------------+---------------------+------+-----+-----------+-------+
| tl_from       | int(10) unsigned    | NO   | PRI | 0         |       |
| tl_namespace  | int(11)             | NO   | PRI | 0         |       |
| tl_title      | varchar(255) binary | NO   | PRI | 0         |       |
+---------------+---------------------+------+-----+-----------+-------+


MediaWiki versions: 1.6 – 1.9

DESCRIBE templatelinks;

+---------------+---------------------+------+-----+-----------+-------+
| Field         | Type                | Null | Key | Default   | Extra |
+---------------+---------------------+------+-----+-----------+-------+
| tl_from       | int(8) unsigned     | NO   | PRI | 0         |       |
| tl_namespace  | int(8)              | NO   | PRI | 0         |       |
| tl_title      | varchar(255) binary | NO   | PRI | 0         |       |
+---------------+---------------------+------+-----+-----------+-------+
DatabasesManual:Database layout Engines: MySQL/MariaDBManual:MySQLOracleManual:OraclePostgreSQLManual:PostgreSQLSQLiteManual:SQLiteSQL ServerManual:Microsoft SQL Server

Technical documentation: SchemaManual:Database layout (tablesCategory:MediaWiki database tables) – API property associationsAPI:Database field and API property associationsField prefixesDatabase field prefixesPrimary key storage in other fieldsManual:Primary key storage in other fieldsWikimedia extension tablesCategory:Wikimedia extension database tables
Configuration: SettingsManual:Configuration_settings#Database_settingsSharingManual:Shared database
Development: AccessManual:Database accessOptimizationDatabase optimizationPolicyDevelopment policy#Database_patchesUpdaterManual:DatabaseUpdater.phpExtension schema updatesManual:Hooks/LoadExtensionSchemaUpdatesPatch fileManual:SQL patch file

Core tables: archivebot_passwordscategorycategorylinkschange_tagcommentconfigexternallinksfilearchivehitcounterimageimagelinksimage_comment_tempinterwikiiwlinksipblocksip_changesjobl10n_cachelanglinkslogginglog_searchmsg_resourcemsg_resource_linksmodule_depsobjectcacheoldimagepagepagelinkspage_propspage_restrictionsprotected_titlesquerycachequerycachetwoquerycache_inforecentchangesredirectrevisionrevision_comment_tempsearchindexsitessite_identifiers - site_statstag_summarytemplatelinkstexttranscacheupdateloguploadstashuseruser_former_groupsuser_groupsuser_newtalkuser_propertiestag_summaryvalid_tagwatchlist