title: updaing\saving with EF violates a DB uniquness restriction
body: <p>I'm using EF to update an entity.</p>
  
  <p>Here is my code:</p>
  
  <pre><code>    public MamConfiguration_V1 Save(MamConfiguration_V1 item)
      {
              item.ThrowIfNull("item");
  
              mMaMDBEntities.MamConfiguration_V1.AddObject(item);
  
              mMaMDBEntities.ObjectStateManager.ChangeObjectState(item, System.Data.EntityState.Modified);
  
              mMaMDBEntities.SaveChanges();
  
              return item;
      }
  </code></pre>
  
  <p>However in this way I get a PK violation erorr in the DB.</p>
  
  <p>I prefer to use this way (creating a new EF entity) and marking it as </p>
  
  <p>modified, how can I not break the uniquness restriction?</p>