Docs For Class PGSQLDataListSource

## Class PGSQLDataListSource

Description

This SQLDataListSource child class interacts with

with a PostgreSQL Database using built in pg_* calls. This assumes that you have PostgreSQL support compiled into PHP

How to use? in the DataList child's get_data_source() method you pass in the result of the pg_connect() call to the constructor.

- author: Aris Basic <aris.basic@silencesoftware.com>
- author: Walter A. Boring IV <waboring@newsblob.com>

Located in /widgets/data_list/PGSQLDataListSource.inc (line 34)

    DataListSource
       |
       --SQLDataListSource
          |
          --PGSQLDataListSource

Variable Summary
mixed $_db
mixed $_result
Method Summary
PGSQLDataListSource PGSQLDataListSource (result $db)
string build_limit_clause (mixed $offset, mixed $limit)
int count (mixed $tables, [string $where_clause = ''], [mixed $count_clause = '*'], string $table)
void do_query ()
array() get_next_data_row ()
void set_db_object (object - $db)
Variables
mixed $_db = NULL (line 42)

This var holds the Database connection reference

that is used to do the sql queries It is assumed that the db is already connected to and is valid postgresi connection reference

mixed $_result = NULL (line 47)

Result of pg_query()

#### Inherited Variables

Inherited from SQLDataListSource

> SQLDataListSource::$_db_options
> SQLDataListSource::$_default_order_sensitivity
> SQLDataListSource::$_query
> SQLDataListSource::$_simple_search_case_insensitive

Inherited from DataListSource

> DataListSource::$_columns
> DataListSource::$_data
> DataListSource::$_data_index
> DataListSource::$_debug
> DataListSource::$_query_params

Methods
Constructor PGSQLDataListSource (line 56)

The constructor is used to pass in the postgres connection reference

PGSQLDataListSource PGSQLDataListSource (result $db)

- result $db: of pg_connect()

build_limit_clause (line 101)

This function builds the limit clause portion of a DB query.

- return: - the limit portion of the query.

string build_limit_clause (mixed $offset, mixed $limit)

Redefinition of:

SQLDataListSource::build_limit_clause()
  This function builds the limit clause portion of a DB query.

count (line 122)

find the number of rows to be returned from a query from a table and where clause

- return: the # of rows

int count (mixed $tables, [string $where_clause = ''], [mixed $count_clause = '*'], string $table)

- string $table: - the table to count from
- string $where_clause: - a where clause

Redefinition of:

SQLDataListSource::count()
  find the number of rows to be returned from a query from a table and where clause

do_query (line 71)
void do_query ()

Redefinition of:

SQLDataListSource::do_query()
  Do the query to the DB and pull in all of the records locally.

get_next_data_row (line 90)

This function gets the next data row from the query()

array() get_next_data_row ()

Redefinition of:

SQLDataListSource::get_next_data_row()
  This function gets the next data row from the query()

set_db_object (line 67)

Set the DB object we will use to talk to the DB.

void set_db_object (object - $db)

- object - $db: the babw_db object.

#### Inherited Methods

Inherited From SQLDataListSource

> SQLDataListSource::advanced_search_where_clause()
> SQLDataListSource::build_groupby_clause()
> SQLDataListSource::build_limit_clause()
> SQLDataListSource::build_order_clause()
> SQLDataListSource::build_query()
> SQLDataListSource::build_search_clause()
> SQLDataListSource::build_where_clause()
> SQLDataListSource::count()
> SQLDataListSource::do_prequery()
> SQLDataListSource::do_query()
> SQLDataListSource::get_count_column()
> SQLDataListSource::get_db_tables()
> SQLDataListSource::get_db_values()
> SQLDataListSource::get_default_order_case_sensitive()
> SQLDataListSource::get_next_data_row()
> SQLDataListSource::get_simple_search_case_insensitive()
> SQLDataListSource::join_clauses()
> SQLDataListSource::search_value_filter()
> SQLDataListSource::setup_db_options()
> SQLDataListSource::setup_order()
> SQLDataListSource::set_count_column()
> SQLDataListSource::set_db_groupby_clause()
> SQLDataListSource::set_db_tables()
> SQLDataListSource::set_db_values()
> SQLDataListSource::set_db_where_clause()
> SQLDataListSource::set_default_order_case_sensitive()
> SQLDataListSource::set_simple_search_case_insensitive()
> SQLDataListSource::simple_search_where_clause()
> SQLDataListSource::sql_varchar_filter()

Inherited From DataListSource

> DataListSource::DataListSource()
> DataListSource::add_column()
> DataListSource::do_prequery()
> DataListSource::do_query()
> DataListSource::get_data_index()
> DataListSource::get_limit()
> DataListSource::get_next_data_row()
> DataListSource::get_offset()
> DataListSource::get_orderby()
> DataListSource::get_reverseorder()
> DataListSource::get_searchby()
> DataListSource::get_searchby_value()
> DataListSource::get_search_type()
> DataListSource::get_secondary_orderby()
> DataListSource::get_simplesearch_modifier()
> DataListSource::get_total_rows()
> DataListSource::query()
> DataListSource::row_filter()
> DataListSource::set_debug()
> DataListSource::set_limit()
> DataListSource::set_offset()
> DataListSource::set_orderby()
> DataListSource::set_reverseorder()
> DataListSource::set_searchby()
> DataListSource::set_searchby_value()
> DataListSource::set_search_type()
> DataListSource::set_secondary_orderby()
> DataListSource::set_simplesearch_modifier()
> DataListSource::set_total_rows()
> DataListSource::sort()
> DataListSource::_is_column_sortable()

Documentation generated on Thu, 1 Sep 2005 17:06:09 -0700 by phpDocumentor 1.3.0RC3