<?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 : Forcing Includes to come from cache</title>
  <link>http://www.ideablade.com/forum/</link>
  <description>This is an XML content feed of; DevForce Community Forum : DevForce 2010 : Forcing Includes to come from cache</description>
  <pubDate>Wed, 29 Jul 2026 06:11:51 -700</pubDate>
  <lastBuildDate>Thu, 21 Oct 2010 10:55:26 -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=2248</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>Forcing Includes to come from cache : But when I leave it off the include...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8874#8874</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=875" rel="nofollow">alindzon</a><br /><strong>Subject:</strong> 2248<br /><strong>Posted:</strong> 21-Oct-2010 at 10:55am<br /><br />But when I leave it off the include this is what happend even though its in cache.<DIV>I cam send you the entire trace, but here is the key piece.</DIV><DIV>SELECT <BR>&#091;Extent1&#093;.&#091;ManID&#093; AS &#091;ManID&#093;, <BR>&#091;Extent1&#093;.&#091;ManName&#093; AS &#091;ManName&#093;, <BR>&#091;Extent1&#093;.&#091;Synonyms&#093; AS &#091;Synonyms&#093;, <BR>&#091;Extent1&#093;.&#091;Display&#093; AS &#091;Display&#093;, <BR>&#091;Extent1&#093;.&#091;Srch&#093; AS &#091;Srch&#093;, <BR>&#091;Extent1&#093;.&#091;ProdCount&#093; AS &#091;ProdCount&#093;<BR>FROM &#091;dbo&#093;.&#091;Manufacturers&#093; AS &#091;Extent1&#093;<BR>WHERE 101424 = &#091;Extent1&#093;.&#091;ManID&#093;</DIV><DIV>&nbsp;</DIV><DIV>This occurs for each and every line in the gridview.&nbsp; </DIV><DIV>&nbsp;</DIV><DIV>But if I load up a manufacturer screen with just manufacturers in the grid there are NO database accessses at all.</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Thu, 21 Oct 2010 10:55:26 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8874#8874</guid>
  </item> 
  <item>
   <title>Forcing Includes to come from cache : alindzon, since the Manufacturers...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8873#8873</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> 2248<br /><strong>Posted:</strong> 21-Oct-2010 at 10:46am<br /><br />alindzon, since the Manufacturers are already in cache you don't need to, and actually shouldn't, use the Include when you query Products.&nbsp;&nbsp; DevForce won't resolve part of the query from the database and part from cache - the entire query with the Include will go to the database if the entire query can't be satisfied from cache.&nbsp;&nbsp; You'd use the Include when you didn't already have Products loaded, to bring in the object graph of Products and Manufacturers.]]>
   </description>
   <pubDate>Thu, 21 Oct 2010 10:46:58 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8873#8873</guid>
  </item> 
  <item>
   <title>Forcing Includes to come from cache : Then perhaps you have something...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8852#8852</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=531" rel="nofollow">midnit</a><br /><strong>Subject:</strong> 2248<br /><strong>Posted:</strong> 20-Oct-2010 at 8:05am<br /><br /><P>Then perhaps you have something set so it wont use cache. It does work, we have over 13 joins that never happen due to the cached data already existing.</P><span style="font-size:10px"><br /><br />Edited by midnit - 20-Oct-2010 at 8:07am</span>]]>
   </description>
   <pubDate>Wed, 20 Oct 2010 08:05:41 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8852#8852</guid>
  </item> 
  <item>
   <title>Forcing Includes to come from cache : I tried that before I added the...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8851#8851</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=875" rel="nofollow">alindzon</a><br /><strong>Subject:</strong> 2248<br /><strong>Posted:</strong> 20-Oct-2010 at 7:51am<br /><br />I tried that before I added the include, and not only was the database accessed, but it was accessed one entry at a time.&nbsp; i.e. each row on the datagrid resulted in a single query to the database.<DIV>&nbsp;</DIV><DIV>So I am afraid that did not work.</DIV><DIV>&nbsp;</DIV><DIV>What I did in the xaml was I put in Manufacturer.ManName as the field to display.</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Wed, 20 Oct 2010 07:51:04 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8851#8851</guid>
  </item> 
  <item>
   <title>Forcing Includes to come from cache : Basically you have to do nothing.  If...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8850#8850</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=531" rel="nofollow">midnit</a><br /><strong>Subject:</strong> 2248<br /><strong>Posted:</strong> 20-Oct-2010 at 7:47am<br /><br />Basically you have to do nothing.<DIV>&nbsp;</DIV><DIV>If the navigation property's item is in cache it will wire it up for you. So remove your includes for the items you already have in cache. Thats assuming you mean you already queried and the data is cached in the same entitymanager.</DIV>]]>
   </description>
   <pubDate>Wed, 20 Oct 2010 07:47:25 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8850#8850</guid>
  </item> 
  <item>
   <title>Forcing Includes to come from cache : I think this is a simple question....</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8849#8849</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=875" rel="nofollow">alindzon</a><br /><strong>Subject:</strong> 2248<br /><strong>Posted:</strong> 20-Oct-2010 at 6:10am<br /><br /><P>I think this is a simple question.&nbsp; I am keeping the entire manufacturer list in cache, which is working perfectly when I query against it.</P><DIV>I have a product table which is NOT in cache, and I am accessing it one page at a time.</DIV><DIV>&nbsp;</DIV><DIV>Every time I retrieve a page of products, I need to substitute the ManName for the ManID which is in the product file, for the view.&nbsp; i.e. I show Manufacturer.ManName which is related by the ManID.</DIV><DIV>&nbsp;</DIV><DIV>I want to compose the query in such a way that the ManName comes from cache and not from a join.</DIV><DIV>&nbsp;</DIV><DIV>I have about 5 tables I am keeping in cache because they are constantly needed as a resource, and there is no need to keep hitting the database.</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Wed, 20 Oct 2010 06:10:40 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2248&amp;PID=8849#8849</guid>
  </item> 
 </channel>
</rss>