postgresql_16:6.10.1.3.4 Notes
PostgreSQL 16 > Server Programming > Server Programming Interface > Interface Functions > SPI_execute > Notes
All SPI query-execution functions set both SPI_processed and SPI_tuptable (just the pointer, not the contents of the structure). Save these two global variables into local C function variables if you need to access the result table of SPI_execute or another query-execution function across later calls.