using Microsoft.EntityFrameworkCore.Migrations;
#nullable disable
namespace DD.Persistence.Database.Postgres.Migrations
{
///
public partial class ParameterDataMigration : Migration
{
///
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
name: "ParameterData",
columns: table => new
{
DiscriminatorId = table.Column(type: "uuid", nullable: false, comment: "Дискриминатор системы"),
ParameterId = table.Column(type: "integer", nullable: false, comment: "Id параметра"),
Timestamp = table.Column(type: "timestamp with time zone", nullable: false, comment: "Временная отметка"),
Value = table.Column(type: "varchar(256)", nullable: false, comment: "Значение параметра в виде строки")
},
constraints: table =>
{
table.PrimaryKey("PK_ParameterData", x => new { x.DiscriminatorId, x.ParameterId, x.Timestamp });
});
}
///
protected override void Down(MigrationBuilder migrationBuilder)
{
migrationBuilder.DropTable(
name: "ParameterData");
}
}
}