aboutsummaryrefslogtreecommitdiff
path: root/src/include/utils/array.h
diff options
context:
space:
mode:
authorTom Lane <tgl@sss.pgh.pa.us>2009-04-05 22:28:59 +0000
committerTom Lane <tgl@sss.pgh.pa.us>2009-04-05 22:28:59 +0000
commitf2110a757d0bdca766fa1b8562c7dcb1a53fd422 (patch)
tree5f3dbadfee7aa7ac8affae27881666add9e527b3 /src/include/utils/array.h
parenteb4c723e562c350f3af828ebe0e8847c79a02a69 (diff)
downloadpostgresql-f2110a757d0bdca766fa1b8562c7dcb1a53fd422.tar.gz
postgresql-f2110a757d0bdca766fa1b8562c7dcb1a53fd422.zip
Change cardinality() into a C-code function, instead of a SQL-language
alias for array_length(v,1). The efficiency gain here is doubtless negligible --- what I'm interested in is making sure that if we have second thoughts about the definition, we will not have to force a post-beta initdb to change the implementation.
Diffstat (limited to 'src/include/utils/array.h')
-rw-r--r--src/include/utils/array.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/include/utils/array.h b/src/include/utils/array.h
index 830f9145df0..f2c79a62196 100644
--- a/src/include/utils/array.h
+++ b/src/include/utils/array.h
@@ -49,7 +49,7 @@
* Portions Copyright (c) 1996-2009, PostgreSQL Global Development Group
* Portions Copyright (c) 1994, Regents of the University of California
*
- * $PostgreSQL: pgsql/src/include/utils/array.h,v 1.74 2009/01/01 17:24:02 momjian Exp $
+ * $PostgreSQL: pgsql/src/include/utils/array.h,v 1.75 2009/04/05 22:28:59 tgl Exp $
*
*-------------------------------------------------------------------------
*/
@@ -200,6 +200,7 @@ extern Datum array_dims(PG_FUNCTION_ARGS);
extern Datum array_lower(PG_FUNCTION_ARGS);
extern Datum array_upper(PG_FUNCTION_ARGS);
extern Datum array_length(PG_FUNCTION_ARGS);
+extern Datum array_cardinality(PG_FUNCTION_ARGS);
extern Datum array_larger(PG_FUNCTION_ARGS);
extern Datum array_smaller(PG_FUNCTION_ARGS);
extern Datum generate_subscripts(PG_FUNCTION_ARGS);