diff options
| author | Tom Lane <tgl@sss.pgh.pa.us> | 2008-11-14 19:58:45 +0000 |
|---|---|---|
| committer | Tom Lane <tgl@sss.pgh.pa.us> | 2008-11-14 19:58:45 +0000 |
| commit | 32cc9e553323c40beba4a98a5859fafe6e4e1855 (patch) | |
| tree | 016aeb2431c88f0f3ce6f115d44f2587e76f6ec3 /doc/src/sgml | |
| parent | 9e0247aba5e2cac1542823a194d4dc2ea1c3abb6 (diff) | |
Reduce contrib/intagg to a thin wrapper around the new core functions
array_agg() and unnest(). We could drop it entirely in the future,
but let's keep it for a release or two as a compatibility assist.
Diffstat (limited to 'doc/src/sgml')
| -rw-r--r-- | doc/src/sgml/intagg.sgml | 34 |
1 files changed, 9 insertions, 25 deletions
diff --git a/doc/src/sgml/intagg.sgml b/doc/src/sgml/intagg.sgml index b6f37f752cf..b33e7c62de7 100644 --- a/doc/src/sgml/intagg.sgml +++ b/doc/src/sgml/intagg.sgml @@ -1,4 +1,4 @@ -<!-- $PostgreSQL: pgsql/doc/src/sgml/intagg.sgml,v 1.3 2007/12/10 05:32:51 tgl Exp $ --> +<!-- $PostgreSQL: pgsql/doc/src/sgml/intagg.sgml,v 1.4 2008/11/14 19:58:45 tgl Exp $ --> <sect1 id="intagg"> <title>intagg</title> @@ -9,7 +9,10 @@ <para> The <filename>intagg</filename> module provides an integer aggregator and an - enumerator. + enumerator. <filename>intagg</filename> is now obsolete, because there + are built-in functions that provide a superset of its capabilities. + However, the module is still provided as a compatibility wrapper around + the built-in functions. </para> <sect2> @@ -20,38 +23,19 @@ <function>int_array_aggregate(integer)</> that produces an integer array containing exactly the integers it is fed. - Here is a not-tremendously-useful example: + This is a wrapper around <function>array_agg</>, + which does the same thing for any array type. </para> - <programlisting> -test=# select int_array_aggregate(i) from -test-# generate_series(1,10,2) i; - int_array_aggregate ---------------------- - {1,3,5,7,9} -(1 row) - </programlisting> - <para> The enumerator is a function <function>int_array_enum(integer[])</> that returns <type>setof integer</>. It is essentially the reverse operation of the aggregator: given an array of integers, expand it - into a set of rows. For example, + into a set of rows. This is a wrapper around <function>unnest</>, + which does the same thing for any array type. </para> - <programlisting> -test=# select * from int_array_enum(array[1,3,5,7,9]); - int_array_enum ----------------- - 1 - 3 - 5 - 7 - 9 -(5 rows) - </programlisting> - </sect2> <sect2> |
