Databases Reference
In-Depth Information
System Functions
The system functions are organized into these categories:
❑
Aggregation
❑
Checksum
❑
Conversion
❑
Cursor
❑
Date
❑
Image/Text
❑
Mathematical
❑
Metadata
❑
Ranking
❑
Security
❑
System
❑
System Statistics
Aggregation
Function Name
Return Type
Description
(numeric —
Calculates the arithmetic average for a range of
AVG()
depends on input)
column values. Internally, this function counts rows
and calculates the sum for all non-null values in the
column and then divides the sum by the count.
Returns the same numeric data type as the column.
Counts all non-null values for a column. The row
count is returned using
COUNT(*)
regardless of null
values.
COUNT()
Int
Same as
COUNT()
but returns a
BigInt
type rather
than an
Int
type.
COUNT_BIG()
BigInt
Used in conjunction with
ROLLUP
and
CUBE
operations in a
GROUP BY
query, this function
returns 0 to indicate that it is on a detail row and
1 to indicate a summary row.
GROUPING()
Int
(numeric or date —
Returns the largest value in a range of column
MAX()
depends on input)
values.
(numeric or date —
Returns the smallest value in a range of column
MIN()
depends on input)
values.
Table continued on following page
Search WWH ::
Custom Search