<?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 : WinRT, Code First - &#039;Include&#039; clause does not work.</title>
  <link>http://www.ideablade.com/forum/</link>
  <description>This is an XML content feed of; DevForce Community Forum : DevForce 2012 : WinRT, Code First - &#039;Include&#039; clause does not work.</description>
  <pubDate>Fri, 10 Apr 2026 22:31:41 -700</pubDate>
  <lastBuildDate>Mon, 29 Jul 2013 12:24:07 -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=4249</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>WinRT, Code First - &#039;Include&#039; clause does not work. : It looks like DevForce has a problem...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=4249&amp;PID=16662#16662</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=11" rel="nofollow">kimj</a><br /><strong>Subject:</strong> 4249<br /><strong>Posted:</strong> 29-Jul-2013 at 12:24pm<br /><br />It looks like DevForce has a problem with the private setter on the User.UserRoles navigation property.&nbsp; It's probably eating the error and should not.&nbsp; You won't be able to use a private accessor, but in theory internal should be allowed, although that too doesn't seem to be working and is something we need to look at.<DIV sab="921">&nbsp;</DIV><DIV sab="922">To work around the issue, you can define the property like this:</DIV><DIV sab="923">&nbsp;</DIV><DIV sab="924">&nbsp; public RelatedEntityList&lt;UserRole&gt; UserRoles { get { return null; } }</DIV><DIV sab="925">&nbsp;</DIV><DIV sab="926">or this:</DIV><DIV sab="927">&nbsp;</DIV><DIV sab="928">&nbsp; public RelatedEntityList&lt;UserRole&gt; UserRoles { get; set; }</DIV><DIV sab="929">&nbsp;</DIV><DIV sab="930">More on defining navigation properties in Code First here - <a href="http://drc.ideablade.com/devforce-2012/bin/view/&#068;ocumentati&#111;n/code-first-entity-classes" target="_blank">http://drc.ideablade.com/devforce-2012/bin/view/Documentation/code-first-entity-classes</A>.</DIV><DIV sab="930">&nbsp;</DIV>]]>
   </description>
   <pubDate>Mon, 29 Jul 2013 12:24:07 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=4249&amp;PID=16662#16662</guid>
  </item> 
  <item>
   <title>WinRT, Code First - &#039;Include&#039; clause does not work. : Hi,  I am using EF Code First...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=4249&amp;PID=16657#16657</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=1552" rel="nofollow">zbig</a><br /><strong>Subject:</strong> 4249<br /><strong>Posted:</strong> 27-Jul-2013 at 1:49pm<br /><br />Hi,<br /><br />I am using EF Code First with fluent mapping. When I'm executing query which contains 'Include' clause, related entities are not retrieved. <br /><br />Please find attached a trivial application (package libraries removed to be able to attach the solution).The solution includes only three entities: User, Role, UserRole (many to many relational table).  <br /><br />I think, I made everything what is necessary to get related entities (according to the documentation), but after executing query (MainPage.xaml.cs):<br /><br /><br />var usersQuery = appTestEntityManager<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  .Users<br />&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  .Include(u =&gt; u.UserRoles);<br /><br />var result = await appTestEntityManager.ExecuteQueryAsync(usersQuery);<br /><br /><br />the 'result' variable does not contains related 'UserRoles'.<br /><br />Database is properly created and filled out by sample data during executing query. Everything seems to be ok ... I have no idea what is wrong. <br /><br />Thanks in advance for any advice. <br /><br /><a href="uploads/1552/AppTest.zip" target="_blank">AppTest.zip</a>]]>
   </description>
   <pubDate>Sat, 27 Jul 2013 13:49:31 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=4249&amp;PID=16657#16657</guid>
  </item> 
 </channel>
</rss>