title: Autogenerate ID GUID datatype Entity Framework
body: <p>I have looked at this post and tried to do it this way</p>
  
  <p><a href="https://stackoverflow.com/questions/5610794/autogenerate-primary-key-guid-entity-framework-ctp5">Autogenerate primary key (Guid) Entity Framework CTP5</a></p>
  
  <pre><code> [Key, DatabaseGenerated(DatabaseGeneratedOption.Identity)]
   public Guid CompanyID { set; get; }
  </code></pre>
  
  <p>However I am still getting the error </p>
  
  <pre><code>Identity column 'CompanyID' must be of data type int, bigint, smallint, tinyint, or decimal or numeric with a scale of 0, and constrained to be nonnullable.
  </code></pre>
  
  <p>This is when I run Update-Database command on the package manager console.</p>