category
Documentation | Sakila |
Name | category |
Module | Inventory |
The category table lists the categories that can be assigned to a film.
The category table is joined to the film table by means of the film_category table.
Columns
Key | Name | Data type | Null | Attributes | References | Description | ||
---|---|---|---|---|---|---|---|---|
1 | category_id | unsigned tinyint(3, 0) | Identity / Auto increment column | A surrogate primary key used to uniquely identify each category in the table. | ||||
A surrogate primary key used to uniquely identify each category in the table. Identity / Auto increment column |
||||||||
2 | name | varchar(25) | The name of the category. | |||||
The name of the category. |
||||||||
3 | last_update | timestamp | Default: CURRENT_TIMESTAMP | The time that the row was created or most recently updated. | ||||
The time that the row was created or most recently updated. Default: CURRENT_TIMESTAMP |
Relations
Foreign table | Primary table | Join | Title / Name / Description | |
---|---|---|---|---|
film_category | category | film_category.category_id = category.category_id | fk_film_category_category Foreign key constraint referencing category.category_id |
|
film_category.category_id = category.category_id Name: fk_film_category_categoryForeign key constraint referencing category.category_id |
Unique keys
Key name | Columns | Description | |
---|---|---|---|
PRIMARY | category_id | Primary key. | |
Primary key. |
Used by
Name |
---|
category
|
Exported: 2018-10-12 17:43, Last imported: 2018-08-06 10:44