pg_connect_poll

Poll the status of an in-progress asynchronous PostgreSQL connection attempt

Description

int pg_connect_poll(PgSql\Connection $connection)

pg_connect_poll polls the status of a PostgreSQL connection created by calling pg_connect with the PGSQL_CONNECT_ASYNC option.

Parameters

connection

An PgSql\Connection instance.

Return Values

Returns PGSQL_POLLING_FAILED, PGSQL_POLLING_READING, PGSQL_POLLING_WRITING, PGSQL_POLLING_OK, or PGSQL_POLLING_ACTIVE.

Changelog

Version Description
8.1.0 The connection parameter expects an PgSql\Connection instance now; previously, a resource was expected.