Fixed the foreign key checks

pull/3742/head
tidusjar 4 years ago
parent 14ba451f8f
commit 5a506ef8d8

@ -6,6 +6,7 @@ namespace Ombi.Store.Migrations.OmbiMySql
{ {
protected override void Up(MigrationBuilder migrationBuilder) protected override void Up(MigrationBuilder migrationBuilder)
{ {
migrationBuilder.Sql("SET FOREIGN_KEY_CHECKS=0;");
migrationBuilder.AlterColumn<string>( migrationBuilder.AlterColumn<string>(
name: "UserId", name: "UserId",
table: "Votes", table: "Votes",
@ -1448,6 +1449,9 @@ namespace Ombi.Store.Migrations.OmbiMySql
nullable: true, nullable: true,
oldClrType: typeof(string), oldClrType: typeof(string),
oldNullable: true); oldNullable: true);
migrationBuilder.Sql("SET FOREIGN_KEY_CHECKS=1;");
} }
} }
} }

Loading…
Cancel
Save