SQL 2005: Partition elimination

Lubor Kollar talked about an issue SQL server 2005 has for partition elimination. http://blogs.msdn.com/sqlcat/archive/2006/02/17/Partition_Elimination_in_SQL_Server_2005.aspx
He found that The partition elimination in SQL Server 2005 does not work if there is OR between the eliminating predicates and if at least one of them is parameterized at the same time.
The solution were to use UNION to remove OR/IN operator  or use Dynamic sql to remove any parameterized condition for the partitioned column.
This entry was posted in SQL server 2005. Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s