You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
19 lines
650 B
19 lines
650 B
using Migrator.Framework;
|
|
|
|
namespace NzbDrone.Core.Datastore.Migrations
|
|
{
|
|
|
|
[Migration(20120227)]
|
|
public class Migration20120227 : NzbDroneMigration
|
|
{
|
|
protected override void MainDbUpgrade()
|
|
{
|
|
Database.ExecuteNonQuery(@"DELETE FROM Seasons WHERE SeasonNumber NOT IN
|
|
(
|
|
SELECT DISTINCT SeasonNumber
|
|
FROM Episodes
|
|
WHERE Seasons.SeriesId = Episodes.SeriesId
|
|
)");
|
|
}
|
|
}
|
|
} |