Fix the blocks table index
This commit is contained in:
parent
43a1a44a8f
commit
ab6f9130f0
2 changed files with 10 additions and 1 deletions
|
@ -133,6 +133,15 @@ public class DatabaseMigrations
|
|||
|
||||
migrations.add(blocksUpdate);
|
||||
|
||||
migrations.add(builder()
|
||||
.withTableID("blocks")
|
||||
.withVersion(3)
|
||||
.withMigrationAction(DatabaseWrapper.get().prepareStatement(" ALTER TABLE `blocks` DROP INDEX `posX`; "))
|
||||
.withMigrationAction(DatabaseWrapper.get().prepareStatement(" ALTER TABLE `blocks` DROP INDEX `posY`; "))
|
||||
.withMigrationAction(DatabaseWrapper.get().prepareStatement(" ALTER TABLE `blocks` DROP INDEX `posZ`; "))
|
||||
.withMigrationAction(DatabaseWrapper.get().prepareStatement("ALTER TABLE `savedBlocks`.`blocks` ADD UNIQUE (`posX`, `posY`, `posZ`); ")));
|
||||
|
||||
|
||||
|
||||
RegisterMigrationsEvent rme = new RegisterMigrationsEvent();
|
||||
MinecraftForge.EVENT_BUS.post(rme);
|
||||
|
|
Reference in a new issue