title: How to get COUNT(*) from one partition of a table in SQL Server 2012?
body: <p>My table have 7 million records and I do split table in 14 part according to ID, each partition include 5 million record and size of partition is 40G. I want to run a query to get count in one partition but it scan all partitions and time of Query become very large.</p>
  
  <pre><code>SELECT COUNT(*) 
  FROM Item 
  WHERE IsComplated = 0 
    AND ID Between 1 AND 5000000
  </code></pre>
  
  <p>How can I run my query on one partition only without scan other partition?</p>