Skip to content

PrepareReceiver

[Source]

Receives the result of a Session.prepare() call. The session is passed to each callback so receivers can execute follow-up operations (such as executing the prepared statement) without needing to store a session reference.

interface tag PrepareReceiver

Public Behaviours

pg_statement_prepared

[Source]

Called when the server has successfully prepared a named statement.

be pg_statement_prepared(
  session: Session tag,
  name: String val)

Parameters


pg_prepare_failed

[Source]

Called when statement preparation fails. The failure is either a server error (ErrorResponseMessage) or a client-side error (ClientQueryError) such as the session being closed, not yet authenticated, or torn down after a server protocol violation (ProtocolViolation).

be pg_prepare_failed(
  session: Session tag,
  name: String val,
  failure: (ErrorResponseMessage val | ClientQueryError))

Parameters