This section describes how to use AGGREGATE functions in Lenses SQL.
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
This page describes the AVG function in Lenses SQL.
Returns the average of the values in a group. It ignores the null value. It can be used with numeric input only.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
sample code:
Output:
This page describes the BOTTOMK function in Lenses SQL.
Returns the last K lowest ranked values. The ranking is based on how many times a value has been seen.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|
Sample code:
Output:
✓
✓
✓
✓ |
This page describes the COUNT function in Lenses SQL.
Returns the number of records returned by a query or the records in a group as a result of a GROUP BY
statement.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describe the COLLECT function in Lenses SQL.
Returns an array in which each value in the input set is assigned to an element of the array.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describes the COLLECT_UNIQUE function in Lenses SQL.
Returns an array of unique values in which each value in the input set is assigned to an element of the array.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describes the MAXK function in Lenses SQL.
Returns the N largest values of a numExpr.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describes the FIRST function in Lenses SQL.
Returns the first item seen in a group.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describes the MINK function in Lenses SQL.
Returns the N smallest values of an numExpr.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describes the LAST function in Lenses SQL.
Returns the last item seen in a group.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describes the MINK_UNIQUE function in Lenses SQL.
Returns the N smallest unique values of a numExpr.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describes the TOPK function in Lenses SQL.
Returns the K highest ranked values. The ranking is based on how many times a value has been seen.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describes the SUM function in Lenses SQL.
Returns the sum of all the values, in the expression. It can be used with numeric input only. Null values are ignored.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|---|---|
Sample code:
Output:
This page describes the MAXK_UNIQUE function in Lenses SQL.
Returns the N smallest unique values of a numExpr.
Available in:
Processor (stateless) | Processors (stateful) | SQL Studio |
---|
Sample code:
Output:
✓
✓
✓
✓
✓
✓
✓
✓
✓
✓
✓
✓
✓
✓
✓
✓
✓
✓ |