Small. Fast. Reliable.
Choose any three.

SQLite Requirement Matrix Details
lang_aggfunc.html

Index Summary Markup Original


R-00466-56349-41436-38164-40851-28282-49107-17370 tcl slt th3 src

In any aggregate function that takes a single argument, that argument can be preceded by the keyword DISTINCT.

slt/slt_lang_aggfunc.test:24   th3/req1/aggfunc01.test:11

/* IMP: R-00466-56349 */
# EVIDENCE-OF: R-00466-56349 In any aggregate function that takes a
# single argument, that argument can be preceded by the keyword
# DISTINCT.

R-00171-59428-63637-20419-61024-28048-20428-49478 tcl slt th3 src

In such cases, duplicate elements are filtered before being passed into the aggregate function.

slt/slt_lang_aggfunc.test:64   th3/req1/aggfunc01.test:15

/* IMP: R-00171-59428 */
# EVIDENCE-OF: R-00171-59428 In such cases, duplicate elements are
# filtered before being passed into the aggregate function.

R-31453-41389-40618-59449-38915-45174-40720-02932 tcl slt th3 src

For example, the function "count(distinct X)" will return the number of distinct values of column X instead of the total number of non-null values in column X.

slt/slt_lang_aggfunc.test:67   th3/req1/aggfunc01.test:18

/* IMP: R-31453-41389 */
# EVIDENCE-OF: R-31453-41389 For example, the function "count(distinct
# X)" will return the number of distinct values of column X instead of
# the total number of non-null values in column X.

R-20409-33051-08329-62436-45384-49643-45094-34288 tcl slt th3 src

The avg() function returns the average value of all non-NULL X within a group.

slt/slt_lang_aggfunc.test:83   th3/req1/aggfunc01.test:53

/* IMP: R-20409-33051 */
# EVIDENCE-OF: R-20409-33051 The avg() function returns the average
# value of all non-NULL X within a group.

R-29052-00975-25766-49663-50070-52826-19346-28533 tcl slt th3 src

String and BLOB values that do not look like numbers are interpreted as 0.

slt/slt_lang_aggfunc.test:92   th3/req1/aggfunc01.test:64

/* IMP: R-29052-00975 */
# EVIDENCE-OF: R-29052-00975 String and BLOB values that do not look
# like numbers are interpreted as 0.

R-17177-10067-30884-53677-27777-30779-31144-63091 tcl slt th3 src

The result of avg() is always a floating point value whenever there is at least one non-NULL input even if all inputs are integers.

slt/slt_lang_aggfunc.test:168   th3/req1/aggfunc01.test:76

/* IMP: R-17177-10067 */
# EVIDENCE-OF: R-17177-10067 The result of avg() is always a floating
# point value whenever there is at least one non-NULL input even if all
# inputs are integers.

R-40597-22164-08785-17254-28069-60974-16591-44156 tcl slt th3 src

The result of avg() is NULL if and only if there are no non-NULL inputs.

slt/slt_lang_aggfunc.test:184   th3/req1/aggfunc01.test:90

/* IMP: R-40597-22164 */
# EVIDENCE-OF: R-40597-22164 The result of avg() is NULL if and only if
# there are no non-NULL inputs.

R-34280-42283-63975-25394-58653-47378-35851-53437 tcl slt th3 src

The count(X) function returns a count of the number of times that X is not NULL in a group.

slt/slt_lang_aggfunc.test:198   th3/req1/aggfunc01.test:100

/* IMP: R-34280-42283 */
# EVIDENCE-OF: R-34280-42283 The count(X) function returns a count of
# the number of times that X is not NULL in a group.

R-13776-21310-53568-57098-48778-28371-47670-31301 tcl slt th3 src

The count(*) function (with no arguments) returns the total number of rows in the group.

slt/slt_lang_aggfunc.test:222   th3/req1/aggfunc01.test:103

/* IMP: R-13776-21310 */
# EVIDENCE-OF: R-13776-21310 The count(*) function (with no arguments)
# returns the total number of rows in the group.

R-56088-25150-58914-01692-09523-48299-30387-32306 tcl slt th3 src

The group_concat() function returns a string which is the concatenation of all non-NULL values of X.

slt/slt_lang_aggfunc.test:236   th3/req1/aggfunc01.test:116

/* IMP: R-56088-25150 */
# EVIDENCE-OF: R-56088-25150 The group_concat() function returns a
# string which is the concatenation of all non-NULL values of X.

R-08600-21007-59699-24141-37945-25671-33905-23052 tcl slt th3 src

If parameter Y is present then it is used as the separator between instances of X.

slt/slt_lang_aggfunc.test:250   th3/req1/aggfunc01.test:119

/* IMP: R-08600-21007 */
# EVIDENCE-OF: R-08600-21007 If parameter Y is present then it is used
# as the separator between instances of X.

R-39910-14723-21123-44064-38823-12161-58690-10248 tcl slt th3 src

A comma (",") is used as the separator if Y is omitted.

slt/slt_lang_aggfunc.test:263   th3/req1/aggfunc01.test:122

/* IMP: R-39910-14723 */
# EVIDENCE-OF: R-39910-14723 A comma (",") is used as the separator if Y
# is omitted.

R-52585-35928-11217-60344-47086-04619-13740-01929 tcl slt th3 src

