Firebird Documentation IndexFirebird 2.5 Language Ref. UpdateAggregate functions → LIST()
Firebird Home Firebird Home Prev: Aggregate functionsFirebird Documentation IndexUp: Aggregate functionsNext: MAX()

LIST()

Tip

Find a more recent version at Firebird 5.0 Language Reference: LIST()

Available in: DSQL, PSQL

Added in: 2.1

Changed in: 2.5

Description: LIST returns a string consisting of the non-NULL argument values in the group, separated either by a comma or by a user-supplied delimiter. If there are no non-NULL values (this includes the case where the group is empty), NULL is returned.

Result type: BLOB

Syntax: 

LIST ([ALL | DISTINCT] expression [, separator])
  • ALL (the default) results in all non-NULL values to be listed. With DISTINCT, duplicates are removed, except if expression is a BLOB.

  • In Firebird 2.5 and up, the optional separator argument may be any string expression. This makes it possible to specify e.g. ascii_char(13) as a separator. (This improvement has also been backported to 2.1.4.)

  • The expression and separator arguments support BLOBs of any size and character set.

  • Date/time and numerical arguments are implicitly converted to strings before concatenation.

  • The result is a text BLOB, except when expression is a BLOB of another subtype.

  • The ordering of the list values is undefined.

Prev: Aggregate functionsFirebird Documentation IndexUp: Aggregate functionsNext: MAX()
Firebird Documentation IndexFirebird 2.5 Language Ref. UpdateAggregate functions → LIST()