Manual:ipblocks table

From MediaWiki.org
Jump to: navigation, search
Manual:ContentsManual:Contents MediaWiki database layoutManual:Database layout ipblocks table


The ipblocks table stores details of IP addresses and users who are blocked from editing. The name "ipblocks" is a legacy name, as now user account blocks are also stored in this table. For previous blocks, see Manual:logging table.

Fields[edit]

ipb_id[edit]

MediaWiki version: 1.2

Primary key, introduced for privacy.

ipb_address[edit]

Blocked IP address in dotted-quad form or user name.

ipb_user[edit]

Blocked user ID or 0 for IP blocks.

ipb_by[edit]

User ID of the administrator who made the block.

ipb_by_text[edit]

MediaWiki version: 1.13

Text username of the administrator who made the block.

ipb_reason[edit]

Reason for the block given by the administrator.

ipb_timestamp[edit]

Creation (or refresh) date in standard YMDHMS form.

ipb_auto[edit]

Indicates that the IP address was blocked because a blocked user accessed a page through it. If this is 1, ipb_address will be hidden.

ipb_anon_only[edit]

MediaWiki version: 1.8

If set to 1, the block only applies to logged out users.

ipb_create_account[edit]

Prevents account creation from matching IP addresses.

ipb_enable_autoblock[edit]

MediaWiki version: 1.9

Enables autoblock on the block.

ipb_expiry[edit]

MediaWiki version: 1.2

Expiry time set by the administrator at the time of the block. A standard timestamp or the string 'infinity'

ipb_range_start[edit]

MediaWiki version: 1.6

The first IP in an IP range block.

ipb_range_end[edit]

The last IP in an IP range block.

ipb_deleted[edit]

MediaWiki version: 1.10

Allows the entry to be flagged, hiding it from users and sysops.

ipb_block_email[edit]

MediaWiki version: 1.11

Prevents the user from accessing Special:Emailuser

ipb_allow_usertalk[edit]

MediaWiki version: 1.14

Prevents a blocked user from editing their talk page. A value of 1 means that the user is not allowed to edit his user talk page. (Thus, a less confusing name would have been ipb_block_usertalk).

ipb_parent_block_id[edit]

MediaWiki version: 1.20

ID of the block that caused this block to exist. Autoblocks set this to the original block so that the original block being deleted also deletes the autoblocks.

Schema summary[edit]

MediaWiki version: 1.25

DESCRIBE ipblocks;

+----------------------+---------------------+------+-----+---------+----------------+
| Field                | Type                | Null | Key | Default | Extra          |
+----------------------+---------------------+------+-----+---------+----------------+
| ipb_id               | int(8)              | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address          | tinyblob            | NO   | MUL | NULL    |                |
| ipb_user             | int(8) unsigned     | NO   | MUL | 0       |                |
| ipb_by               | int(8) unsigned     | NO   |     | 0       |                |
| ipb_by_text          | varchar(255) binary | NO   |     | NULL    |                |
| ipb_reason           | varbinary(767)      | NO   |     | NULL    |                |
| ipb_timestamp        | binary(14)          | NO   | MUL | NULL    |                |
| ipb_auto             | bool                | NO   |     | 0       |                |
| ipb_anon_only        | bool                | NO   |     | 0       |                |
| ipb_create_account   | bool                | NO   |     | 1       |                |
| ipb_enable_autoblock | bool                | NO   |     | 1       |                |
| ipb_expiry           | varbinary(14)       | NO   | MUL | NULL    |                |
| ipb_range_start      | tinyblob            | NO   | MUL | NULL    |                |
| ipb_range_end        | tinyblob            | NO   |     | NULL    |                |
| ipb_deleted          | bool                | NO   |     | 0       |                |
| ipb_block_email      | bool                | NO   |     | 0       |                |
| ipb_allow_usertalk   | bool                | NO   |     | 0       |                |
| ipb_parent_block_id  | int(10)             | YES  | MUL | NULL    |                |
+----------------------+---------------------+------+-----+---------+----------------+


MediaWiki versions: 1.20 – 1.24

DESCRIBE ipblocks;

