Analysis Services
Head
Returns the first specified number of elements in a set.
Syntax
Head(«Set»[, «Numeric Expression»])
Remarks
This function returns the first «Numeric Expression» elements in a set. The order of elements is preserved. The default value of «Numeric Expression» is 1. If «Numeric Expression» is less than 1, the empty set is returned. If «Numeric Expression» exceeds the number of tuples in the set, the original set is returned.
Example
The following example returns the set {USA, Canada, France}
:
Head({USA, Canada, France, Germany, Japan}, 3)