The max() aggregate function returns the maximum value of all values in the group.

slt/slt_lang_aggfunc.test:277   th3/req1/aggfunc01.test:134

/* IMP: R-52585-35928 */
# EVIDENCE-OF: R-52585-35928 The max() aggregate function returns the
# maximum value of all values in the group.

R-13053-11096-22952-42489-44628-35475-18449-44243 tcl slt th3 src

The maximum value is the value that would be returned last in an ORDER BY on the same column.

slt/slt_lang_aggfunc.test:292   th3/req1/aggfunc01.test:137

/* IMP: R-13053-11096 */
# EVIDENCE-OF: R-13053-11096 The maximum value is the value that would
# be returned last in an ORDER BY on the same column.

R-50775-16353-43388-35823-42786-57944-23203-27410 tcl slt th3 src

Aggregate max() returns NULL if and only if there are no non-NULL values in the group.

slt/slt_lang_aggfunc.test:311   th3/req1/aggfunc01.test:140

/* IMP: R-50775-16353 */
# EVIDENCE-OF: R-50775-16353 Aggregate max() returns NULL if and only if
# there are no non-NULL values in the group.

R-16028-39081-19377-46684-10718-53381-04734-64750 tcl slt th3 src

The min() aggregate function returns the minimum non-NULL value of all values in the group.

slt/slt_lang_aggfunc.test:325   th3/req1/aggfunc01.test:181

/* IMP: R-16028-39081 */
# EVIDENCE-OF: R-16028-39081 The min() aggregate function returns the
# minimum non-NULL value of all values in the group.

R-30311-39793-14973-30919-34186-11921-51287-47112 tcl slt th3 src

The minimum value is the first non-NULL value that would appear in an ORDER BY of the column.

slt/slt_lang_aggfunc.test:339   th3/req1/aggfunc01.test:184

/* IMP: R-30311-39793 */
# EVIDENCE-OF: R-30311-39793 The minimum value is the first non-NULL
# value that would appear in an ORDER BY of the column.

R-10396-30188-46343-25997-25410-36538-31299-06809 tcl slt th3 src

Aggregate min() returns NULL if and only if there are no non-NULL values in the group.

slt/slt_lang_aggfunc.test:358   th3/req1/aggfunc01.test:187

/* IMP: R-10396-30188 */
# EVIDENCE-OF: R-10396-30188 Aggregate min() returns NULL if and only if
# there are no non-NULL values in the group.

R-24943-34514-22714-26526-33619-31596-02812-18143 tcl slt th3 src

The sum() and total() aggregate functions return the sum of all non-NULL values in the group.

slt/slt_lang_aggfunc.test:372   th3/req1/aggfunc01.test:216

/* IMP: R-24943-34514 */
# EVIDENCE-OF: R-24943-34514 The sum() and total() aggregate functions
# return the sum of all non-NULL values in the group.

R-44223-43966-50481-12161-32962-54841-33868-44497 tcl slt th3 src

If there are no non-NULL input rows then sum() returns NULL but total() returns 0.

slt/slt_lang_aggfunc.test:396   th3/req1/aggfunc01.test:219

/* IMP: R-44223-43966 */
# EVIDENCE-OF: R-44223-43966 If there are no non-NULL input rows then
# sum() returns NULL but total() returns 0.

R-07734-01023-35400-33877-62605-53392-63637-26399 tcl slt th3 src

The result of total() is always a floating point value.

slt/slt_lang_aggfunc.test:420   th3/req1/aggfunc01.test:246

/* IMP: R-07734-01023 */
# EVIDENCE-OF: R-07734-01023 The result of total() is always a floating
# point value.

R-19660-56479-36342-33235-14845-36400-09046-33188 tcl slt th3 src

The result of sum() is an integer value if all non-NULL inputs are integers.

slt/slt_lang_aggfunc.test:434   th3/req1/aggfunc01.test:249

/* IMP: R-19660-56479 */
# EVIDENCE-OF: R-19660-56479 The result of sum() is an integer value if
# all non-NULL inputs are integers.

R-33611-59266-40471-38425-31292-58317-36705-42935 tcl slt th3 src

If any input to sum() is neither an integer nor a NULL, then sum() returns a floating point value which is an approximation of the mathematical sum.

slt/slt_lang_aggfunc.test:448   th3/req1/aggfunc01.test:303

/* IMP: R-33611-59266 */
# EVIDENCE-OF: R-33611-59266 If any input to sum() is neither an integer
# nor a NULL, then sum() returns a floating point value which is an
# approximation of the mathematical sum.

R-08904-24719-11346-47287-22123-01310-57737-05262 tcl slt th3 src

Sum() will throw an "integer overflow" exception if all inputs are integers or NULL and an integer overflow occurs at any point during the computation.

th3/req1/aggfunc01.test:265

/* IMP: R-08904-24719 */
# EVIDENCE-OF: R-08904-24719 Sum() will throw an "integer overflow"
# exception if all inputs are integers or NULL and an integer overflow
# occurs at any point during the computation.

R-19553-64528-24132-56992-22388-20387-05422-50188 tcl slt th3 src

Total() never throws an integer overflow.

th3/req1/aggfunc01.test:269

/* IMP: R-19553-64528 */
# EVIDENCE-OF: R-19553-64528 Total() never throws an integer overflow.