class ChangeGovukGuixRevisionsPrimaryKey < ActiveRecord::Migration[5.1] def change execute 'ALTER TABLE govuk_guix_revisions DROP CONSTRAINT govuk_guix_revisions_pkey;' execute 'ALTER TABLE govuk_guix_revisions ADD PRIMARY KEY (commit_hash);' remove_column :govuk_guix_revisions, :id end end