Class used to return the results of an select query.

package webkdb
author thg2oo6
copyright Copyright (c) 2012
version 1.0
access public

 Methods

Constructs the result element.

__construct(\mysqli_result $query) 

Parameters

$query

\mysqli_result

The query result.

Destructs the class and frees the result.

__destruct() 

Returns the number of the rows returned by the executed query.

num_rows() : integer

Returns

integer

Returns an array with the database results represented as objects.

result() : mixed

Returns

mixed

Returns an array with the database results represented as associative array.

result_array() : array

Returns

array

Returns a row from the select query (object).

row(\$pos $pos) : object

In case of multiple rows it returns only the first one, or the specified one.

Parameters

$pos

\$pos

Fetches the row at the specified position.

Returns

object

Returns a row from the select query (array).

row_array(\$pos $pos) : array

In case of multiple rows it returns only the first one, or the specified one.

Parameters

$pos

\$pos

Fetches the row at the specified position.

Returns

array

 Properties

 

The link with the mysql query result.

$_query : \mysqli_result