Locate a number within a range.(SQL).

      Partition (number,start,stop,interval)

   number   The number to evaluate

   start    The start of the overall range of numbers.

   stop     The end of the overall range of numbers.

   interval The interval spanned by each range.

The Partition() function can be used in an SQL query.


SELECT Count(T_Sales.ItemID) AS CountSales,
       Partition([Sale_Price],0,100000,5000) AS Pricebracket
FROM T_Sales
WHERE (T_Sales.Sale_Price>0)
GROUP BY Partition([Sale_Price],0,100000,5000); 

“Love's dominion, like a king's, admits of no partition” ~ Ovid


Avg (SQL) - Average.
Count - Count records.
Max - Return the maximum value from a query.
Min - Return the minimum value from a query.
Sum (SQL) - Add up the values in a query result set.

© Copyright 1999-2015
Some rights reserved