public.customer
Description
Columns
Name | Type | Default | Nullable | Children | Parents | Comment |
---|---|---|---|---|---|---|
customer_id | integer | nextval('customer_customer_id_seq'::regclass) | false | public.payment_p2022_01 public.payment_p2022_02 public.payment_p2022_03 public.payment_p2022_04 public.payment_p2022_05 public.payment_p2022_06 public.rental | ||
store_id | integer | false | public.store | |||
first_name | text | false | ||||
last_name | text | false | ||||
text | true | |||||
address_id | integer | false | public.address | |||
activebool | boolean | true | false | |||
create_date | date | CURRENT_DATE | false | |||
last_update | timestamp with time zone | now() | true | |||
active | integer | true |
Constraints
Name | Type | Definition |
---|---|---|
customer_address_id_fkey | FOREIGN KEY | FOREIGN KEY (address_id) REFERENCES address(address_id) ON UPDATE CASCADE ON DELETE RESTRICT |
customer_pkey | PRIMARY KEY | PRIMARY KEY (customer_id) |
customer_store_id_fkey | FOREIGN KEY | FOREIGN KEY (store_id) REFERENCES store(store_id) ON UPDATE CASCADE ON DELETE RESTRICT |
Indexes
Name | Definition |
---|---|
customer_pkey | CREATE UNIQUE INDEX customer_pkey ON public.customer USING btree (customer_id) |
idx_fk_address_id | CREATE INDEX idx_fk_address_id ON public.customer USING btree (address_id) |
idx_fk_store_id | CREATE INDEX idx_fk_store_id ON public.customer USING btree (store_id) |
idx_last_name | CREATE INDEX idx_last_name ON public.customer USING btree (last_name) |
Triggers
Name | Definition |
---|---|
last_updated | CREATE TRIGGER last_updated BEFORE UPDATE ON public.customer FOR EACH ROW EXECUTE FUNCTION last_updated() |