+----------------------+---------------------+------+-----+---------+----------------+
| Field                | Type                | Null | Key | Default | Extra          |
+----------------------+---------------------+------+-----+---------+----------------+
| ipb_id               | int(8)              | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address          | tinyblob            | NO   | MUL | NULL    |                |
| ipb_user             | int(8) unsigned     | NO   | MUL | 0       |                |
| ipb_by               | int(8) unsigned     | NO   |     | 0       |                |
| ipb_by_text          | varchar(255) binary | NO   |     | NULL    |                |
| ipb_reason           | tinyblob            | NO   |     | NULL    |                |
| ipb_timestamp        | binary(14)          | NO   | MUL | NULL    |                |
| ipb_auto             | bool                | NO   |     | 0       |                |
| ipb_anon_only        | bool                | NO   |     | 0       |                |
| ipb_create_account   | bool                | NO   |     | 1       |                |
| ipb_enable_autoblock | bool                | NO   |     | 1       |                |
| ipb_expiry           | varbinary(14)       | NO   | MUL | NULL    |                |
| ipb_range_start      | tinyblob            | NO   | MUL | NULL    |                |
| ipb_range_end        | tinyblob            | NO   |     | NULL    |                |
| ipb_deleted          | bool                | NO   |     | 0       |                |
| ipb_block_email      | bool                | NO   |     | 0       |                |
| ipb_allow_usertalk   | bool                | NO   |     | 0       |                |
| ipb_parent_block_id  | int(10)             | YES  | MUL | NULL    |                |
+----------------------+---------------------+------+-----+---------+----------------+


MediaWiki versions: 1.14 – 1.19

DESCRIBE ipblocks;

+----------------------+---------------------+------+-----+---------+----------------+
| Field                | Type                | Null | Key | Default | Extra          |
+----------------------+---------------------+------+-----+---------+----------------+
| ipb_id               | int(8)              | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address          | tinyblob            | NO   | MUL | NULL    |                |
| ipb_user             | int(8) unsigned     | NO   | MUL | 0       |                |
| ipb_by               | int(8) unsigned     | NO   |     | 0       |                |
| ipb_by_text          | varchar(255) binary | NO   |     | NULL    |                |
| ipb_reason           | tinyblob            | NO   |     | NULL    |                |
| ipb_timestamp        | binary(14)          | NO   | MUL | NULL    |                |
| ipb_auto             | bool                | NO   |     | 0       |                |
| ipb_anon_only        | bool                | NO   |     | 0       |                |
| ipb_create_account   | bool                | NO   |     | 1       |                |
| ipb_enable_autoblock | bool                | NO   |     | 1       |                |
| ipb_expiry           | varbinary(14)       | NO   | MUL | NULL    |                |
| ipb_range_start      | tinyblob            | NO   | MUL | NULL    |                |
| ipb_range_end        | tinyblob            | NO   |     | NULL    |                |
| ipb_deleted          | bool                | NO   |     | 0       |                |
| ipb_block_email      | bool                | NO   |     | 0       |                |
| ipb_allow_usertalk   | bool                | NO   |     | 0       |                |
+----------------------+---------------------+------+-----+---------+----------------+


MediaWiki version: 1.13

DESCRIBE ipblocks;

+----------------------+---------------------+------+-----+---------+----------------+
| Field                | Type                | Null | Key | Default | Extra          |
+----------------------+---------------------+------+-----+---------+----------------+
| ipb_id               | int(8)              | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address          | tinyblob            | NO   | MUL | NULL    |                |
| ipb_user             | int(8) unsigned     | NO   | MUL | 0       |                |
| ipb_by               | int(8) unsigned     | NO   |     | 0       |                |
| ipb_by_text          | varchar(255) binary | NO   |     | NULL    |                |
| ipb_reason           | tinyblob            | NO   |     | NULL    |                |
| ipb_timestamp        | binary(14)          | NO   | MUL | NULL    |                |
| ipb_auto             | bool                | NO   |     | 0       |                |
| ipb_anon_only        | bool                | NO   |     | 0       |                |
| ipb_create_account   | bool                | NO   |     | 1       |                |
| ipb_enable_autoblock | bool                | NO   |     | 1       |                |
| ipb_expiry           | varbinary(14)       | NO   | MUL | NULL    |                |
| ipb_range_start      | tinyblob            | NO   | MUL | NULL    |                |
| ipb_range_end        | tinyblob            | NO   |     | NULL    |                |
| ipb_deleted          | bool                | NO   |     | 0       |                |
| ipb_block_email      | bool                | NO   |     | 0       |                |
+----------------------+---------------------+------+-----+---------+----------------+


MediaWiki versions: 1.11 – 1.12

DESCRIBE ipblocks;

