From a93846d2d83b463fc90cfe7dbaa9294667dd5808 Mon Sep 17 00:00:00 2001 From: "kay.one" Date: Wed, 18 Jan 2012 21:12:30 -0800 Subject: [PATCH] Deleting any series with seriesid =0 during migration. --- .../Datastore/Migrations/Migration20120118.cs | 14 ++++++++++++++ NzbDrone.Core/NzbDrone.Core.csproj | 1 + 2 files changed, 15 insertions(+) create mode 100644 NzbDrone.Core/Datastore/Migrations/Migration20120118.cs diff --git a/NzbDrone.Core/Datastore/Migrations/Migration20120118.cs b/NzbDrone.Core/Datastore/Migrations/Migration20120118.cs new file mode 100644 index 000000000..627310419 --- /dev/null +++ b/NzbDrone.Core/Datastore/Migrations/Migration20120118.cs @@ -0,0 +1,14 @@ +using Migrator.Framework; + +namespace NzbDrone.Core.Datastore.Migrations +{ + + [Migration(20120118)] + public class Migration20120118 : NzbDroneMigration + { + protected override void MainDbUpgrade() + { + Database.ExecuteNonQuery("DELETE FROM SERIES WHERE SeriesID = 0"); + } + } +} \ No newline at end of file diff --git a/NzbDrone.Core/NzbDrone.Core.csproj b/NzbDrone.Core/NzbDrone.Core.csproj index e4cdcbf7a..39f602725 100644 --- a/NzbDrone.Core/NzbDrone.Core.csproj +++ b/NzbDrone.Core/NzbDrone.Core.csproj @@ -208,6 +208,7 @@ +