This post is a continuation of the SQL Server 2014 Cardinality Estimator enhancements exploration series:<\/p>\n
In previous posts for this series, I discussed how the assumption of independence with regards to multiple predicates against the same table, in absence of multi-column stats, is blunted a bit with the new Cardinality Estimator for SQL Server 2014.\u00a0 So your estimates may increase for this scenario.<\/p>\n
On the flip-side, when it comes to joins between two tables, you may see a reduction <\/em>in join estimate values for scenarios where there are non-join filter predicates on the tables being joined.<\/p>\n Take the following example, using pre-SQL Server 2014 CE behavior:<\/p>\n The SQL Sentry Plan Explorer plan tree view is as follows:<\/p>\n\r\nUSE [master]\r\nGO\r\n\r\nALTER DATABASE [Credit] SET COMPATIBILITY_LEVEL = 110\r\nGO\r\n\r\nUSE [Credit];\r\nGO\r\n\r\nSELECT\u00a0 [m].[member_no] ,\r\n[m].[lastname] ,\r\n[p].[payment_no] ,\r\n[p].[payment_dt] ,\r\n[p].[payment_amt]\r\nFROM\u00a0\u00a0\u00a0 dbo.[member] AS [m]\r\nINNER JOIN dbo.[payment] AS [p]\r\nON\u00a0\u00a0\u00a0\u00a0\u00a0 [m].[member_no] = p.[member_no]\r\nWHERE\u00a0\u00a0 [m].[region_no] = 2\r\nAND [p].[payment_dt] = '1999-09-02 00:00:00.000'\r\nOPTION\u00a0 ( RECOMPILE );\r\nGO\r\n<\/pre>\n