+----------------------+--------------------+------+-----+---------+----------------+
| Field                | Type               | Null | Key | Default | Extra          |
+----------------------+--------------------+------+-----+---------+----------------+
| ipb_id               | int(8)             | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address          | tinyblob           | NO   | MUL | NULL    |                |
| ipb_user             | int(8) unsigned    | NO   | MUL | 0       |                |
| ipb_by               | int(8) unsigned    | NO   |     | 0       |                |
| ipb_reason           | tinyblob           | NO   |     | NULL    |                |
| ipb_timestamp        | binary(14)         | NO   | MUL | NULL    |                |
| ipb_auto             | bool               | NO   |     | 0       |                |
| ipb_anon_only        | bool               | NO   |     | 0       |                |
| ipb_create_account   | bool               | NO   |     | 1       |                |
| ipb_enable_autoblock | bool               | NO   |     | 1       |                |
| ipb_expiry           | varbinary(14)      | NO   | MUL | NULL    |                |
| ipb_range_start      | tinyblob           | NO   | MUL | NULL    |                |
| ipb_range_end        | tinyblob           | NO   |     | NULL    |                |
| ipb_deleted          | bool               | NO   |     | 0       |                |
| ipb_block_email      | bool               | NO   |     | 0       |                |
+----------------------+--------------------+------+-----+---------+----------------+


MediaWiki version: 1.11

DESCRIBE ipblocks;

+----------------------+--------------------+------+-----+---------+----------------+
| Field                | Type               | Null | Key | Default | Extra          |
+----------------------+--------------------+------+-----+---------+----------------+
| ipb_id               | int(8)             | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address          | tinyblob           | NO   | MUL | NULL    |                |
| ipb_user             | int(8) unsigned    | NO   | MUL | 0       |                |
| ipb_by               | int(8) unsigned    | NO   |     | 0       |                |
| ipb_reason           | tinyblob           | NO   |     | NULL    |                |
| ipb_timestamp        | binary(14)         | NO   | MUL | NULL    |                |
| ipb_auto             | bool               | NO   |     | 0       |                |
| ipb_anon_only        | bool               | NO   |     | 0       |                |
| ipb_create_account   | bool               | NO   |     | 1       |                |
| ipb_enable_autoblock | bool               | NO   |     | 1       |                |
| ipb_expiry           | varbinary(14)      | NO   | MUL | NULL    |                |
| ipb_range_start      | tinyblob           | NO   | MUL | NULL    |                |
| ipb_range_end        | tinyblob           | NO   |     | NULL    |                |
| ipb_deleted          | bool               | NO   |     | 0       |                |
| ipb_block_email      | bool               | NO   |     | 0       |                |
+----------------------+--------------------+------+-----+---------+----------------+


MediaWiki version: 1.10

DESCRIBE ipblocks;

+----------------------+--------------------+------+-----+---------+----------------+
| Field                | Type               | Null | Key | Default | Extra          |
+----------------------+--------------------+------+-----+---------+----------------+
| ipb_id               | int(8)             | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address          | tinyblob           | NO   | MUL | NULL    |                |
| ipb_user             | int(8) unsigned    | NO   | MUL | 0       |                |
| ipb_by               | int(8) unsigned    | NO   |     | 0       |                |
| ipb_reason           | tinyblob           | NO   |     | NULL    |                |
| ipb_timestamp        | binary(14)         | NO   | MUL | NULL    |                |
| ipb_auto             | bool               | NO   |     | 0       |                |
| ipb_anon_only        | bool               | NO   |     | 0       |                |
| ipb_create_account   | bool               | NO   |     | 1       |                |
| ipb_enable_autoblock | bool               | NO   |     | 1       |                |
| ipb_expiry           | varbinary(14)      | NO   | MUL | NULL    |                |
| ipb_range_start      | tinyblob           | NO   | MUL | NULL    |                |
| ipb_range_end        | tinyblob           | NO   |     | NULL    |                |
| ipb_deleted          | bool               | NO   |     | 0       |                |
+----------------------+--------------------+------+-----+---------+----------------+


MediaWiki version: 1.9

DESCRIBE ipblocks;

+----------------------+--------------------+------+-----+---------+----------------+
| Field                | Type               | Null | Key | Default | Extra          |
+----------------------+--------------------+------+-----+---------+----------------+
| ipb_id               | int(8)             | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address          | tinyblob           | NO   | MUL | NULL    |                |
| ipb_user             | int(8) unsigned    | NO   | MUL | 0       |                |
| ipb_by               | int(8) unsigned    | NO   |     | 0       |                |
| ipb_reason           | tinyblob           | NO   |     | NULL    |                |
| ipb_timestamp        | char(14) binary    | NO   | MUL | NULL    |                |
| ipb_auto             | bool               | NO   |     | 0       |                |
| ipb_anon_only        | bool               | NO   |     | 0       |                |
| ipb_create_account   | bool               | NO   |     | 1       |                |
| ipb_enable_autoblock | bool               | NO   |     | 1       |                |
| ipb_expiry           | char(14) binary    | NO   | MUL | NULL    |                |
| ipb_range_start      | tinyblob           | NO   | MUL | NULL    |                |
| ipb_range_end        | tinyblob           | NO   |     | NULL    |                |
+----------------------+--------------------+------+-----+---------+----------------+


