AnewtDatabaseConnectionPostgreSQL Class Reference

PostgreSQL database connection. More...

List of all members.

Public Member Functions

 __construct ($settings)
 Create a new connection instance (internal use only).
 is_connected ()
 Check whether the connection is currently open.
 last_insert_id ($sequence=null)
 Get the last insert id for PostgreSQL by getting the current value of a sequence.
 real_execute_sql ($sql)
 Execute SQL and create an AnewtDatabaseResultSet for a query.
 escape_boolean ($value)
 Escape a boolean for use in SQL queries.
 escape_string ($value)
 Escape a string for use in SQL queries.
 escape_table_name ($value)
 Escape a table name for use in SQL queries.
 escape_column_name ($value)
 Escape a column name for use in SQL queries.

Protected Member Functions

 real_connect ()
 Establish a database connection.
 real_disconnect ()
 Disconnect the database connection.


Detailed Description

PostgreSQL database connection.

Specify postgresql as the connection type when setting up the connection using AnewtDatabase::setup_connection().

The settings accepted by this backend are:

See also:
AnewtDatabase

AnewtDatabaseConnection

Definition at line 28 of file backend-postgresql.lib.php.


Constructor & Destructor Documentation

AnewtDatabaseConnectionPostgreSQL::__construct ( settings  ) 

Create a new connection instance (internal use only).

Do not call this method directly; it is for internal use only. See the AnewtDatabase documentation on how to setup and obtain AnewtDatabaseConnection instances.

Parameters:
$settings Associative array with connection settings.

Reimplemented from AnewtDatabaseConnection.

Definition at line 30 of file backend-postgresql.lib.php.


Member Function Documentation

AnewtDatabaseConnectionPostgreSQL::is_connected (  ) 

Check whether the connection is currently open.

Returns:
True if the connection is open, false otherwise.

Reimplemented from AnewtDatabaseConnection.

Definition at line 85 of file backend-postgresql.lib.php.

AnewtDatabaseConnectionPostgreSQL::last_insert_id ( sequence = null  ) 

Get the last insert id for PostgreSQL by getting the current value of a sequence.

Parameters:
$sequence The name of the sequence.

Reimplemented from AnewtDatabaseConnection.

Definition at line 97 of file backend-postgresql.lib.php.

AnewtDatabaseConnectionPostgreSQL::real_execute_sql ( sql  ) 

Execute SQL and create an AnewtDatabaseResultSet for a query.

This method is for internal use only and is backend-specific.

Parameters:
$sql The SQL query to execute.

Reimplemented from AnewtDatabaseConnection.

Definition at line 106 of file backend-postgresql.lib.php.

AnewtDatabaseConnectionPostgreSQL::escape_boolean ( value  ) 

Escape a boolean for use in SQL queries.

Parameters:
$value The value to escape
Returns:
The escaped value

Reimplemented from AnewtDatabaseConnection.

Definition at line 120 of file backend-postgresql.lib.php.

AnewtDatabaseConnectionPostgreSQL::escape_string ( value  ) 

Escape a string for use in SQL queries.

Parameters:
$value The value to escape
Returns:
The escaped value

Reimplemented from AnewtDatabaseConnection.

Definition at line 126 of file backend-postgresql.lib.php.

AnewtDatabaseConnectionPostgreSQL::escape_table_name ( value  ) 

Escape a table name for use in SQL queries.

Parameters:
$value The value to escape
Returns:
The escaped value

Reimplemented from AnewtDatabaseConnection.

Definition at line 132 of file backend-postgresql.lib.php.

AnewtDatabaseConnectionPostgreSQL::escape_column_name ( value  ) 

Escape a column name for use in SQL queries.

Parameters:
$value The value to escape
Returns:
The escaped value

Reimplemented from AnewtDatabaseConnection.

Definition at line 155 of file backend-postgresql.lib.php.


The documentation for this class was generated from the following file:

Generated on Sun Aug 2 22:54:37 2009 for Anewt by  doxygen 1.5.9