1
0
mirror of https://github.com/Radarr/Radarr.git synced 2024-10-03 22:57:18 +02:00

Drop all Commands rows before running migration 204

This commit is contained in:
Qstick 2021-12-23 11:50:13 -06:00
parent eecd4e4b7d
commit 346236764c

View File

@ -8,6 +8,9 @@ public class ensure_identity_on_id_columns : NzbDroneMigrationBase
{
protected override void MainDbUpgrade()
{
//Purge Commands before reworking tables
Delete.FromTable("Commands").AllRows();
Alter.Column("Id").OnTable("Movies").AsInt32().PrimaryKey().Identity();
Alter.Column("Id").OnTable("MovieTranslations").AsInt32().PrimaryKey().Identity();
Alter.Column("Id").OnTable("Commands").AsInt32().PrimaryKey().Identity();