postgresql_16:7.1.2.4 Examples
PostgreSQL 16 > Reference > SQL Commands > ALTER AGGREGATE > Examples
To rename the aggregate function myavg for type integer to my_average: ALTER AGGREGATE myavg(integer) RENAME TO my_average;
To change the owner of the aggregate function myavg for type integer to joe: ALTER AGGREGATE myavg(integer) OWNER TO joe;
To move the ordered-set aggregate mypercentile with direct argument of type float8 and aggregated argument of type integer into schema myschema: ALTER AGGREGATE mypercentile(float8 ORDER BY integer) SET SCHEMA myschema; This will work too: ALTER AGGREGATE mypercentile(float8, integer) SET SCHEMA myschema;