dex/db/migrations/0009_key_not_primary_key.sql

6 lines
182 B
MySQL
Raw Normal View History

-- +migrate Up
ALTER TABLE key ADD COLUMN tmp_value bytea;
UPDATE KEY SET tmp_value = value;
ALTER TABLE key DROP COLUMN value;
ALTER TABLE key RENAME COLUMN "tmp_value" to "value";