When you use EF 6.x code first
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
public Guid Id { get; set; }
and initialize a database table, it will put a
(newsequentialid())
inside the table properties under the header Default Value or Binding, allowing the ID to be populated as it is inserted.
The problem is if you create a table and add the
[DatabaseGenerated(DatabaseGeneratedOption.Identity)]
part later, future update-databases won't add back the (newsequentialid())
To fix the proper way is to wipe migration, delete database and re-migrate... or you can just add (newsequentialid()) into the table designer.