TDV Adapter for Cassandra

Build 22.0.8462

Aggregate Functions

Examples of Aggregate Functions

Below are several examples of SQL aggregate functions.

COUNT

Returns the number of rows matching the query criteria.

SELECT COUNT(*) FROM "CData"."Sample".Products WHERE Industry = 'Floppy Disks'

AVG

Returns the average of the column values.

SELECT  AVG(AnnualRevenue) FROM "CData"."Sample".Products WHERE Industry = 'Floppy Disks'

MIN

Returns the minimum column value.

SELECT MIN(AnnualRevenue) FROM "CData"."Sample".Products WHERE Industry = 'Floppy Disks'

MAX

Returns the maximum column value.

SELECT  MAX(AnnualRevenue) FROM "CData"."Sample".Products WHERE Industry = 'Floppy Disks'

SUM

Returns the total sum of the column values.

SELECT SUM(AnnualRevenue) FROM "CData"."Sample".Products WHERE Industry = 'Floppy Disks'

Copyright (c) 2023 CData Software, Inc. - All rights reserved.
Build 22.0.8462