using System; using Microsoft.EntityFrameworkCore.Migrations; #nullable disable namespace LY.MicroService.TaskManagement.Migrations { public partial class ChangeBackgroundJobInfoKeyToString : Migration { protected override void Up(MigrationBuilder migrationBuilder) { migrationBuilder.AlterColumn( name: "Id", table: "TK_BackgroundJobs", type: "varchar(255)", nullable: false, oldClrType: typeof(Guid), oldType: "char(36)") .Annotation("MySql:CharSet", "utf8mb4") .OldAnnotation("Relational:Collation", "ascii_general_ci"); migrationBuilder.AlterColumn( name: "JobId", table: "TK_BackgroundJobLogs", type: "varchar(255)", maxLength: 255, nullable: true, oldClrType: typeof(Guid), oldType: "char(36)", oldNullable: true) .Annotation("MySql:CharSet", "utf8mb4") .OldAnnotation("Relational:Collation", "ascii_general_ci"); } protected override void Down(MigrationBuilder migrationBuilder) { migrationBuilder.AlterColumn( name: "Id", table: "TK_BackgroundJobs", type: "char(36)", nullable: false, collation: "ascii_general_ci", oldClrType: typeof(string), oldType: "varchar(255)") .OldAnnotation("MySql:CharSet", "utf8mb4"); migrationBuilder.AlterColumn( name: "JobId", table: "TK_BackgroundJobLogs", type: "char(36)", nullable: true, collation: "ascii_general_ci", oldClrType: typeof(string), oldType: "varchar(255)", oldMaxLength: 255, oldNullable: true) .OldAnnotation("MySql:CharSet", "utf8mb4"); } } }