Posted On: Oct 11, 2017

The LISTAGG aggregate function orders the rows for each group in a query according to the ORDER BY expression, then concatenates the values into a single string. With the new DISTINCT argument, you can now eliminate duplicate values from the specified expression before concatenating the values into a single string. For more information, see LISTAGG Function in the Amazon Redshift Database Developer Guide.

LISTAGG DISTINCT is available in all regions.