SPI_SCRO...SOR_FETCH(3)
πΈ NAME πΈ
SPI_scroll_cursor_fetch β fetch some rows from a cursor. This is the SPI_SCRO...SOR_FETCH(3) page from the PostgreSQL 13.23 manual, and bestie we are getting into it.
β¨ SYNOPSIS β¨
void SPI_scroll_cursor_fetch(Portal portal, FetchDirection direction,
long count)
π DESCRIPTION π
SPI_scroll_cursor_fetch fetches some rows from a cursor. It is literally equivalent to the SQL command FETCH. Iconic behavior, no notes.
π ARGUMENTS π
Portal portalβ the portal containing the cursor.FetchDirection directionβ one ofFETCH_FORWARD,FETCH_BACKWARD,FETCH_ABSOLUTE, orFETCH_RELATIVE.long countβ number of rows to fetch forFETCH_FORWARDorFETCH_BACKWARD; absolute row number to fetch forFETCH_ABSOLUTE; or relative row number to fetch forFETCH_RELATIVE.
π«Ά RETURN VALUE π«Ά
SPI_processed and SPI_tuptable are set as in SPI_execute if successful.
π₯ NOTES π₯
See the SQL FETCH(7) command for details of the interpretation of the direction and count parameters.
Heads up, bestie: direction values other thanFETCH_FORWARDmay fail if the cursorβs plan was not created with theCURSOR_OPT_SCROLLoption. Thatβs the vibe check, so plan accordingly π
okay thatβs the page β source/version/date sign-off: PostgreSQL 13.23, 2025, SPI_SCRO...SOR_FETCH(3). bye bestie π
π¦ where this page comes from
- opensuse-leap 16.0: postgresql13-docs 13.23-160000.1.1 Β· PostgreSQL
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms