Index: doc/src/sgml/spi.sgml
===================================================================
RCS file: /cvsroot/pgsql-server/doc/src/sgml/spi.sgml,v
retrieving revision 1.32
diff -c -c -r1.32 spi.sgml
*** doc/src/sgml/spi.sgml 5 Mar 2004 01:00:45 -0000 1.32
--- doc/src/sgml/spi.sgml 17 Mar 2004 01:04:25 -0000
***************
*** 199,204 ****
--- 199,266 ----
+
+
+ SPI_push
+
+
+
+ SPI_push
+ pushes SPI stack to allow recursive SPI calls
+
+
+ SPI_push
+
+
+
+ void SPI_push(void)
+
+
+
+
+ Description
+
+
+ SPI_push pushes a new environment on to the
+ SPI call stack, allowing recursive calls to use a new environment.
+
+
+
+
+
+
+
+
+
+ SPI_pop
+
+
+
+ SPI_pop
+ pops SPI stack to allow recursive SPI calls
+
+
+ SPI_pop
+
+
+
+ void SPI_pop(void)
+
+
+
+
+ Description
+
+
+ SPI_pop pops the previous environment from the
+ SPI call stack. For use when returning from recursive SPI calls.
+
+
+
+
+
+
+
SPI_exec
Index: src/backend/executor/spi.c
===================================================================
RCS file: /cvsroot/pgsql-server/src/backend/executor/spi.c,v
retrieving revision 1.110
diff -c -c -r1.110 spi.c
*** src/backend/executor/spi.c 5 Mar 2004 00:47:01 -0000 1.110
--- src/backend/executor/spi.c 17 Mar 2004 01:04:27 -0000
***************
*** 201,212 ****
--- 201,214 ----
SPI_tuptable = NULL;
}
+ /* Pushes SPI stack to allow recursive SPI calls */
void
SPI_push(void)
{
_SPI_curid++;
}
+ /* Pops SPI stack to allow recursive SPI calls */
void
SPI_pop(void)
{
Index: src/include/executor/spi.h
===================================================================
RCS file: /cvsroot/pgsql-server/src/include/executor/spi.h,v
retrieving revision 1.42
diff -c -c -r1.42 spi.h
*** src/include/executor/spi.h 5 Mar 2004 00:47:01 -0000 1.42
--- src/include/executor/spi.h 17 Mar 2004 01:04:28 -0000
***************
*** 81,88 ****
extern int SPI_finish(void);
extern void SPI_push(void);
extern void SPI_pop(void);
! extern int SPI_exec(const char *src, int tcount);
! extern int SPI_execp(void *plan, Datum *values, const char *Nulls,
int tcount);
extern int SPI_execp_current(void *plan, Datum *values, const char *Nulls,
bool useCurrentSnapshot, int tcount);
--- 81,88 ----
extern int SPI_finish(void);
extern void SPI_push(void);
extern void SPI_pop(void);
! extern int SPI_exec(const char *src, int tcount);
! extern int SPI_execp(void *plan, Datum *values, const char *Nulls,
int tcount);
extern int SPI_execp_current(void *plan, Datum *values, const char *Nulls,
bool useCurrentSnapshot, int tcount);