3 PostgreSQL documentation
6 <refentry id=
"SQL-DROPAGGREGATE">
8 <refentrytitle id=
"SQL-DROPAGGREGATE-TITLE">DROP AGGREGATE
</refentrytitle>
9 <manvolnum>7</manvolnum>
10 <refmiscinfo>SQL - Language Statements
</refmiscinfo>
14 <refname>DROP AGGREGATE
</refname>
15 <refpurpose>remove an aggregate function
</refpurpose>
18 <indexterm zone=
"sql-dropaggregate">
19 <primary>DROP AGGREGATE
</primary>
24 DROP AGGREGATE [ IF EXISTS ]
<replaceable class=
"PARAMETER">name
</replaceable> (
<replaceable class=
"PARAMETER">type
</replaceable> [ , ... ] ) [ CASCADE | RESTRICT ]
29 <title>Description
</title>
32 <command>DROP AGGREGATE
</command> removes an existing
33 aggregate function. To execute this command the current
34 user must be the owner of the aggregate function.
39 <title>Parameters
</title>
44 <term><literal>IF EXISTS
</literal></term>
47 Do not throw an error if the aggregate does not exist. A notice is issued
54 <term><replaceable class=
"parameter">name
</replaceable></term>
57 The name (optionally schema-qualified) of an existing aggregate function.
63 <term><replaceable class=
"parameter">type
</replaceable></term>
66 An input data type on which the aggregate function operates.
67 To reference a zero-argument aggregate function, write
<literal>*<
/>
68 in place of the list of input data types.
74 <term><literal>CASCADE
</literal></term>
77 Automatically drop objects that depend on the aggregate function.
83 <term><literal>RESTRICT
</literal></term>
86 Refuse to drop the aggregate function if any objects depend on
87 it. This is the default.
95 <title>Examples
</title>
98 To remove the aggregate function
<literal>myavg
</literal> for type
101 DROP AGGREGATE myavg(integer);
107 <title>Compatibility
</title>
110 There is no
<command>DROP AGGREGATE
</command> statement in the SQL
116 <title>See Also
</title>
118 <simplelist type=
"inline">
119 <member><xref linkend=
"sql-alteraggregate" endterm=
"sql-alteraggregate-title"></member>
120 <member><xref linkend=
"sql-createaggregate" endterm=
"sql-createaggregate-title"></member>