$ 0 0 Try using this format : - select string_agg(column_name, ' value_separator') from (select distinct column_name from table_name);