MediaWiki version: 1.8

DESCRIBE ipblocks;

+--------------------+--------------------+------+-----+---------+----------------+
| Field              | Type               | Null | Key | Default | Extra          |
+--------------------+--------------------+------+-----+---------+----------------+
| ipb_id             | int(8)             | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address        | tinyblob           | NO   | MUL | NULL    |                |
| ipb_user           | int(8) unsigned    | NO   | MUL | 0       |                |
| ipb_by             | int(8) unsigned    | NO   |     | 0       |                |
| ipb_reason         | tinyblob           | NO   |     | NULL    |                |
| ipb_timestamp      | char(14) binary    | NO   | MUL | NULL    |                |
| ipb_auto           | bool               | NO   |     | 0       |                |
| ipb_anon_only      | bool               | NO   |     | 0       |                |
| ipb_create_account | bool               | NO   |     | 1       |                |
| ipb_expiry         | char(14) binary    | NO   | MUL | NULL    |                |
| ipb_range_start    | tinyblob           | NO   | MUL | NULL    |                |
| ipb_range_end      | tinyblob           | NO   |     | NULL    |                |
+--------------------+--------------------+------+-----+---------+----------------+


MediaWiki versions: 1.6 – 1.7

DESCRIBE ipblocks;

+--------------------+--------------------+------+-----+---------+----------------+
| Field              | Type               | Null | Key | Default | Extra          |
+--------------------+--------------------+------+-----+---------+----------------+
| ipb_id             | int(8)             | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address        | varchar(40) binary | NO   | MUL | NULL    |                |
| ipb_user           | int(8) unsigned    | NO   | MUL | 0       |                |
| ipb_by             | int(8) unsigned    | NO   |     | 0       |                |
| ipb_reason         | tinyblob           | NO   |     | NULL    |                |
| ipb_timestamp      | char(14) binary    | NO   |     | NULL    |                |
| ipb_auto           | tinyint(1)         | NO   |     | 0       |                |
| ipb_expiry         | char(14) binary    | NO   |     | NULL    |                |
| ipb_range_start    | varchar(32)        | NO   | MUL | NULL    |                |
| ipb_range_end      | varchar(32)        | NO   |     | NULL    |                |
+--------------------+--------------------+------+-----+---------+----------------+


MediaWiki versions: 1.2 – 1.5

DESCRIBE ipblocks;

+--------------------+--------------------+------+-----+---------+----------------+
| Field              | Type               | Null | Key | Default | Extra          |
+--------------------+--------------------+------+-----+---------+----------------+
| ipb_id             | int(8)             | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address        | varchar(40) binary | NO   | MUL | NULL    |                |
| ipb_user           | int(8) unsigned    | NO   | MUL | 0       |                |
| ipb_by             | int(8) unsigned    | NO   |     | 0       |                |
| ipb_reason         | tinyblob           | NO   |     | NULL    |                |
| ipb_timestamp      | char(14) binary    | NO   |     | NULL    |                |
| ipb_auto           | tinyint(1)         | NO   |     | 0       |                |
| ipb_expiry         | char(14) binary    | NO   |     | NULL    |                |
+--------------------+--------------------+------+-----+---------+----------------+


MediaWiki version: 1.1

DESCRIBE ipblocks;

+--------------------+--------------------+------+-----+---------+----------------+
| Field              | Type               | Null | Key | Default | Extra          |
+--------------------+--------------------+------+-----+---------+----------------+
| ipb_id             | int(8)             | NO   | PRI | NULL    | AUTO_INCREMENT |
| ipb_address        | varchar(40) binary | NO   | MUL | NULL    |                |
| ipb_user           | int(8) unsigned    | NO   | MUL | 0       |                |
| ipb_by             | int(8) unsigned    | NO   |     | 0       |                |
| ipb_reason         | tinyblob           | NO   |     | NULL    |                |
| ipb_timestamp      | char(14) binary    | NO   |     | NULL    |                |
| ipb_auto           | tinyint(1)         | NO   |     | 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
Language:Project:Language policy English  • 日本語 • polski

See also[edit]