Skip to content

Commit

Permalink
Don't drop an index on a table that was just created
Browse files Browse the repository at this point in the history
  • Loading branch information
murrant committed Apr 25, 2016
1 parent 59428bb commit 40b598d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion sql-schema/113.sql
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
CREATE TABLE IF NOT EXISTS `route` ( `device_id` int(11) NOT NULL, `context_name` varchar(128) CHARACTER SET utf8 collate utf8_general_ci not null, `ipRouteDest` varchar(256) not null, `ipRouteIfIndex` varchar(256), `ipRouteMetric` varchar(256) not null, `ipRouteNextHop` varchar(256) not null, `ipRouteType` varchar(256) not null, `ipRouteProto` varchar(256) not null, `discoveredAt` int(11) NOT NULL, `ipRouteMask` varchar(256) not null ) ENGINE=InnoDB DEFAULT CHARSET=utf8;
ALTER TABLE `route` DROP INDEX `device` , ADD INDEX `device` (`device_id` ASC, `context_name` ASC, `ipRouteDest`(255) ASC, `ipRouteNextHop` ASC);
ALTER TABLE `route` ADD INDEX `device` (`device_id` ASC, `context_name` ASC, `ipRouteDest`(255) ASC, `ipRouteNextHop` ASC);

0 comments on commit 40b598d

Please sign in to comment.