Asp.net core + EFCore + PostgreSQL: trouble with the migration?

Have an old migration which worked fine with MSSQL.
protected override void Up(MigrationBuilder migrationBuilder)
{
migrationBuilder.CreateTable(
 name: "Users",
 columns: table => new
{
 Id = table.Column<int>(nullable: false)
 .Annotation("SqlServer:ValueGenerationStrategy", SqlServerValueGenerationStrategy.IdentityColumn),
 Login = table.Column<string>(nullable: false),
 Password = table.Column<string>(nullable: false)
},
 constraints: table =>
{
 table.PrimaryKey("PK_Users", x => x.Id);
});
 }</string></string></int>

Now moved to PostgreSQL, and something went wrong..
when adding data to a table without explicitly specifying the exception id crashes:
null value in column "Id" violates not-null constraint
Failed executing DbCommand (4ms) [Parameters=[@p0='?', @p1='?'], CommandType='Text', CommandTimeout='30']
INSERT INTO "Users" ("Login", "Password")
VALUES (@p0, @p1)
RETURNING "Id";


I believe the problem is in the Sql annotation?
June 8th 19 at 16:58
0 answer

Find more questions by tags Entity FrameworkASP.NETPostgreSQL