postgresql_16:6.10.1.27.1 Description
PostgreSQL 16 > Server Programming > Server Programming Interface > Interface Functions > SPI_cursor_close > Description
SPI_cursor_close closes a previously created cursor and releases its portal storage.
All open cursors are closed automatically at the end of a transaction. SPI_cursor_close need only be invoked if it is desirable to release resources sooner.