1SPI_CURSOR_FETCH(3) PostgreSQL 13.3 Documentation SPI_CURSOR_FETCH(3)
2
3
4
6 SPI_cursor_fetch - fetch some rows from a cursor
7
9 void SPI_cursor_fetch(Portal portal, bool forward, long count)
10
12 SPI_cursor_fetch fetches some rows from a cursor. This is equivalent to
13 a subset of the SQL command FETCH (see SPI_scroll_cursor_fetch for more
14 functionality).
15
17 Portal portal
18 portal containing the cursor
19
20 bool forward
21 true for fetch forward, false for fetch backward
22
23 long count
24 maximum number of rows to fetch
25
27 SPI_processed and SPI_tuptable are set as in SPI_execute if successful.
28
30 Fetching backward may fail if the cursor's plan was not created with
31 the CURSOR_OPT_SCROLL option.
32
33
34
35PostgreSQL 13.3 2021 SPI_CURSOR_FETCH(3)