title: Oracle entity in VS entity framework doesnt update the primary key in code
body: <p>I have an entity called Tree, which has a primary key called Id (with StoreGeneratedPattern = Identity) that when using the following code, correctly inserts into the database.</p>
  
  <pre><code>   using(TestContainer tss = new TestContainer())
     {
        Tree tree = new Tree()
        {
           Name = "TestTree"
        };
  
        tss.Trees.AddObject(tree);
        tss.SaveChanges();
     }
  </code></pre>
  
  <p>I have a backing sequence + trigger to handle the auto incremented primary key Id. I have verified that this actually inserts into the database correctly. </p>
  
  <p>Calling <code>tss.Refresh(System.Data.Objects.RefreshMode.StoreWins, tree);</code> does not update the object (the 'Id' field is still 0). Any ideas?</p>
  
  <pre><code>        &lt;EntityType Name="Tree"&gt;
            &lt;Key&gt;
              &lt;PropertyRef Name="Id" /&gt;
            &lt;/Key&gt;
            &lt;Property Type="Int32" Name="Id" Nullable="false" annotation:StoreGeneratedPattern="Identity" /&gt;
            &lt;Property Type="String" Name="Name" Nullable="false" /&gt;
            &lt;NavigationProperty Name="HeuristicCulls" Relationship="TOPSSSimpleSelect.TreeHeuristicCull" FromRole="Tree" ToRole="HeuristicCull" /&gt;
            &lt;Property Type="Int32" Name="Type" Nullable="false" /&gt;
            &lt;NavigationProperty Name="PR_T" Relationship="TOPSSSimpleSelect.PR_TTree" FromRole="Tree" ToRole="PR_T" /&gt;
            &lt;NavigationProperty Name="TreeItems" Relationship="TOPSSSimpleSelect.TreeTreeItem" FromRole="Tree" ToRole="TreeItem" /&gt;
            &lt;Property Type="Byte" Name="IsRoot" Nullable="false" /&gt;
            &lt;Property Type="Byte" Name="IsProductRoot" Nullable="false" /&gt;
            &lt;NavigationProperty Name="TreeProducts" Relationship="TOPSSSimpleSelect.T_TP" FromRole="Tree" ToRole="TreeProducts" /&gt;
          &lt;/EntityType&gt;
          &lt;EntityType Name="TreeItem"&gt;
            &lt;Key&gt;
              &lt;PropertyRef Name="Id" /&gt;
            &lt;/Key&gt;
            &lt;Property Type="Int32" Name="Id" Nullable="false" annotation:StoreGeneratedPattern="Identity" /&gt;
            &lt;NavigationProperty Name="Questions" Relationship="TOPSSSimpleSelect.TI_Q" FromRole="TreeItem" ToRole="Question" /&gt;
            &lt;Property Type="String" Name="Name" Nullable="false" /&gt;
            &lt;NavigationProperty Name="SubmitRules" Relationship="TOPSSSimpleSelect.SubmitRuleTreeItem" FromRole="TreeItem" ToRole="SubmitRule" /&gt;
            &lt;NavigationProperty Name="PR_TI" Relationship="TOPSSSimpleSelect.PR_TITreeItem" FromRole="TreeItem" ToRole="PR_TI" /&gt;
            &lt;NavigationProperty Name="Tree" Relationship="TOPSSSimpleSelect.TreeTreeItem" FromRole="TreeItem" ToRole="Tree" /&gt;
            &lt;Property Type="Int32" Name="TreeId" Nullable="false" annotation:StoreGeneratedPattern="Identity" /&gt;
            &lt;Property Type="Byte" Name="IsRoot" Nullable="false" /&gt;
          &lt;/EntityType&gt;
  </code></pre>