Manual:Ipblocks table

The ipblocks table stores details of IP addresses and users who have been blocked from editing.

DESCRIBE ipblocks; gives the following:

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

The fields are:


 * ipb_id : Primary key, introduced for privacy.
 * ipb_address : Blocked IP address in dotted-quad form or user name.
 * ipb_user : Blocked user ID or 0 for IP blocks.
 * ipb_by : User ID of the administrator who made the block.
 * ipb_reason : Reason for the block given by the administrator.
 * ipb_timestamp : Creation (or refresh) date in standard YMDHMS form.
 * ipb_auto : Indicates that the IP address was banned because a banned user accessed a page through it. If this is 1, ipb_address will be hidden.
 * ipb_expiry : Expiry time set by the administrator at the time of the block

Some of this information was adapted from schema.doc.

Related pages: range blocks, admininstrator's guide to blocking, bans, bans and blocks.

DESCRIBE ipblocks; in MediaWiki 1.8 gives the following: ++-+--+-+-++ ++-+--+-+-++ ++-+--+-+-++
 * 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)        | NO   | MUL | NULL    |                |
 * ipb_auto          | tinyint(1)      | NO   |     | 0       |                |
 * ipb_anon_only     | tinyint(1)      | NO   |     | 0       |                |
 * ipb_create_account | tinyint(1)     | NO   |     | 1       |                |
 * ipb_expiry        | char(14)        | NO   | MUL | NULL    |                |
 * ipb_range_start   | tinyblob        | NO   | MUL | NULL    |                |
 * ipb_range_end     | tinyblob        | NO   |     | NULL    |                |

+--+-+--+-+-++ +--+-+--+-+-++ +--+-+--+-+-++
 * 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)        | NO   | MUL | NULL    |                |
 * ipb_auto            | tinyint(1)      | NO   |     | 0       |                |
 * ipb_anon_only       | tinyint(1)      | NO   |     | 0       |                |
 * ipb_create_account  | tinyint(1)      | NO   |     | 1       |                |
 * ipb_enable_autoblock | tinyint(1)     | NO   |     | 1       |                |
 * ipb_expiry          | char(14)        | NO   | MUL | NULL    |                |
 * ipb_range_start     | tinyblob        | NO   | MUL | NULL    |                |
 * ipb_range_end       | tinyblob        | NO   |     | NULL    |                |

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

+--+-+--+-+-++ +--+-+--+-+-++ +--+-+--+-+-++
 * 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)        | NO   | MUL | NULL    |                |
 * ipb_auto            | tinyint(1)      | NO   |     | 0       |                |
 * ipb_anon_only       | tinyint(1)      | NO   |     | 0       |                |
 * ipb_create_account  | tinyint(1)      | NO   |     | 1       |                |
 * ipb_enable_autoblock | tinyint(1)     | NO   |     | 1       |                |
 * ipb_expiry          | char(14)        | NO   | MUL | NULL    |                |
 * ipb_range_start     | tinyblob        | NO   | MUL | NULL    |                |
 * ipb_range_end       | tinyblob        | NO   |     | NULL    |                |
 * ipb_deleted         | tinyint(1)      | NO   |     | NULL    |                |
 * ipb_block_email     | tinyint(4)      | NO   |     | NULL    |                |