BEGIN;

ALTER TABLE adjustment_stocks
    DROP CONSTRAINT IF EXISTS chk_adjustment_stocks_paired_not_self;

ALTER TABLE adjustment_stocks
    DROP CONSTRAINT IF EXISTS fk_adjustment_stocks_paired_adjustment_id;

DROP INDEX IF EXISTS idx_adjustment_stocks_paired_adjustment_id;

ALTER TABLE adjustment_stocks
    DROP COLUMN IF EXISTS paired_adjustment_id;

COMMIT;
