<?xml version="1.0" encoding="UTF-8"?> <rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" ><channel><title>Quickduck &#187; Performance</title> <atom:link href="http://quickduck.com/blog/tag/performance/feed/" rel="self" type="application/rss+xml" /><link>http://quickduck.com/blog</link> <description>Straight from the mind of geniuseseses....</description> <lastBuildDate>Mon, 09 Jan 2012 02:29:30 +0000</lastBuildDate> <language>en</language> <sy:updatePeriod>hourly</sy:updatePeriod> <sy:updateFrequency>1</sy:updateFrequency> <generator>http://wordpress.org/?v=3.3.1</generator> <item><title>Varchar, Nvarchar and Entity Framework</title><link>http://quickduck.com/blog/2010/09/23/varchar-nvarchar-and-entity-framework/</link> <comments>http://quickduck.com/blog/2010/09/23/varchar-nvarchar-and-entity-framework/#comments</comments> <pubDate>Thu, 23 Sep 2010 01:41:29 +0000</pubDate> <dc:creator>Drew Freyling</dc:creator> <category><![CDATA[.Net]]></category> <category><![CDATA[C#]]></category> <category><![CDATA[Sql Server]]></category> <category><![CDATA[Data Access]]></category> <category><![CDATA[Performance]]></category><guid isPermaLink="false">http://quickduck.com/blog/?p=322</guid> <description><![CDATA[Further to my previous post about a bug with Entity Framework 1.0, I&#8217;ve have discovered another bug but this time due to its handling of varchars. Let&#8217;s assume we&#8217;re using the following query: If our Country column is a varchar Entity Framework will pass through our &#8220;Australia&#8221; string as an nvarchar parameter regardless of what [...]]]></description> <content:encoded><![CDATA[<div class="google_plus_one"><g:plusone size="standard" count="false" url="http://quickduck.com/blog/2010/09/23/varchar-nvarchar-and-entity-framework/"></g:plusone></div><p>Further to my <a href="http://quickduck.com/blog/2010/04/24/handling-of-nulls-in-entity-framework/">previous post</a> about a bug with Entity Framework 1.0, I&#8217;ve have discovered another bug but this time due to its handling of varchars.</p><p>Let&#8217;s assume we&#8217;re using the following query:</p><pre class="brush: plain; title: ; notranslate">
var query = context.Orders.Where(o =&gt; o.Customer.Address.Country == &quot;Australia&quot;);
</pre><p>If our Country column is a varchar  Entity Framework will pass through our &#8220;Australia&#8221; string as an nvarchar parameter regardless of what we define in our SSDL!<br /> Now has is this a bad thing you may ask? Well what this means is that even if we have an index on our country column, SQL Server will have to do an index scan rather than an index seek because it has to convert the nvarchar &#8220;Australia&#8221; down to a varchar and do the comparison across every row in the table.</p><p>Thankfully there is a <a href="http://social.msdn.microsoft.com/Forums/en-US/adodotnetentityframework/thread/d8577454-ebca-4697-80ef-73b7620e87a4">workaround</a> .</p><p>This problem has also been <a href="http://blogs.msdn.com/b/adonet/archive/2010/05/10/improvements-to-generated-sql-in-net-4-0.aspx">addressed</a> in EF 4.0 as well.</p> ]]></content:encoded> <wfw:commentRss>http://quickduck.com/blog/2010/09/23/varchar-nvarchar-and-entity-framework/feed/</wfw:commentRss> <slash:comments>0</slash:comments> </item> <item><title>Quick WPF Performance Statistics</title><link>http://quickduck.com/blog/2009/12/23/quick-wpf-performance-statistics/</link> <comments>http://quickduck.com/blog/2009/12/23/quick-wpf-performance-statistics/#comments</comments> <pubDate>Wed, 23 Dec 2009 01:15:56 +0000</pubDate> <dc:creator>Drew Freyling</dc:creator> <category><![CDATA[.Net]]></category> <category><![CDATA[C#]]></category> <category><![CDATA[Performance]]></category> <category><![CDATA[WPF]]></category><guid isPermaLink="false">http://quickduck.com/blog/?p=239</guid> <description><![CDATA[Just thought I&#8217;d put out some quick WPF performance statistics thanks to Microsoft. You can download the entire slideshow here. DependencyProperty is x3 faster than INotifyPropertyChanged ObservableCollection accesses single items 90 times faster than List ObjectDataProvider is x20 smaller than XmlDataProvider Microsoft also have some other good tips over here too. I&#8217;d like to see [...]]]></description> <content:encoded><![CDATA[<div class="google_plus_one"><g:plusone size="standard" count="false" url="http://quickduck.com/blog/2009/12/23/quick-wpf-performance-statistics/"></g:plusone></div><div>Just thought I&#8217;d put out some quick WPF performance statistics thanks to Microsoft. You can download the entire slideshow <a title="WPF Performance Best Practices" href="http://download.microsoft.com/download/B/8/8/B8813050-D289-4A78-9A27-AA4ED49BCC65/2009-03-11_TechDays_MSDN_012.pptx" target="_blank">here</a>.</div><ul><li>DependencyProperty is x3 faster than INotifyPropertyChanged</li><li>ObservableCollection accesses single items 90 times faster than List</li><li>ObjectDataProvider is x20 smaller than XmlDataProvider</li></ul><p>Microsoft also have some other good tips over <a title="WPF Performance Best Practices" href="http://msdn.microsoft.com/en-us/library/aa970683.aspx">here</a> too.<br /> I&#8217;d like to see some real world statistics on the differences between using static vs dynamic resources too. Anybody know of any?</p> ]]></content:encoded> <wfw:commentRss>http://quickduck.com/blog/2009/12/23/quick-wpf-performance-statistics/feed/</wfw:commentRss> <slash:comments>1</slash:comments> </item> </channel> </rss>
<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using disk: basic
Page Caching using disk: enhanced

Served from: quickduck.com @ 2012-02-05 16:39:12 -->
