postgresql array distinct values code example
Example 1: postgresql distinct
SELECT
DISTINCT bcolor
FROM
distinct_demo
ORDER BY
bcolor;
Example 2: postgresql make each element in array distinct
SELECT ARRAY(SELECT DISTINCT unnest(t_column)) FROM t_name;