title: How to update primary key value in entity framework?
body: <p>I have table(and also entity in Entity Data Model) <code>Person</code> with following fields:</p>
  
  <pre><code>Name              Type
  SocialID          String      
  FirstName         String
  LastName          String
  </code></pre>
  
  <p>which <code>SocialID</code> is Primary Key. I want to update value of <code>SocialID</code> for each record. However when i try to update this field in Entity Framework I get following error:  </p>
  
  <pre><code>The property 'SocialID' is part of the object's key information and cannot 
  be modified.
  </code></pre>
  
  <p>The code that i get above error is:</p>
  
  <pre><code>foreach (var p in Entity.Persons)
  {
     p.SocialID= p.SocialID + "00";
     Entity.SaveChanges();
  }
  </code></pre>
  
  <p>How I can do this??</p>