Hello
select array_agg(distinct mycolumn) from
from the very beginning? Even the 7.1 manual describes such a syntax: https://stream.boxwatch.ru/docs/7.1/sql-expressions.html
regards, Sergei