summaryrefslogtreecommitdiff
path: root/src/pl/plpgsql
diff options
context:
space:
mode:
authorNeil Conway2005-05-02 00:37:07 +0000
committerNeil Conway2005-05-02 00:37:07 +0000
commitf478856c7f875efceea27f30041965571815f05b (patch)
treef57db3d9edb2a059089da30aa06b4abb75a7d166 /src/pl/plpgsql
parent6c412f0605afeb809014553ff7ad28cf9ed5526b (diff)
Change SPI functions to use a `long' when specifying the number of tuples
to produce when running the executor. This is consistent with the internal executor APIs (such as ExecutorRun), which also use a long for this purpose. It also allows FETCH_ALL to be passed -- since FETCH_ALL is defined as LONG_MAX, this wouldn't have worked on platforms where int and long are of different sizes. Per report from Tzahi Fadida.
Diffstat (limited to 'src/pl/plpgsql')
-rw-r--r--src/pl/plpgsql/src/pl_exec.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/pl/plpgsql/src/pl_exec.c b/src/pl/plpgsql/src/pl_exec.c
index 71ded9da05f..1b42e8bd448 100644
--- a/src/pl/plpgsql/src/pl_exec.c
+++ b/src/pl/plpgsql/src/pl_exec.c
@@ -3,7 +3,7 @@
* procedural language
*
* IDENTIFICATION
- * $PostgreSQL: pgsql/src/pl/plpgsql/src/pl_exec.c,v 1.136 2005/05/01 18:56:19 tgl Exp $
+ * $PostgreSQL: pgsql/src/pl/plpgsql/src/pl_exec.c,v 1.137 2005/05/02 00:37:07 neilc Exp $
*
* This software is copyrighted by Jan Wieck - Hamburg.
*
@@ -158,7 +158,7 @@ static Datum exec_eval_expr(PLpgSQL_execstate *estate,
bool *isNull,
Oid *rettype);
static int exec_run_select(PLpgSQL_execstate *estate,
- PLpgSQL_expr *expr, int maxtuples, Portal *portalP);
+ PLpgSQL_expr *expr, long maxtuples, Portal *portalP);
static void exec_move_row(PLpgSQL_execstate *estate,
PLpgSQL_rec *rec,
PLpgSQL_row *row,
@@ -3482,7 +3482,7 @@ exec_eval_expr(PLpgSQL_execstate *estate,
*/
static int
exec_run_select(PLpgSQL_execstate *estate,
- PLpgSQL_expr *expr, int maxtuples, Portal *portalP)
+ PLpgSQL_expr *expr, long maxtuples, Portal *portalP)
{
int i;
Datum *values;