<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/"><channel><title>O/R Mapper</title><link>http://davidhayden.com/blog/dave/category/24.aspx</link><description>O/R Mapper</description><managingEditor>Dave Hayden</managingEditor><dc:language>en-US</dc:language><generator>.Text Version 0.95.2004.101</generator><item><dc:creator>Dave Hayden</dc:creator><title>NHibernate and Castle ActiveRecord Tutorial for the Uninitiated</title><link>http://davidhayden.com/blog/dave/archive/2008/04/28/NHibernateCastleActiveRecordTutorialUninitiated.aspx</link><pubDate>Mon, 28 Apr 2008 09:24:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2008/04/28/NHibernateCastleActiveRecordTutorialUninitiated.aspx</guid><description>If you are interested in Castle ActiveRecord, The NHibernate FAQ has a new tutorial on getting started with Castle ActiveRecord.
&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3533.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>Dave Hayden</dc:creator><title>Retina.net O/R Mapper for the .NET Framework - Data Access Layer Generation</title><link>http://davidhayden.com/blog/dave/archive/2008/04/28/RetinaNetORMapperDataAccessLayerGeneration.aspx</link><pubDate>Mon, 28 Apr 2008 08:54:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2008/04/28/RetinaNetORMapperDataAccessLayerGeneration.aspx</guid><description>Retina.net is an O/R Mapper for the .NET Framework that appears to be active once again on CodePlex.&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3532.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>Dave Hayden</dc:creator><title>SubSonic 2.1 - Repository Pattern LINQ To Subsonic SubStage - Data Access Layer Generation</title><link>http://davidhayden.com/blog/dave/archive/2008/03/31/SubSonic21RepositoryPatternLINQToSubsonicSubStageDataAccessLayerGeneration.aspx</link><pubDate>Mon, 31 Mar 2008 23:07:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2008/03/31/SubSonic21RepositoryPatternLINQToSubsonicSubStageDataAccessLayerGeneration.aspx</guid><description>&lt;H1&gt;&lt;FONT face=Verdana&gt;SubSonic 2.1 - Repository Pattern LINQ To Subsonic SubStage - Data Access Layer Generation&lt;/FONT&gt;&lt;/H1&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;by &lt;A href="http://www.davidhayden.com/"&gt;David Hayden&lt;/A&gt;, &lt;A href="http://www.davidhayden.com/"&gt;Florida .NET Developer&lt;/A&gt; Filed: &lt;A href="http://davidhayden.com/blog/dave/category/10.aspx?Show=All"&gt;.NET Tools&lt;/A&gt;, &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/15.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;Code Generation&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;, &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/24.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;O/R Mapper&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;IMG alt=Subsonic src="/photos/subsonic3.jpg" align=right&gt;SubSonic is a cool &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/15.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;code generation tool&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; and &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/24.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;O/R Mapper&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; that helps you generate a &lt;/FONT&gt;&lt;A href="http://www.pnpguidance.net/Tag/DataAccessLayer.aspx"&gt;&lt;FONT face=Verdana size=2&gt;data access layer&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; for your ASP.NET and Winform .NET Applications.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;A new version of SubSonic, 2.1 Beta, includes a number of bug fixes as well as a new &lt;STRONG&gt;Repository Base Class&lt;/STRONG&gt; for those who don't appreciate &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2006/06/10/2984.aspx"&gt;&lt;FONT face=Verdana size=2&gt;ActiveRecord&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; and would prefer business classes void of data access code similar to the Repository Pattern in &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2006/06/21/2995.aspx"&gt;&lt;FONT face=Verdana size=2&gt;Domain-Driven Design&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;.&amp;nbsp;SubSonic has&amp;nbsp;a new &lt;STRONG&gt;Query Tool&lt;/STRONG&gt; as well as a feature called &lt;STRONG&gt;SubStage&lt;/STRONG&gt;. There is also some talk of &lt;STRONG&gt;LINQ To SubSonic&lt;/STRONG&gt; as well.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;If you are looking for a tool / framework to help you generate a data access layer for your ASP.NET Web Applications, certainly give SubSonic a spin as it is a very active community with new code generation and O/R Mapping features being added often.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;You can learn more by visiting the new SubSonic Project Home &lt;/FONT&gt;&lt;A href="http://subsonicproject.com/" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;here&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;. I recommend looking at &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/59.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;LINQ To SQL&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;, too.&lt;/FONT&gt;&lt;/P&gt;&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3507.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>Dave Hayden</dc:creator><title>High Performance LINQ To SQL - Compiled Queries - O/R Mappers - Ecommerce Websites</title><link>http://davidhayden.com/blog/dave/archive/2008/02/19/HighPerformanceLINQToSQLCompiledQueriesORMappersEcommerceWebsites.aspx</link><pubDate>Tue, 19 Feb 2008 19:30:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2008/02/19/HighPerformanceLINQToSQLCompiledQueriesORMappersEcommerceWebsites.aspx</guid><description>&lt;H1&gt;&lt;FONT face=Verdana&gt;High Performance LINQ To SQL - Compiled Queries - O/R Mappers - Ecommerce Websites&lt;/FONT&gt;&lt;/H1&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;by &lt;A href="http://www.davidhayden.com/"&gt;David Hayden&lt;/A&gt;, &lt;A href="http://www.davidhayden.com/"&gt;Florida ASP.NET Developer&lt;/A&gt;, Filed: &lt;A href="http://davidhayden.com/blog/dave/category/59.aspx?Show=All"&gt;LINQ To SQL&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;It should be of no surprise that an &lt;A href="http://davidhayden.com/blog/dave/category/24.aspx?Show=All"&gt;O/R Mapper&lt;/A&gt; will add overhead to performance as compared to the performance one would receive from a DataReader in ADO.NET. LINQ To SQL is no different. It adds a lot of services on top of ADO.NET, such as:&lt;/FONT&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Connection&amp;nbsp; Management&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Query Translation and Execution&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Object Identity&lt;/FONT&gt; 
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Change Tracking&lt;/FONT&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;This, of course, all comes at a little bit of a performance overhead. For most applications and user stories the&amp;nbsp;slower performance&amp;nbsp;is irrelevant. The value of the O/R Mapping services greatly outweigh any degradation in performance.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Sometimes, however, there may be a couple of database activities that are very expensive and we may want to achieve as optimal performance as possible even at the expense of maintainability. LINQ To SQL has a solution for these times - &lt;STRONG&gt;Compiled Queries&lt;/STRONG&gt;.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;H2&gt;&lt;FONT face=Verdana&gt;LINQ To SQL Compiled Queries&lt;/FONT&gt;&lt;/H2&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Let's pretend we have an &lt;STRONG&gt;e-commerce website&lt;/STRONG&gt; and getting Products By Category is an expensive operation. We have optimized the database as much as we can using proper indexing and covering indexes and it just isn't enough. We are using LINQ To SQL and we decide it is time for Compiled Queries. LINQ To SQL Compiled Queries allow the translation of the query to happen once at compile time and the query to be consumed many times. The lack of translation at each call will greatly improve performance for our e-commerce store.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Using Northwind, I create a partial class of the &lt;STRONG&gt;NorthwindDataContext&lt;/STRONG&gt; and add my compiled query:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN style="COLOR: #0000ff"&gt;public&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; &lt;FONT color=#0000ff&gt;partial&lt;/FONT&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;class&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; NorthwindDataContext
{
    &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;public&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;static&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; Func&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;NorthwindDataContext, &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;int&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;, IQueryable&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;Product&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;
        ProductsByCategoryID &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; &lt;FONT color=#ff0000&gt;CompiledQuery&lt;/FONT&gt;.&lt;FONT color=#ff0000&gt;Compile&lt;/FONT&gt;
            ((NorthwindDataContext context, &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;int&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; categoryID) &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;
            context.Products.Where(p &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; p.CategoryID &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;==&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; categoryID));

    &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;public&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; IQueryable&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;Product&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; GetProductsByCategoryIDFast(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;int&lt;BR&gt;                                                        &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;categoryID)
    {
        &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;return&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; ProductsByCategoryID(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;this&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;, categoryID);
    }
}&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Everything above is compiled except for the category I am searching on. Note we are using &lt;A href="http://davidhayden.com/blog/dave/archive/2006/12/18/ExpressionTrees.aspx"&gt;Expression Trees&lt;/A&gt;, which are new to &lt;A href="http://davidhayden.com/blog/dave/archive/2006/12/21/QueryExpressionsAnonymousTypesLambaExpressions.aspx"&gt;C# 3.0&lt;/A&gt;. This will greatly improve the performance of getting the products by category in my e-commerce store.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Now in my e-commerce website I will use the higher performance method of accessing the products in my product catalog by category:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN style="COLOR: #000000"&gt;NorthwindDataContext db &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;new&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; NorthwindDataContext();

