aboutsummaryrefslogtreecommitdiff
path: root/src/include/utils/builtins.h
diff options
context:
space:
mode:
authorItagaki Takahiro <itagaki.takahiro@gmail.com>2010-02-01 03:14:45 +0000
committerItagaki Takahiro <itagaki.takahiro@gmail.com>2010-02-01 03:14:45 +0000
commit9ea9918e37689fbc9ed43532b8828652b5ea90cd (patch)
treef512d7e150549dd403f0266374d7dbcfa460d8ed /src/include/utils/builtins.h
parentee3a81f0a03d0da128689df92a84a24a337645ec (diff)
downloadpostgresql-9ea9918e37689fbc9ed43532b8828652b5ea90cd.tar.gz
postgresql-9ea9918e37689fbc9ed43532b8828652b5ea90cd.zip
Add string_agg aggregate functions. The one argument version concatenates
the input values into a string. The two argument version also does the same thing, but inserts delimiters between elements. Original patch by Pavel Stehule, reviewed by David E. Wheeler and me.
Diffstat (limited to 'src/include/utils/builtins.h')
-rw-r--r--src/include/utils/builtins.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/src/include/utils/builtins.h b/src/include/utils/builtins.h
index 11eb8acacc7..6381c3d7356 100644
--- a/src/include/utils/builtins.h
+++ b/src/include/utils/builtins.h
@@ -7,7 +7,7 @@
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/utils/builtins.h,v 1.345 2010/01/25 20:55:32 tgl Exp $
+ * $PostgreSQL: pgsql/src/include/utils/builtins.h,v 1.346 2010/02/01 03:14:45 itagaki Exp $
*
*-------------------------------------------------------------------------
*/
@@ -724,6 +724,10 @@ extern Datum unknownsend(PG_FUNCTION_ARGS);
extern Datum pg_column_size(PG_FUNCTION_ARGS);
+extern Datum string_agg_transfn(PG_FUNCTION_ARGS);
+extern Datum string_agg_delim_transfn(PG_FUNCTION_ARGS);
+extern Datum string_agg_finalfn(PG_FUNCTION_ARGS);
+
/* version.c */
extern Datum pgsql_version(PG_FUNCTION_ARGS);
@@ -772,6 +776,9 @@ extern Datum translate(PG_FUNCTION_ARGS);
extern Datum chr (PG_FUNCTION_ARGS);
extern Datum repeat(PG_FUNCTION_ARGS);
extern Datum ascii(PG_FUNCTION_ARGS);
+extern Datum string_agg_transfn(PG_FUNCTION_ARGS);
+extern Datum string_agg_delim_transfn(PG_FUNCTION_ARGS);
+extern Datum string_agg_finalfn(PG_FUNCTION_ARGS);
/* inet_net_ntop.c */
extern char *inet_net_ntop(int af, const void *src, int bits,