forked from cerc-io/ipld-eth-server
6583ce72b8
* Logs now are attached to receipt, so removing block + index unique constraint
14 lines
223 B
PL/PgSQL
14 lines
223 B
PL/PgSQL
BEGIN;
|
|
ALTER TABLE logs
|
|
DROP CONSTRAINT log_uc;
|
|
|
|
ALTER TABLE logs
|
|
ADD COLUMN receipt_id INT;
|
|
|
|
ALTER TABLE logs
|
|
ADD CONSTRAINT receipts_fk
|
|
FOREIGN KEY (receipt_id)
|
|
REFERENCES receipts (id)
|
|
ON DELETE CASCADE;
|
|
|
|
COMMIT; |