List&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;Product&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; products &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; db.GetProductsByCategoryIDFast(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #ff0000"&gt;1&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;).ToList();&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Here I am getting all the products in my product catalog&amp;nbsp;in the CategoryID = 1. The improvement in performance is much better and very close to the performance of the speed of the DataReader in ADO.NET. This should make my e-commerce website perform much quicker than when not using a LINQ To SQL Compiled Query.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;For more information on the performance one achieves by using LINQ To SQL Compiled Queries, I recommend reading Rico Mariana's blog:&lt;/FONT&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://blogs.msdn.com/ricom/archive/2007/06/22/dlinq-linq-to-sql-performance-part-1.aspx" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;http://blogs.msdn.com/ricom/archive/2007/06/22/dlinq-linq-to-sql-performance-part-1.aspx&lt;/FONT&gt;&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;There are actually several parts to his LINQ To SQL performance testing that you can read on his blog.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;H2&gt;&lt;FONT face=Verdana&gt;Conclusion&lt;/FONT&gt;&lt;/H2&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;LINQ To SQL offers the option of Compiled Queries when you need to achieve DataReader like performances in ADO.NET. This comes at a bit of a price of maintenance, because you will need to create compiled queries for those operations you feel are expensive.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;H2&gt;&lt;FONT face=Verdana&gt;LINQ To SQL Tutorials&lt;/FONT&gt;&lt;/H2&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2008/01/01/ASPNETDynamicDataValidationLINQToSQLOnPropertyChangingPartialMethods.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;ASP.NET Dynamic Data and Validation Using LINQ To SQL OnPropertyChanging Partial Methods&lt;/FONT&gt;&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/10/28/LINQToSQLEnumSupportExampleDiscriminatorColumnInheritanceMapping.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL Enum Support Example Using Discriminator Column and Inheritance Mapping&lt;/FONT&gt;&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/10/26/LINQToSQLInheritanceDiscriminatorColumnExampleInheritanceMappingTutorial.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL Discriminator Column Example - Inheritance Mapping Tutorial&lt;/FONT&gt;&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/10/12/LINQToSQLAttachMethodAttachingDetachedBusinessEntitiesDataContextAttach.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL Attach Method for Attaching Detached Business Entities - DataContext.Attach&lt;/FONT&gt;&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/09/28/LINQToSQLVisualStudio2008PerformanceUpdate.aspx"&gt;&lt;FONT face=Verdana size=2&gt;LINQ To SQL and Visual Studio 2008 Performance Update&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/09/23/LINQPadDynamicallyQuerySQLDatabasesLINQ.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQPad - Dynamically Query SQL Server Databases in LINQ&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/20/LINQToSQLDebuggerVisualizerRevisitedSameConcernsBetterUI.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL Debugger Visualizer Revisited - Same Concerns Better UI :)&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/17/DataContextLogLoggingLINQToSQLOutputConsoleDebuggerOuputWindow.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;DataContext.Log - Logging LINQ To SQL Output to Console or Debugger Output Window&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/17/LINQToSQLDebuggerVisualizerVisualStudio2008HasLimitedValueLINQToSQLTutorials.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL Debugger Visualizer in Visual Studio 2008 Has Limited Value - LINQ To SQL Tutorials&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/09/LINQToSQLReplacementDataAccessGuidancePackage.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL As Replacement To Data Access Guidance Package&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/08/LINQDataAccessLayerCreatingInsertUpdateDeleteStoredProcedures.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ Data Access Layer - Creating Insert Update Delete Stored Procedures&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/07/CreatingDataAccessLayerLINQToSQLStoredProceduresSupport.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;Creating Data Access Layer Using LINQ To SQL - Stored Procedures Support&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/03/LinqDataSourceHighPerformanceQueriesDataLoadOptionsAvoidingDatabaseRoundtrips.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LinqDataSource - High Performance Queries Using DataLoadOptions - Avoiding Database Roundtrips&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/05/LINQToSQLPerformanceTradeoffsLessDatabaseRoundtripsButDuplicatedData.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ to SQL - Performance Tradeoffs: Less Database Roundtrips but Duplicated Data in Each Row??&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/05/LINQToSQLLazyLoadingPropertiesSpecifyingPreFetchWhenNeededPerformance.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL - Lazy Loading Properties and Specifying PreFetch When Needed - Sweet Query and Performance Control&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/06/LINQToSQLVideoGettingFromExpressionTreesToSQL.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL Video - Getting From Expression Trees to SQL&lt;/FONT&gt;&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Author:&amp;nbsp;&lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;David Hayden&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;, &lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;Florida&amp;nbsp;Website Developer&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Site: &lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;http://www.davidhayden.com/&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3464.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>Dave Hayden</dc:creator><title>LightSpeed O/R Mapper - High Performance .NET Domain Model and O/R Mapping Framework</title><link>http://davidhayden.com/blog/dave/archive/2007/12/21/LightSpeedORMapper.aspx</link><pubDate>Fri, 21 Dec 2007 19:58:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2007/12/21/LightSpeedORMapper.aspx</guid><description>&lt;H1&gt;&lt;FONT face=Verdana&gt;LightSpeed O/R Mapper - High Performance .NET Domain Model and O/R Mapping Framework&lt;/FONT&gt;&lt;/H1&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;by &lt;A href="http://www.davidhayden.com/"&gt;David Hayden&lt;/A&gt;, Filed: &lt;A href="http://davidhayden.com/blog/dave/category/24.aspx?Show=All"&gt;.NET O/R Mapper&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.mindscape.co.nz/products/LightSpeed/" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;&lt;IMG alt="O/R Mapper" src="/photos/lightspeed.jpg" align=right border=0&gt;&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;Writing data access code for a rich domain model is tedious and complicated. You need to get yourself an easy-to-use and performant O/R Mapper built using solid patterns &amp;amp; practices to handle it for you. I haven't tried &lt;/FONT&gt;&lt;A href="http://www.mindscape.co.nz/products/LightSpeed/" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;LightSpeed&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; yet, but it is on my list as I appreciate many of the values in the&amp;nbsp;O/R Mapper's&amp;nbsp;description:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;"LightSpeed is an innovative, high performance .NET domain model and O/R mapping framework designed to accelerate your development while, at the same time, providing your application with a solid foundation based on best practice domain-driven design patterns. With features like convention-over-configuration, fast data access, model validation and data binding, it allows you to focus your efforts where they should be: Solving business problems and not writing tedious infrastructure and "plumbing" code."&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;They just released a version 1.1 and the features look pretty impressive. If you are interested, they have an &lt;A href="http://www.mindscape.co.nz/products/LightSpeed/" target=_blank&gt;express edition you can download for free&lt;/A&gt;!&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Learn &lt;/FONT&gt;&lt;A href="http://www.mindscape.co.nz/products/LightSpeed/" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;more&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3418.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>Dave Hayden</dc:creator><title>eXpressApp Framework Released - ASP.NET Web Rapid Application Development ( RAD )</title><link>http://davidhayden.com/blog/dave/archive/2007/12/21/eXpressAppFrameworkReleasedASPNETWebRapidApplicationDevelopmentRAD.aspx</link><pubDate>Fri, 21 Dec 2007 19:29:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2007/12/21/eXpressAppFrameworkReleasedASPNETWebRapidApplicationDevelopmentRAD.aspx</guid><description>&lt;H1&gt;&lt;FONT face=Verdana&gt;eXpressApp Framework Released - ASP.NET Web Rapid Application Development ( RAD )&lt;/FONT&gt;&lt;/H1&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;by &lt;A href="http://www.davidhayden.com/"&gt;David Hayden&lt;/A&gt; ( &lt;A href="http://www.davidhayden.com/"&gt;Florida .NET Developer&lt;/A&gt; ), Filed: &lt;A href="http://davidhayden.com/blog/dave/category/10.aspx?Show=All"&gt;.NET Tools&lt;/A&gt;, &lt;A href="http://davidhayden.com/blog/dave/category/24.aspx?Show=All"&gt;O/R Mappers&lt;/A&gt;, &lt;A href="http://davidhayden.com/blog/dave/category/15.aspx?Show=All"&gt;Code Generation&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Developer Express released their &lt;STRONG&gt;eXpressApp Framework&lt;/STRONG&gt;, which is a winform and &lt;STRONG&gt;ASP.NET rapid application development framework&lt;/STRONG&gt; that utilizes a number of their other tools and components in DXperience. Per the website:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&amp;#8220;The eXpressApp Framework by Developer Express is a powerful instrument for creating business applications quickly and easily. A strong modular architecture allows for platform independent domain specific extensions. Examples of typical applications include business/sales/CRM systems, projects, documentation, HR and training class management, and many others. The currently supported target platforms are Windows Forms and ASP.NET 2, and our open architecture allows extensions of either of these platforms as well as the introduction of completely new targets (WPF support is part of our plans for the future).&amp;#8221;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Keep in mind that it is a 1.0 version, but if you are looking for a framework to rapidly build winform and ASP.NET 2.0 applications, you may want to take the trial download for a spin.&amp;nbsp;I suspect that just like with most frameworks&amp;nbsp;there is probably a decent learning curve before you can become really productive, but it may pay off in the long run.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Learn more &lt;A href="http://www.devexpress.com/Products/NET/Libraries/eXpressApp/Index.xml" target=_blank&gt;here&lt;/A&gt;.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3417.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>Dave Hayden</dc:creator><title>LLBLGen Pro v2.5 Released - Code Generation of the Data Access Layer</title><link>http://davidhayden.com/blog/dave/archive/2007/08/23/LLBLGenPro25ReleasedCodeGenerationDataAccessLayer.aspx</link><pubDate>Thu, 23 Aug 2007 14:09:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2007/08/23/LLBLGenPro25ReleasedCodeGenerationDataAccessLayer.aspx</guid><description>&lt;H1&gt;&lt;FONT face=Verdana&gt;LLBLGen Pro v2.5 Released - Code Generation of the Data Access Layer&lt;/FONT&gt;&lt;/H1&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;by &lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;David Hayden&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; ( &lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;Florida .NET Developer&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; ), Filed: &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/24.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;O/R Mappers&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;, &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/15.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;Code Generation&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;A new version of &lt;/FONT&gt;&lt;A href="http://www.llblgen.com/" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;LLBLGen Pro&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; has been released, version 2.5, with a number of&amp;nbsp;interesting features:&lt;/FONT&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;FONT face=Verdana&gt;&lt;FONT size=2&gt;&lt;STRONG&gt;Auditing&lt;/STRONG&gt; - Define auditors which record audit information during the entity's life cycle and provide audit entity objects (of the type you provide) to the framework to be persisted automatically when the audited entity is part of a transaction with the database. This gives great flexibility what to audit and when and frees the developer from the hassle to persist the audit entities at some point in time.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;FONT face=Verdana&gt;&lt;FONT size=2&gt;&lt;STRONG&gt;Authorization&lt;/STRONG&gt; - You can define, using whatever authorization mechanism you want to use, if a user at runtime is allowed to perform an action on / with an entity object or set of entity objects: field get/set, entity load, entity save (insert), entity save (update), entity delete, updates of entities directly in the database and deletes of entities directly in the database.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;FONT face=Verdana&gt;&lt;FONT size=2&gt;&lt;STRONG&gt;Dependency Injection&lt;/STRONG&gt; - 'Inject' instances of types at runtime into for example entity objects. This mechanism makes writing validation classes, concurrency predicate factories, authorizers etc. much easier as you don't have to add the code to inject instances of these classes into entity objects at runtime.&lt;/FONT&gt;&lt;/FONT&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;Fast and compact serialization/deserialization&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;Even better prefetch paths&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;Singularization and pluralization of names&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;Abbreviation support&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;In-memory hierarchical filtering and projections&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;Excluding fields for fetching&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/LI&gt;
&lt;LI&gt;&lt;STRONG&gt;&lt;FONT face=Verdana size=2&gt;Sybase ASA and ASE support, SqlServer CE Desktop support&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Frans has the &lt;/FONT&gt;&lt;A href="http://weblogs.asp.net/fbouma/archive/2007/08/23/llblgen-pro-v2-5-has-been-released.aspx" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;complete scoop on his blog&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;I am really interested in those top 3 features. I will have to play with the new version this&amp;nbsp;weekend.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;News Feed:&amp;nbsp;&lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;David Hayden&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; ( &lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;Florida .NET Developer&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; )&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Filed: &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/24.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;O/R Mappers&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;, &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/15.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;Code Generation&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3312.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>Dave Hayden</dc:creator><title>LINQ To SQL Debugger Visualizer Revisited - Same Concerns Better UI :)</title><link>http://davidhayden.com/blog/dave/archive/2007/08/20/LINQToSQLDebuggerVisualizerRevisitedSameConcernsBetterUI.aspx</link><pubDate>Mon, 20 Aug 2007 11:02:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2007/08/20/LINQToSQLDebuggerVisualizerRevisitedSameConcernsBetterUI.aspx</guid><description>&lt;H1&gt;&lt;FONT face=Verdana&gt;LINQ To SQL Debugger Visualizer Revisited - Same&amp;nbsp;Concerns Better UI :)&lt;/FONT&gt;&lt;/H1&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;by &lt;A href="http://www.davidhayden.com/"&gt;David Hayden&lt;/A&gt; ( &lt;A href="http://www.davidhayden.com/"&gt;Microsoft MVP C#&lt;/A&gt; ), Filed: &lt;A href="http://davidhayden.com/blog/dave/category/59.aspx?Show=All"&gt;LINQ To SQL&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;FONT color=#ff0000&gt;&lt;STRONG&gt;Update:&lt;/STRONG&gt;&lt;/FONT&gt; &lt;A href="http://codebetter.com/blogs/david.hayden/archive/2007/08/20/linq-to-sql-debugger-visualizer-concerns.aspx"&gt;Mentioned this on CodeBetter, too&lt;/A&gt; :) Check the comments. Scott Guthrie&amp;nbsp;sent an email to the developer about&amp;nbsp;looking into it.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;In the previous post I mentioned some concerns I have with the &lt;STRONG&gt;LINQ To SQL Debugger Visualizer&lt;/STRONG&gt; in that the query it displays is not the whole story:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/17/LINQToSQLDebuggerVisualizerVisualStudio2008HasLimitedValueLINQToSQLTutorials.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL Debugger Visualizer in Visual Studio 2008 Has Limited Value - LINQ To SQL Tutorials&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Turns out I wasn't even using the Debugger Visualizer - DOH! &lt;/FONT&gt;&lt;FONT face=Verdana size=2&gt;Here is the real LINQ To SQL Debugger Visualizer, which is a separate download:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P align=center&gt;&lt;FONT face=Verdana size=2&gt;&lt;IMG alt="LINQ To SQL Debugger Visualizer" src="http://www.davidhayden.com/photos/LINQToSQLDebuggerVisualizer2.jpg"&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;So, the debugger visualizer is much easier to work with than I previously mentioned in the&amp;nbsp;earlier post, but it still suggests only 1 query will be executed when in actuality it&amp;nbsp;will execute&amp;nbsp;40+ (correction: 90+ queries if you are using a non-modified Northwind which I&amp;nbsp;downloaded again because I&amp;nbsp;keep screwing with it&amp;nbsp;) queries to the database using the following code in beta 2:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;FONT face=Verdana&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: #0000ff"&gt;using&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; (NorthwindDataContext context &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;SPAN style="COLOR: #000000"&gt;
&lt;FONT face=Verdana size=2&gt;                            &lt;/FONT&gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;&lt;FONT face=Verdana size=2&gt;new&lt;/FONT&gt;&lt;/SPAN&gt;&lt;FONT face=Verdana&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: #000000"&gt; NorthwindDataContext())
{           
    DataLoadOptions options &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;new&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face=Verdana&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: #000000"&gt; DataLoadOptions();
    
    options.LoadWith&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;Customer&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;(c &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&amp;gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face=Verdana&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: #000000"&gt; c.Orders);
    options.LoadWith&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;Order&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;(o &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&amp;gt;&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;FONT face=Verdana&gt;&lt;FONT size=2&gt;&lt;SPAN style="COLOR: #000000"&gt; o.Order_Details);&lt;BR&gt;&lt;BR&gt;&lt;BR&gt;    context.LoadOptions = options;
    
    var query &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; from c &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;in&lt;/SPAN&gt;&lt;/FONT&gt;&lt;/FONT&gt;&lt;SPAN style="COLOR: #000000"&gt;&lt;FONT face=Verdana size=2&gt; context.Customers
                      select c;
}&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;I talked more about that in the previous post mentioned above.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;A little deceptive if you ask me, but still useful in other ways.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;News Feed:&amp;nbsp;&lt;A href="http://www.davidhayden.com/"&gt;David Hayden&lt;/A&gt; ( &lt;A href="http://www.davidhayden.com/"&gt;Microsoft MVP C#&lt;/A&gt; )&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Filed: &lt;A href="http://davidhayden.com/blog/dave/category/59.aspx?Show=All"&gt;LINQ To SQL&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3311.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>Dave Hayden</dc:creator><title>Repository Factory - Nice Improvements to the Data Access Guidance Package</title><link>http://davidhayden.com/blog/dave/archive/2007/08/19/RepositoryFactoryNiceImprovementsDataAccessGuidancePackage.aspx</link><pubDate>Sun, 19 Aug 2007 19:56:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2007/08/19/RepositoryFactoryNiceImprovementsDataAccessGuidancePackage.aspx</guid><description>&lt;H1&gt;&lt;FONT face=Verdana&gt;Repository Factory - Nice Improvements to the Data Access Guidance Package&lt;/FONT&gt;&lt;/H1&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;by &lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;David Hayden&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; ( &lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;Microsoft MVP C#&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; ), Filed: &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/15.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;Code Generation&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;I had some time this weekend to take a quick peek at the &lt;/FONT&gt;&lt;A href="http://www.pnpguidance.net/Category/RepositoryFactory.aspx" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;Repository Factory&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;, which is a new guidance package from the Microsoft Patterns &amp;amp; Practices Team that replaces the &lt;/FONT&gt;&lt;A href="http://www.pnpguidance.net/Post/DataAccessGuidancePackageBecomesRepositoryFactory.aspx" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;Data Access Guidance Package&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;. I talked about the Data Access Guidance Package in the following screencast:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.pnpguidance.net/Post/CreateDataAccessLayerUsingDataAccessGuidancePackageScreencast.aspx" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;Create Data Access Layer Using Data Access Guidance Package Screencast&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;FONT face=Verdana size=2&gt;Anyway, the team has already created a number of new improvements and features that were really exciting to play with this weekend:&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;UL&gt;&lt;SPAN&gt;
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Improved&amp;nbsp;Mapping of Stored Procedure Parameters to Entity Properties &lt;/FONT&gt;
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Generates an Interface for each Repository Class &lt;/FONT&gt;
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Generates a RepositoryFactory Class for Retrieving Individual Repositories &lt;/FONT&gt;
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Repositories Registered via Configuration Section in App.config / Web.config &lt;/FONT&gt;
&lt;LI&gt;&lt;FONT face=Verdana size=2&gt;Common and Base Repository Classes in Separate Repository Assembly&lt;/FONT&gt;&lt;/LI&gt;&lt;/SPAN&gt;&lt;/UL&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Very, very cool. You can see some code samples and photos over on &lt;A href="http://www.pnpguidance.net/" target=_blank&gt;PnPGuidance&lt;/A&gt;:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.pnpguidance.net/Post/RepositoryFactoryNewImprovedDataAccessGuidancePackage.aspx" target=_blank&gt;&lt;FONT face=Verdana size=2&gt;Repository Factory - New and Improved Data Access Guidance Package&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;SPAN&gt;&lt;FONT face=Verdana size=2&gt;Well worth using over the old Data Access Guidance Package starting now for that data access layer code generation!&lt;/FONT&gt;&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3310.aspx" width = "1" height = "1" /&gt;</description></item><item><dc:creator>Dave Hayden</dc:creator><title>DataContext.Log - Logging LINQ To SQL Output to Console or Debugger Output Window</title><link>http://davidhayden.com/blog/dave/archive/2007/08/17/DataContextLogLoggingLINQToSQLOutputConsoleDebuggerOuputWindow.aspx</link><pubDate>Fri, 17 Aug 2007 13:57:00 GMT</pubDate><guid>http://davidhayden.com/blog/dave/archive/2007/08/17/DataContextLogLoggingLINQToSQLOutputConsoleDebuggerOuputWindow.aspx</guid><description>&lt;H1&gt;&lt;FONT face=Verdana&gt;DataContext.Log - Logging LINQ To SQL Output to Console or Debugger Output Window&lt;/FONT&gt;&lt;/H1&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;by &lt;A href="http://www.davidhayden.com/"&gt;David Hayden&lt;/A&gt; ( &lt;A href="http://www.davidhayden.com/"&gt;Microsoft MVP C#&lt;/A&gt; ), Filed: &lt;A href="http://davidhayden.com/blog/dave/category/59.aspx?Show=All"&gt;LINQ To SQL&lt;/A&gt;, &lt;A href="http://davidhayden.com/blog/dave/category/24.aspx?Show=All"&gt;O/R Mappers&lt;/A&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Another quick tutorial on LINQ To SQL to append to the rest:&lt;/FONT&gt;&lt;/P&gt;
&lt;UL&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/17/LINQToSQLDebuggerVisualizerVisualStudio2008HasLimitedValueLINQToSQLTutorials.aspx"&gt;&lt;FONT face=Verdana size=2&gt;LINQ To SQL Debugger Visualizer in Visual Studio 2008 Has Limited Value - LINQ To SQL Tutorials&lt;/FONT&gt;&lt;/A&gt; 
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/09/LINQToSQLReplacementDataAccessGuidancePackage.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL As Replacement To Data Access Guidance Package&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/08/LINQDataAccessLayerCreatingInsertUpdateDeleteStoredProcedures.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ Data Access Layer - Creating Insert Update Delete Stored Procedures&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/07/CreatingDataAccessLayerLINQToSQLStoredProceduresSupport.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;Creating Data Access Layer Using LINQ To SQL - Stored Procedures Support&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/03/LinqDataSourceHighPerformanceQueriesDataLoadOptionsAvoidingDatabaseRoundtrips.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LinqDataSource - High Performance Queries Using DataLoadOptions - Avoiding Database Roundtrips&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/05/LINQToSQLPerformanceTradeoffsLessDatabaseRoundtripsButDuplicatedData.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ to SQL - Performance Tradeoffs: Less Database Roundtrips but Duplicated Data in Each Row??&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/05/LINQToSQLLazyLoadingPropertiesSpecifyingPreFetchWhenNeededPerformance.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL - Lazy Loading Properties and Specifying PreFetch When Needed - Sweet Query and Performance Control&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; &lt;/FONT&gt;
&lt;LI&gt;&lt;A href="http://davidhayden.com/blog/dave/archive/2007/08/06/LINQToSQLVideoGettingFromExpressionTreesToSQL.aspx"&gt;&lt;FONT face=Verdana color=#0000ff size=2&gt;LINQ To SQL Video - Getting From Expression Trees to SQL&lt;/FONT&gt;&lt;/A&gt;&lt;/LI&gt;&lt;/UL&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;&lt;/FONT&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Although you can always use SQL Server Profiler to view the SQL generated by LINQ To SQL, there is a &lt;STRONG&gt;DataContext.Log&lt;/STRONG&gt; Property that you can assign a TextWriter to view the SQL generated.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;For playing in&amp;nbsp;a console application, you have the option of assigning &lt;STRONG&gt;Console.Out&lt;/STRONG&gt;, which will display the SQL output to the console:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN style="COLOR: #0000ff"&gt;using&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; (NorthwindDataContext context &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;BR&gt;                           &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;new&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; NorthwindDataContext())
{          
    context.Log &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; Console.Out;

    Customer customer &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; context.Customers.Single&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;Customer&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;
                       (c &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; c.CustomerID.Equals(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #008080"&gt;ALFKI&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;));
}&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;However, displaying&amp;nbsp;the SQL code&amp;nbsp;in&amp;nbsp;the &lt;STRONG&gt;debugger output window&lt;/STRONG&gt; for non-console applications and even console applications is better using something like &lt;STRONG&gt;DebuggerWriter&lt;/STRONG&gt;, which is a wrapper around &lt;STRONG&gt;System.Diagnostics.Debugger:&lt;/STRONG&gt;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;&lt;SPAN style="COLOR: #0000ff"&gt;using&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; (NorthwindDataContext context &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;BR&gt;                         &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;new&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; NorthwindDataContext())
{          
    context.Log &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; &lt;/SPAN&gt;&lt;SPAN style="COLOR: #0000ff"&gt;new&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; DebuggerWriter();

    Customer customer &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; context.Customers.Single&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;lt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;Customer&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;
                        (c &lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;=&amp;gt;&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt; c.CustomerID.Equals(&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #008080"&gt;ALFKI&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;"&lt;/SPAN&gt;&lt;SPAN style="COLOR: #000000"&gt;));
}&lt;/SPAN&gt;&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;You can write your own DebuggerWriter, or you could check out the code from Kris Vandermotten:&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;A href="http://www.u2u.info/Blogs/Kris/Lists/Posts/Post.aspx?ID=11"&gt;&lt;FONT face=Verdana size=2&gt;Sending the LINQ To SQL log to the debugger output window&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Very cool, Kris!&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;News Feed:&amp;nbsp;&lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;David Hayden&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; ( &lt;/FONT&gt;&lt;A href="http://www.davidhayden.com/"&gt;&lt;FONT face=Verdana size=2&gt;Microsoft MVP C#&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt; )&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face=Verdana size=2&gt;Filed: &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/59.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;LINQ To SQL&lt;/FONT&gt;&lt;/A&gt;&lt;FONT face=Verdana size=2&gt;, &lt;/FONT&gt;&lt;A href="http://davidhayden.com/blog/dave/category/24.aspx?Show=All"&gt;&lt;FONT face=Verdana size=2&gt;O/R Mappers&lt;/FONT&gt;&lt;/A&gt;&lt;/P&gt;&lt;img src ="http://davidhayden.com/blog/dave/aggbug/3309.aspx" width = "1" height = "1" /&gt;</description></item></channel></rss>