New: Drop commands table content before postgres migration

Signed-off-by: Stevie Robinson <stevie.robinson@gmail.com>

(cherry picked from commit 8dd3b45c90209136c0bd0a861061c6d20837d62f)
This commit is contained in:
Stevie Robinson 2024-01-19 06:42:31 +01:00 committed by Bogdan
parent 18dc6f60b0
commit 77863dc2cf
1 changed files with 2 additions and 0 deletions

View File

@ -8,6 +8,8 @@ namespace NzbDrone.Core.Datastore.Migration
{
protected override void MainDbUpgrade()
{
Delete.FromTable("Commands").AllRows();
Alter.Table("Blocklist").AlterColumn("Date").AsDateTimeOffset().NotNullable();
Alter.Table("Blocklist").AlterColumn("PublishedDate").AsDateTimeOffset().Nullable();
Alter.Table("Collections").AlterColumn("Added").AsDateTimeOffset().Nullable();