-- @depends: release_3_1_0
ALTER TABLE inventory RENAME orderitems_id TO delivery_order_items_stock_id;
ALTER TABLE inventory ADD CONSTRAINT delivery_order_items_stock_id_fkey FOREIGN KEY (delivery_order_items_stock_id) REFERENCES delivery_order_items_stock (id);
-- @depends: release_3_1_0
ALTER TABLE inventory RENAME orderitems_id TO delivery_order_items_stock_id;
ALTER TABLE inventory ADD CONSTRAINT delivery_order_items_stock_id_fkey FOREIGN KEY (delivery_order_items_stock_id) REFERENCES delivery_order_items_stock (id);