HORIZON HASKELLDocslts/ghc-9.14.x45dd5372026-10-11Search names, modules, packages, or :: a typeCtrl K

GHC 9.14.1 · lts/ghc-9.14.x · 45dd537 · 2026-10-11

Modulepostgresql-simple-0.7.0.1Haskell2010

Database.PostgreSQL.Simple.Cursor

  • 1 type
  • 4 values

Types

1 declaration
datadata Cursor
#

Cursor within a transaction.

Cursor management

2 declarations

Folding over rows from a cursor

2 declarations
valuefoldForward
  1. :: FromRow r
  2. => Cursor
  3. -> Int
  4. -> a -> r -> IO a
  5. -> a
  6. -> IO (Either a a)
#

Fold over a chunk of rows, calling the supplied fold-like function on each row as it is received. In case the cursor is exhausted, a Left value is returned, otherwise a Right value is returned.

valuefoldForwardWithParser
  1. :: Cursor
  2. -> RowParser r
  3. -> Int
  4. -> a -> r -> IO a
  5. -> a
  6. -> IO (Either a a)
#

Fold over a chunk of rows from the given cursor, calling the supplied fold-like function on each row as it is received. In case the cursor is exhausted, a Left value is returned, otherwise a Right value is returned.