2018-05-22
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
actor_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
first_name | VARCHAR(45) | ✔ | |||||||||
last_name | VARCHAR(45) | ✔ | |||||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
address_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
address | VARCHAR(50) | ✔ | |||||||||
address2 | VARCHAR(50) | NULL | |||||||||
district | VARCHAR(20) | ✔ | |||||||||
city_id | SMALLINT(5) | ✔ | ✔ | ✔ | |||||||
postal_code | VARCHAR(10) | NULL | |||||||||
phone | VARCHAR(20) | ✔ | |||||||||
location | GEOMETRY | ✔ | |||||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
category_id | TINYINT(3) | ✔ | ✔ | ✔ | ✔ | ||||||
name | VARCHAR(25) | ✔ | |||||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
city_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
city | VARCHAR(50) | ✔ | |||||||||
country_id | SMALLINT(5) | ✔ | ✔ | ✔ | |||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
country_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
country | VARCHAR(50) | ✔ | |||||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
customer_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
store_id | TINYINT(3) | ✔ | ✔ | ✔ | |||||||
first_name | VARCHAR(45) | ✔ | |||||||||
last_name | VARCHAR(45) | ✔ | |||||||||
VARCHAR(50) | NULL | ||||||||||
address_id | SMALLINT(5) | ✔ | ✔ | ✔ | |||||||
active | TINYINT(1) | ✔ | '1' | ||||||||
create_date | DATETIME | ✔ | |||||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
film_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
title | VARCHAR(255) | ✔ | |||||||||
description | TEXT | NULL | |||||||||
release_year | YEAR(4) | NULL | |||||||||
language_id | TINYINT(3) | ✔ | ✔ | ✔ | |||||||
original_language_id | TINYINT(3) | ✔ | ✔ | NULL | |||||||
rental_duration | TINYINT(3) | ✔ | ✔ | '3' | |||||||
rental_rate | DECIMAL(4,2) | ✔ | '4.99' | ||||||||
length | SMALLINT(5) | ✔ | NULL | ||||||||
replacement_cost | DECIMAL(5,2) | ✔ | '19.99' | ||||||||
rating | ENUM('G', 'PG', 'PG-13', 'R', 'NC-17') | 'G' | |||||||||
special_features | SET('Trailers', 'Commentaries', 'Deleted Scenes', 'Behind the Scenes') | NULL | |||||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
actor_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
film_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
film_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
category_id | TINYINT(3) | ✔ | ✔ | ✔ | ✔ | ||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
film_id | SMALLINT(6) | ✔ | ✔ | ||||||||
title | VARCHAR(255) | ✔ | |||||||||
description | TEXT | NULL |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
inventory_id | MEDIUMINT(8) | ✔ | ✔ | ✔ | ✔ | ||||||
film_id | SMALLINT(5) | ✔ | ✔ | ✔ | |||||||
store_id | TINYINT(3) | ✔ | ✔ | ✔ | |||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
language_id | TINYINT(3) | ✔ | ✔ | ✔ | ✔ | ||||||
name | CHAR(20) | ✔ | |||||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
payment_id | SMALLINT(5) | ✔ | ✔ | ✔ | ✔ | ||||||
customer_id | SMALLINT(5) | ✔ | ✔ | ✔ | |||||||
staff_id | TINYINT(3) | ✔ | ✔ | ✔ | |||||||
rental_id | INT(11) | ✔ | NULL | ||||||||
amount | DECIMAL(5,2) | ✔ | |||||||||
payment_date | DATETIME | ✔ | |||||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
rental_id | INT(11) | ✔ | ✔ | ✔ | |||||||
rental_date | DATETIME | ✔ | |||||||||
inventory_id | MEDIUMINT(8) | ✔ | ✔ | ✔ | |||||||
customer_id | SMALLINT(5) | ✔ | ✔ | ✔ | |||||||
return_date | DATETIME | NULL | |||||||||
staff_id | TINYINT(3) | ✔ | ✔ | ✔ | |||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
staff_id | TINYINT(3) | ✔ | ✔ | ✔ | ✔ | ||||||
first_name | VARCHAR(45) | ✔ | |||||||||
last_name | VARCHAR(45) | ✔ | |||||||||
address_id | SMALLINT(5) | ✔ | ✔ | ✔ | |||||||
picture | BLOB | NULL | |||||||||
VARCHAR(50) | NULL | ||||||||||
store_id | TINYINT(3) | ✔ | ✔ | ✔ | |||||||
active | TINYINT(1) | ✔ | '1' | ||||||||
username | VARCHAR(16) | ✔ | |||||||||
password | VARCHAR(40) | NULL | |||||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |
Column name | DataType | PK | FK | NN | UQ | BIN | UN | ZF | AI | Default | Comment |
---|---|---|---|---|---|---|---|---|---|---|---|
store_id | TINYINT(3) | ✔ | ✔ | ✔ | ✔ | ||||||
manager_staff_id | TINYINT(3) | ✔ | ✔ | ✔ | |||||||
address_id | SMALLINT(5) | ✔ | ✔ | ✔ | |||||||
last_update | TIMESTAMP | ✔ | CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP |