Class n2f_database_query

Description

Core database query class for N2 Framework Yverdon.

Located in /system/classes/database.cls.php (line 215)

n2f_events
   |
   --n2f_database_query
Variable Summary
array $params
string $query
result $result
Method Summary
n2f_database_query __construct (string $sql, n2f_database &$db, [ $options = null], n2f_database $db)
n2f_database addData (mixed $key, mixed $data)
n2f_database_query addError (string $string)
n2f_database_query addParam (string $key, mixed $value, mixed $type)
string fetchError ()
array fetchErrors ()
mixed fetchInc ([ $params = null])
mixed fetchResult (integer $offset, string $field_name)
mixed fetchRow ()
mixed fetchRows ()
mixed getData (mixed $key)
boolean isError ()
integer numRows ()
Variables
n2f_database $db (line 221)

Internal reference to the global database handler.

  • access: public
array $params (line 233)

Collection of parameters for the current query.

  • access: public
string $query (line 227)

SQL string used for this query.

  • access: public
result $result (line 239)

Holds the current result set for the query if applicable.

  • access: public
array $_internalData (line 251)

Internal container for object data.

  • access: protected

Inherited Variables

Inherited from n2f_events

n2f_events::$events
Methods
Constructor __construct (line 260)

Initializes a new n2f_database_query object.

  • access: public
n2f_database_query __construct (string $sql, n2f_database &$db, [ $options = null], n2f_database $db)

Redefinition of:
n2f_events::__construct()
Initializes the n2f_events object.
addData (line 319)

Mechanism for storing data in the n2f_database_query object's internal data container.

  • access: public
n2f_database addData (mixed $key, mixed $data)
  • mixed $key
  • mixed $data
addError (line 417)

Adds an error to the n2f_database_query object's error stack.

  • access: public
n2f_database_query addError (string $string)
  • string $string
addParam (line 347)

Adds a parameter to the query stack.

  • access: public
n2f_database_query addParam (string $key, mixed $value, mixed $type)
  • string $key
  • mixed $value
  • mixed $type
addParams (line 365)

Adds an array of parameters to the query stack.

  • access: public
n2f_database_query addParams ( $params)
  • array $params
execQuery (line 396)

Executes the query.

  • access: public
n2f_database_query execQuery ()
fetchError (line 445)

Returns the last populated error string.

  • access: public
string fetchError ()
fetchErrors (line 454)

Returns the error stack.

  • access: public
array fetchErrors ()
fetchInc (line 492)

Fetches the last automatically incremented value from the query (if applicable).

  • access: public
mixed fetchInc ([ $params = null])
  • $params
fetchResult (line 483)

Fetches a specific field from the result.

  • access: public
mixed fetchResult (integer $offset, string $field_name)
  • integer $offset
  • string $field_name
fetchRow (line 463)

Fetches a single row from the result.

  • access: public
mixed fetchRow ()
fetchRows (line 472)

Fetches all rows from the result.

  • access: public
mixed fetchRows ()
getData (line 331)

Retrieves data from the n2f_database_query object's internal data container.

  • access: public
mixed getData (mixed $key)
  • mixed $key
isError (line 432)

Returns true or false based on whether or not an error has occurred.

  • access: public
boolean isError ()
numRows (line 505)

Returns the number of rows from the result.

  • access: public
integer numRows ()

Inherited Methods

Inherited From n2f_events

n2f_events::__construct()
n2f_events::addEvent()
n2f_events::hitEvent()
n2f_events::hookEvent()

Documentation generated on Sat, 23 Jan 2010 11:13:34 -0500 by phpDocumentor 1.4.1