public.inventory
Documentation | Pagila |
Schema | public |
Name | inventory |
Module | Inventory |
Stores inventory data
Columns
Key | Name | Data type | Null | Attributes | References | Description | ||
---|---|---|---|---|---|---|---|---|
1 | inventory_id | integer | Default: nextval('inventory_inventory_id_seq'::regclass) | A surrogate primary key used to uniquely identify each item in inventory. | ||||
A surrogate primary key used to uniquely identify each item in inventory. Default: nextval('inventory_inventory_id_seq'::regclass) |
||||||||
2 | film_id | smallint | public.film | A foreign key pointing to the film this item represents. | ||||
A foreign key pointing to the film this item represents. References: public.film |
||||||||
3 | store_id | smallint | public.store | A foreign key pointing to the store stocking this item. | ||||
A foreign key pointing to the store stocking this item. References: public.store |
||||||||
4 | last_update | timestamp without time zone(6) | Default: now() | The time that the row was created or most recently updated. | ||||
The time that the row was created or most recently updated. Default: now() |
Relations
Foreign table | Primary table | Join | Title / Name / Description | |
---|---|---|---|---|
public.inventory | public.film | public.inventory.film_id = public.film.film_id | inventory_film_id_fkey Foreign key constraint referencing film.film_id |
|
public.inventory.film_id = public.film.film_id Name: inventory_film_id_fkeyForeign key constraint referencing film.film_id |
||||
public.inventory | public.store | public.inventory.store_id = public.store.store_id | inventory_store_id_fkey Foreign key constraint referencing store.store_id |
|
public.inventory.store_id = public.store.store_id Name: inventory_store_id_fkeyForeign key constraint referencing store.store_id |
||||
public.rental | public.inventory | public.rental.inventory_id = public.inventory.inventory_id | rental_inventory_id_fkey Foreign key constraint referencing inventory.inventory_id |
|
public.rental.inventory_id = public.inventory.inventory_id Name: rental_inventory_id_fkeyForeign key constraint referencing inventory.inventory_id |
Unique keys
Key name | Columns | Description | |
---|---|---|---|
inventory_pkey | inventory_id | Primary key. | |
Primary key. |
Triggers
Key name | When | Description | |
---|---|---|---|
last_updated | Before Update | The last_updated trigger sets last_update column of table to the current timestamp. | |
The last_updated trigger sets last_update column of table to the current timestamp. |
Uses
Name |
---|
public.inventory
|
Used by
Name |
---|
public.inventory
|
Exported: 2018-10-12 17:07, Last imported: 2018-08-06 09:25