<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="http://syndication.webwiz.co.uk/rss_namespace/">
 <channel>
  <title>DevForce Community Forum : Many To Many Collection bug</title>
  <link>http://www.ideablade.com/forum/</link>
  <description>This is an XML content feed of; DevForce Community Forum : DevForce 2010 : Many To Many Collection bug</description>
  <pubDate>Sat, 11 Apr 2026 21:53:21 -700</pubDate>
  <lastBuildDate>Fri, 19 Nov 2010 09:04:30 -700</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 9.69</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>www.ideablade.com/forum/RSS_post_feed.asp?TID=2312</WebWizForums:feedURL>
  <image>
   <title>DevForce Community Forum</title>
   <url>http://www.ideablade.com/forum/forum_images/IdeaBlade_logo_tm.png</url>
   <link>http://www.ideablade.com/forum/</link>
  </image>
  <item>
   <title>Many To Many Collection bug : Hi Tersius,  The fix will be...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2312&amp;PID=9163#9163</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=892" rel="nofollow">sbelini</a><br /><strong>Subject:</strong> 2312<br /><strong>Posted:</strong> 19-Nov-2010 at 9:04am<br /><br />Hi Tersius,<DIV>&nbsp;</DIV><DIV>The fix will be available in DevForce 6.0.7 which will be released early in December.</DIV>]]>
   </description>
   <pubDate>Fri, 19 Nov 2010 09:04:30 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2312&amp;PID=9163#9163</guid>
  </item> 
  <item>
   <title>Many To Many Collection bug : Thanks, do you have any idea how...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2312&amp;PID=9149#9149</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=988" rel="nofollow">tersiusk</a><br /><strong>Subject:</strong> 2312<br /><strong>Posted:</strong> 17-Nov-2010 at 11:00pm<br /><br />Thanks, do you have any idea how long it will take to get this fixed?]]>
   </description>
   <pubDate>Wed, 17 Nov 2010 23:00:29 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2312&amp;PID=9149#9149</guid>
  </item> 
  <item>
   <title>Many To Many Collection bug : Hi tersiusk,   I verified the...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2312&amp;PID=9146#9146</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=892" rel="nofollow">sbelini</a><br /><strong>Subject:</strong> 2312<br /><strong>Posted:</strong> 17-Nov-2010 at 3:20pm<br /><br />Hi tersiusk, <DIV>&nbsp;</DIV><DIV>I verified the behavior you stated.</DIV><DIV>I am filing a bug an will follow up with you once the issue is fixed.</DIV><DIV>&nbsp;</DIV><DIV>sbelini.</DIV>]]>
   </description>
   <pubDate>Wed, 17 Nov 2010 15:20:11 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2312&amp;PID=9146#9146</guid>
  </item> 
  <item>
   <title>Many To Many Collection bug : HiI have found a possible bug...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2312&amp;PID=9140#9140</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=988" rel="nofollow">tersiusk</a><br /><strong>Subject:</strong> 2312<br /><strong>Posted:</strong> 17-Nov-2010 at 2:39am<br /><br /><div>Hi&nbsp;</div><div><br></div><div>I have found a possible bug in a Many To Many scenario. The following code throws the following exception.&nbsp;</div><div><span ="Apple-style-span" style="font-size: 11.6667px; "><table width="99%"><tr><td><pre class="BBcode"></span></div><div>Violation of PRIMARY KEY constraint 'PK_SystemFunctions'. Cannot insert duplicate key in object 'dbo.SystemFunctions'.</div><div><span ="Apple-style-span" style="font-size: 11.6667px; "></pre></td></tr></table></span></div><div><span ="Apple-style-span" style="font-size: 11.6667px; ">I merely remove an entity and then add another entity and then add the removed enitity again. This is not suppose to trigger any inserts since the record was not deleted but only removed and added in memory. Also when I use only EF the error goes away and it works.</span></div><div><table width="99%"><tr><td><pre class="BBcode"></div><div><div>&nbsp;var role = DemoDBEntities.DefaultManager.Roles.Where(r =&gt; r.Name == "RoleA").FirstOrDefault();</div><div><br></div><div>var remSystemfunction = role.SystemFunctions&#091;0&#093;;</div><div><br></div><div>var systemFunctionToAdd = DemoDBEntities.DefaultManager.SystemFunctions.</div><div>&nbsp;&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;Where(sf =&gt; sf.Name == "SystemFunctionC").FirstOrDefault();</div><div><br></div><div>role.SystemFunctions.Remove(remSystemfunction);</div><div>role.SystemFunctions.Add(systemFunctionToAdd);</div><div>role.SystemFunctions.Add(remSystemfunction);</div><div><br></div><div>DemoDBEntities.DefaultManager.SaveChanges();</div></div><div></pre></td></tr></table></div><div>I have attached a sample project along with a sql file to generate the database and some dummy records.</div><a href="uploads/988/ManyToManyBug.rar" target="_blank">uploads/988/ManyToManyBug.rar</a>]]>
   </description>
   <pubDate>Wed, 17 Nov 2010 02:39:54 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2312&amp;PID=9140#9140</guid>
  </item> 
 </channel>
</rss>