salix/db/versions/10992-goldenIvy/00-referenceRate.sql

5 lines
301 B
SQL

ALTER TABLE vn.referenceRate DROP INDEX `PRIMARY`;
ALTER TABLE vn.referenceRate ADD id INT auto_increment PRIMARY KEY;
ALTER TABLE vn.referenceRate CHANGE id id int(11) auto_increment NOT NULL FIRST;
CREATE UNIQUE INDEX referenceRate_currencyFk_IDX USING BTREE ON vn.referenceRate (currencyFk,dated);