__construct()
__destruct()
as_array()
cached()
count()
current()
get()
key()
next()
rewind()
sanitize()
sanitized()
unsanitize()
valid()
$_as_object
$_current_row
$_query
$_result
$_results
$_row
$_sanitization_enabled
$_total_rows
__construct(mixed $result, string $sql, mixed $as_object)
mixed
query result
string
SQL query
mixed
object
__destruct() : void
as_array(string $key, string $value) : array
// Indexed array of all rows $rows = $result->as_array();
// Associative array of rows by "id"
$rows = $result->as_array('id');
// Associative array of rows, "id" => "name"
$rows = $result->as_array('id', 'name');
string
column for associative keys
string
column for values
array
cached() : \Fuel\Core\Database_Result
count() : integer
echo count($result);
integer
current() : mixed
mixed
get(string $name, mixed $default) : mixed
// Get the "id" value $id = $result->get('id');
string
column to get
mixed
default value if the column does not exist
mixed
key() : integer
integer
next()
rewind()
sanitize() : \Fuel\Core\Database_Result
fluent | This method is part of a fluent interface and will return the same instance |
---|
sanitized() : bool
bool
unsanitize() : \Fuel\Core\Database_Result
fluent | This method is part of a fluent interface and will return the same instance |
---|
valid() : boolean
boolean
$_as_object : bool
$_current_row : int
$_query : string
$_result : resource
$_results : array
$_row : mixed
$_sanitization_enabled : bool
$_total_rows : int