Postgres module

listen

procedure · 2 overloadssince 0.27.0Source

LISTEN on a channel. The name is quoted, so any text is a channel.

listen :: (c: *Connection, channel: string) -> Pg_Error

LISTEN on a channel. The name is quoted, so any text is a channel.

Parameters

c: *Connection
the connection.
channel: string
the channel's name.

Returns

listen :: (pool: *Pool, channels: ..string) -> (*Listener, Pg_Error)

Starts a listener on channels, holding a connection from pool.

Parameters

pool: *Pool
the pool the connection is taken from and returned to.
channels: ..string
the channels to LISTEN on.

Returns

See also