<?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 : Splitting entity in multiple databases</title>
  <link>http://www.ideablade.com/forum/</link>
  <description>This is an XML content feed of; DevForce Community Forum : DevForce 2010 : Splitting entity in multiple databases</description>
  <pubDate>Mon, 13 Apr 2026 12:29:31 -700</pubDate>
  <lastBuildDate>Wed, 28 Sep 2011 16:18:40 -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=2983</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>Splitting entity in multiple databases : Hi Tristan,You would define a...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2983&amp;PID=11732#11732</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=477" rel="nofollow">ting</a><br /><strong>Subject:</strong> 2983<br /><strong>Posted:</strong> 28-Sep-2011 at 4:18pm<br /><br />Hi Tristan,<div><br></div><div>You would define a model (EDMX) for the customer database and another model for the shared database. A DevForce EntityManager can work with multiple models as shown in these examples:</div><div><a href="http://drc.ideablade.com/xwiki/bin/view/&#068;ocumentati&#111;n/many-models-per-manager" target="_blank">http://drc.ideablade.com/xwiki/bin/view/Documentation/many-models-per-manager</a></div><div><a href="http://drc.ideablade.com/xwiki/bin/view/&#068;ocumentati&#111;n/code-sample-query-multiple-models" target="_blank">http://drc.ideablade.com/xwiki/bin/view/Documentation/code-sample-query-multiple-models</a></div><div><a href="http://drc.ideablade.com/xwiki/bin/view/&#068;ocumentati&#111;n/code-sample-working-multiple-models" target="_blank">http://drc.ideablade.com/xwiki/bin/view/Documentation/code-sample-working-multiple-models</a></div><div><br></div><div>By default, there won't be navigation properties that navigate from one model to another (DevForce/EF doesn't know about these relationships), but you could write these yourself in the partial classes.</div><div><br></div><div>However,&nbsp;I'd recommend that you use a repository pattern in a different assembly to navigate across models. A repository pattern in general is a good idea, and it will save you from having to deal with any circular reference issues if you want to navigate bidirectionally between the models.</div><div><br></div><div>For example, one of the methods in the repository might look like this:</div><div>country = Repository.GetCountry(address);</div><div><br></div>]]>
   </description>
   <pubDate>Wed, 28 Sep 2011 16:18:40 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2983&amp;PID=11732#11732</guid>
  </item> 
  <item>
   <title>Splitting entity in multiple databases : We are developing a SaaS application...</title>
   <link>http://www.ideablade.com/forum/forum_posts.asp?TID=2983&amp;PID=11726#11726</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.ideablade.com/forum/member_profile.asp?PF=1093" rel="nofollow">s_tristan</a><br /><strong>Subject:</strong> 2983<br /><strong>Posted:</strong> 28-Sep-2011 at 6:27am<br /><br />We are developing a SaaS application that contains:<br><ul><li>one shared nonsecured database with reference data (countries, regions, cities etc.)</li><li>one separate database per each customer of application</li></ul>So there are a simply entity - Address with such properties:<br><ul><li>Zip (string)<br></li><li>Country (reference to Country)<br></li><li>Region (reference to Region)</li><li>City(reference to City)</li><li>Address line (string)</li></ul>We want to store Address entity in the customer database, while the references (Country, Region, City) are in the shared database.<br><br>How to implement this scenario with DF?<br>]]>
   </description>
   <pubDate>Wed, 28 Sep 2011 06:27:30 -700</pubDate>
   <guid isPermaLink="true">http://www.ideablade.com/forum/forum_posts.asp?TID=2983&amp;PID=11726#11726</guid>
  </item> 
 </channel>
</rss>