API16:JDatabase/setQuery
From Joomla! Documentation
Description
Sets the SQL query string for later execution.
<! removed transcluded page call, red link never existed >
Syntax
setQuery($query, $offset=0, $limit=0)
| Parameter Name | Default Value | Description |
|---|---|---|
| $query | The SQL query. | |
| $offset | 0 | The offset to start selection. |
| $limit | 0 | The number of results to return. |
Returns
object This object to support chaining.
Defined in
libraries/joomla/database/database.php
Importing
jimport( 'joomla.database.database' );
Source Body
public function setQuery($query, $offset = 0, $limit = 0)
{
$this->_sql = $query;
$this->_limit = (int) $limit;
$this->_offset = (int) $offset;
return $this;
}
<! removed transcluded page call, red link never existed >
Examples
Code Examples