## 例

`

     resource pg_pconnect ( string $connection_string [, int $connect_type ] )

`

## 説明

pg_pconnect() opens a connection to a PostgreSQL database. It returns a connection resource that is needed by other PostgreSQL functions. If a second call is made to pg_pconnect() with the same connection_string as an existing connection, the existing connection will be returned unless you pass PGSQL_CONNECT_FORCE_NEW as connect_type. To enable persistent connection, the pgsql.allow_persistent php.ini directive must be set to "On" (which is the default). The maximum number of persistent connection can be defined with the pgsql.max_persistent php.ini directive (defaults to -1 for no limit). The total number of connections can be set with the pgsql.max_links php.ini directive. pg_close() will not close persistent links generated by pg_pconnect().

## 戻り値

PostgreSQL connection resource on success, FALSE on failure.