Extracted from Pike v7.6 release 61 at 2005-12-30.
pike.ida.liu.se
[Top]
Sql
Sql.postgres

Class Sql.postgres

Description

This is an interface to the Postgres (Postgres95, pgsql) database server. This module may or may not be availible on your Pike, depending whether the appropriate include and library files could be found at compile-time. Note that you do not need to have a Postgres server running on your host to use this module: you can connect to the database over a TCP/IP socket.

Note

Also note that this module uses blocking I/O I/O to connect to the server. Postgres is quite slow, and so you might want to consider this particular aspect. It is (at least should be) thread-safe, and so it can be used in a multithread environment.

The behavior of the Postgres C API also depends on certain environment variables defined in the environment of the Pike interpreter.

"PGHOST"

Sets the name of the default host to connect to. It defaults to "localhost".

"PGOPTIONS"

Sets some extra flags for the frontend-backend connection. do not set unless you're sure of what you're doing.

"PGPORT"

Sets the default port to connect to, otherwise it will use compile-time defaults (that is: the time you compiled the postgres library, not the Pike driver).

"PGTTY"

Sets the file to be used for Postgres frontend debugging. Do not use, unless you're sure of what you're doing.

"PGDATABASE"

Sets the default database to connect to.

"PGREALM"

Sets the default realm for Kerberos authentication. I never used this, so I can't help you.


Refer to the Postgres documentation for further details.

See also

Sql.Sql , Postgres.postgres , Sql.postgres_result


Inherit mo

inherit Postgres.postgres : mo


Variable version

string version

Description

Should you need to report a bug to the author, please submit along with the report the driver version number, as returned by this call.