__construct()
__toString()
as_assoc()
as_object()
bind()
cached()
compile()
execute()
param()
parameters()
set_connection()
type()
$_as_object
$_cache_all
$_cache_key
$_connection
$_lifetime
$_parameters
$_sql
$_type
__construct(string $sql, integer $type)
string
query string
integer
query type: DB::SELECT, DB::INSERT, etc
__toString() : string
string
as_assoc() : \Fuel\Core\Database_Query
fluent | This method is part of a fluent interface and will return the same instance |
---|
as_object(mixed $class) : \Fuel\Core\Database_Query
fluent | This method is part of a fluent interface and will return the same instance |
---|
mixed
classname or true for stdClass
bind(string $param, mixed $var) : \Fuel\Core\Database_Query
fluent | This method is part of a fluent interface and will return the same instance |
---|
string
parameter key to replace
mixed
variable to use
cached(integer $lifetime, string $cache_key, boolean $cache_all) : \Fuel\Core\Database_Query
fluent | This method is part of a fluent interface and will return the same instance |
---|
integer
number of seconds to cache or null for default
string
name of the cache key to be used or null for default
boolean
if true, cache all results, even empty ones
compile(mixed $db) : string
Replaces any parameters with their given values.
mixed
Database instance or instance name
string
execute(mixed $db) : object: mixed: integer
mixed
Database instance or name of instance
object
Database_Result for SELECT queriesmixed
the insert id for INSERT queriesinteger
number of affected rows for all other queriesparam(string $param, mixed $value) : \Fuel\Core\Database_Query
fluent | This method is part of a fluent interface and will return the same instance |
---|
string
parameter key to replace
mixed
value to use
parameters(array $params) : \Fuel\Core\Database_Query
fluent | This method is part of a fluent interface and will return the same instance |
---|
array
list of parameters
set_connection(mixed $db) : \Fuel\Core\Database_Query
fluent | This method is part of a fluent interface and will return the same instance |
---|
mixed
type() : integer
integer
$_as_object : bool
$_cache_all : boolean
$_cache_key : string
$_lifetime : int
$_parameters : array
$_sql : string
$_type : int