container.copy_bucket_item
|
Cascading Deletes: Deleting rows from this table will cascade to: container.copy_bucket. |
|
Deferrable Constraints: The following FK constraints are deferrable — they are checked at transaction end, not statement end: |
Columns
| Column | Type | Nullable | Default | Notes |
|---|---|---|---|---|
id PK |
|
No |
nextval('container.copy_bucket_item_id_seq'::regclass) |
|
bucket FK |
|
No |
||
target_copy |
|
No |
||
pos |
|
Yes |
||
create_time |
|
No |
now() |
Foreign Keys
| Column(s) | References | On Delete | On Update | Deferrable | Constraint |
|---|---|---|---|---|---|
|
CASCADE |
CASCADE |
DEFERRED |
|
Indexes
| Index | Method | Definition |
|---|---|---|
|
btree |
|
|
btree |
|
Triggers
| Trigger | Timing | Event | Level | Function |
|---|---|---|---|---|
|
AFTER |
INSERT OR UPDATE |
ROW |
Trigger Bodies
inherit_copy_bucket_item_target_copy_fkey
Function: evergreen.container_copy_bucket_item_target_copy_inh_fkey()
Timing: AFTER INSERT OR UPDATE ROW
BEGIN
PERFORM 1 FROM asset.copy WHERE id = NEW.target_copy;
IF NOT FOUND THEN
RAISE foreign_key_violation USING MESSAGE = FORMAT(
$$Referenced asset.copy id not found, target_copy:%s$$, NEW.target_copy
);
END IF;
RETURN NEW;
END;