According to PHP.net manual, pg_pconnect will create a persistent connection, or will return the existing one if it already exists with same connection string.
The problem I have is I want to know whether that call indeed creates a connection or actually returns the same, for example, for loading prepared statements in case it is the first connection.
Can it actually be possible?
UPDATE: With this question I am not referring to the current running PHP script. I want to know if the connection has been opened sometime (maybe by other scripts another time) or this script is the first in open that connection (for example, because I resetted the PostgreSQL server).