<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>Diego Vega - All Comments</title><link>http://blogs.msdn.com/b/diego/</link><description>Entity Framework news and sporadic epiphanies</description><dc:language>en-US</dc:language><generator>Telligent Evolution Platform Developer Build (Build: 5.6.50428.7875)</generator><item><title>re: Tips to avoid deadlocks in Entity Framework applications</title><link>http://blogs.msdn.com/b/diego/archive/2012/04/01/tips-to-avoid-deadlocks-in-entity-framework-applications.aspx#10401710</link><pubDate>Tue, 12 Mar 2013 19:13:08 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10401710</guid><dc:creator>Diego B Vega</dc:creator><description>&lt;p&gt;Hello Mukesh,&lt;/p&gt;
&lt;p&gt;As long as the TransactionScope is created with ReadCommitted and READ_COMMITTED_SNAPSHOT is not enabled in the database then you are not really following the recommendations I explained in this blog post and I assume that you might be seeing locking issues because you are in fact using the default implementation of READ COMMITTED, which uses locking.&lt;/p&gt;
&lt;p&gt;While READ COMMITTED and SNAPSHOT are two different transaction isolation levels you can choose from by passing an argument to TransactionScope, READ_COMMITTED_SNAPSHOT setting on the other hand is a database-wide setting that replaces the default implementation of READ COMMITTED which uses locking with one that has READ COMMITTED semantics but uses snapshots.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10401710" width="1" height="1"&gt;</description></item><item><title>re: Tips to avoid deadlocks in Entity Framework applications</title><link>http://blogs.msdn.com/b/diego/archive/2012/04/01/tips-to-avoid-deadlocks-in-entity-framework-applications.aspx#10401695</link><pubDate>Tue, 12 Mar 2013 18:26:36 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10401695</guid><dc:creator>Mukesh</dc:creator><description>&lt;p&gt;In the EF code, I have &amp;nbsp;TransactionScope &amp;nbsp;as ReadCommitted Isolation. I set the SNAPSHOT ISOLATION to ON. But READ COMMITTED SNAPSHOT is OFF. I am still facing locking issues. Any ideas?&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10401695" width="1" height="1"&gt;</description></item><item><title>re: Wrapped System.IO.FileNotFoundException with Entity Framework POCO and Self-Tracking Entities T4 Templates</title><link>http://blogs.msdn.com/b/diego/archive/2010/04/14/wrapped-system-io-filenotfoundexception-with-entity-framework-poco-and-self-tracking-entities-t4-templates.aspx#10393661</link><pubDate>Thu, 14 Feb 2013 12:30:17 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10393661</guid><dc:creator>Gurbax Bhangal</dc:creator><description>&lt;p&gt;Thanks a lot .......it worked for me&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10393661" width="1" height="1"&gt;</description></item><item><title>re: Workaround for performance with Enumerable.Contains and non-Unicode columns against EF in .NET 4.0</title><link>http://blogs.msdn.com/b/diego/archive/2012/12/12/workaround-for-performance-with-enumerable-contains-and-non-unicode-columns-against-ef-in-net-4-0.aspx#10379395</link><pubDate>Wed, 19 Dec 2012 11:52:21 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10379395</guid><dc:creator>Felipe Fujiy</dc:creator><description>&lt;p&gt;Diego, one thing that always bite me, is how to encapsulate Filters. Sometimes I do a extension method:&lt;/p&gt;
&lt;p&gt;public static IQueryable&amp;lt;EDIFICIO&amp;gt; WhereFromProject(this IQueryable&amp;lt;EDIFICIO&amp;gt; source, int idProject)&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;{&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;return andares.Where(x=&amp;gt; x.prj == idProject);&lt;/p&gt;
&lt;p&gt; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;}&lt;/p&gt;
&lt;p&gt;But it just works on main collection like container.EDIFICIO.WhereFromProject(idProject) and not on subqueries: container.AnotherEntity.Where(x=&amp;gt; x.EDIFICIO. WhereFromProject(idProject))&lt;/p&gt;
&lt;p&gt;Is it possible to do something similar usaing Expressions and MethodInfo as you did? Could you send me a example? Would help so much.&lt;/p&gt;
&lt;p&gt;Thx&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10379395" width="1" height="1"&gt;</description></item><item><title>re: Wrapped System.IO.FileNotFoundException with Entity Framework POCO and Self-Tracking Entities T4 Templates</title><link>http://blogs.msdn.com/b/diego/archive/2010/04/14/wrapped-system-io-filenotfoundexception-with-entity-framework-poco-and-self-tracking-entities-t4-templates.aspx#10373613</link><pubDate>Fri, 30 Nov 2012 19:37:13 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10373613</guid><dc:creator>Diego B Vega</dc:creator><description>&lt;p&gt;@Peter Doyle: yes this is fixed in the EF 5 templates for Visual Studio 2012.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10373613" width="1" height="1"&gt;</description></item><item><title>re: Wrapped System.IO.FileNotFoundException with Entity Framework POCO and Self-Tracking Entities T4 Templates</title><link>http://blogs.msdn.com/b/diego/archive/2010/04/14/wrapped-system-io-filenotfoundexception-with-entity-framework-poco-and-self-tracking-entities-t4-templates.aspx#10373076</link><pubDate>Thu, 29 Nov 2012 14:47:31 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10373076</guid><dc:creator>Peter Doyle</dc:creator><description>&lt;p&gt;But it literately 2 years later and the same bug is still there!&lt;/p&gt;
&lt;p&gt;Maybe its fixed in the 2012 VS&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10373076" width="1" height="1"&gt;</description></item><item><title>re: Stored procedures with output parameters using SqlQuery in the DbContext API</title><link>http://blogs.msdn.com/b/diego/archive/2012/01/10/how-to-execute-stored-procedures-sqlquery-in-the-dbcontext-api.aspx#10348447</link><pubDate>Tue, 11 Sep 2012 23:20:50 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10348447</guid><dc:creator>Diego B Vega</dc:creator><description>&lt;p&gt;Crob, thanks for sharing this detail. I didn&amp;#39;t test this with different versions of SQL Server so I didn&amp;#39;t hit a problem with the missing EXEC. I will add a note to the post.&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10348447" width="1" height="1"&gt;</description></item><item><title>re: Stored procedures with output parameters using SqlQuery in the DbContext API</title><link>http://blogs.msdn.com/b/diego/archive/2012/01/10/how-to-execute-stored-procedures-sqlquery-in-the-dbcontext-api.aspx#10348337</link><pubDate>Tue, 11 Sep 2012 19:13:31 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10348337</guid><dc:creator>Crob</dc:creator><description>&lt;p&gt;Found the solution here:&lt;/p&gt;
&lt;p&gt;&lt;a rel="nofollow" target="_new" href="http://stackoverflow.com/questions/6403930/what-causes-incorrect-syntax-near-stored-procedure-name-in-ef-code-first-and"&gt;stackoverflow.com/.../what-causes-incorrect-syntax-near-stored-procedure-name-in-ef-code-first-and&lt;/a&gt;&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10348337" width="1" height="1"&gt;</description></item><item><title>re: Stored procedures with output parameters using SqlQuery in the DbContext API</title><link>http://blogs.msdn.com/b/diego/archive/2012/01/10/how-to-execute-stored-procedures-sqlquery-in-the-dbcontext-api.aspx#10348315</link><pubDate>Tue, 11 Sep 2012 18:13:48 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10348315</guid><dc:creator>Crob</dc:creator><description>&lt;p&gt;I am using this against a sql2008 server and it&amp;#39;s working great for me. &amp;nbsp;I need to get the application to work against a sql2000 server but when I try it I get the exception &amp;quot;Incorrect syntax near &amp;#39;stored procedure name here&amp;#39;.&amp;quot; &amp;nbsp;If I build the query string myself without using parameters it goes through fine like below:&lt;/p&gt;
&lt;p&gt;var spResults = context.Database.SqlQuery&amp;lt;GoldmineCustomerInfo&amp;gt;(&amp;quot;spweb20_GetCustomerInfoFromGoldMine @custCode = &amp;#39;custcodevalue&amp;#39;).ToList();&lt;/p&gt;
&lt;p&gt;Do I have to tell EF this is a sql2000 server in my configuration somewhere?&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10348315" width="1" height="1"&gt;</description></item><item><title>re: Wrapped System.IO.FileNotFoundException with Entity Framework POCO and Self-Tracking Entities T4 Templates</title><link>http://blogs.msdn.com/b/diego/archive/2010/04/14/wrapped-system-io-filenotfoundexception-with-entity-framework-poco-and-self-tracking-entities-t4-templates.aspx#10336641</link><pubDate>Fri, 03 Aug 2012 16:27:53 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:10336641</guid><dc:creator>Wil Wiseman</dc:creator><description>&lt;p&gt;I thought my EF framework was hosed and was about to uninstall VS and re-install. &amp;nbsp;I didn&amp;#39;t excpect the SE to return any results when fed the exception, so applaud you thoroughness. Well done!&lt;/p&gt;
&lt;div style="clear:both;"&gt;&lt;/div&gt;&lt;img src="http://blogs.msdn.com/aggbug.aspx?PostID=10336641" width="1" height="1"&gt;</description></item></channel></rss>