mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-04-30 15:52:17 +09:00
Support SELECT DISTINCT queries
This commit is contained in:
parent
e3138f7278
commit
a086c93935
2 changed files with 12 additions and 0 deletions
|
|
@ -20,6 +20,7 @@ class Query extends VariableBase
|
|||
public $conditions = array();
|
||||
public $groupby = null;
|
||||
public $navigation = null;
|
||||
public $select_distinct = false;
|
||||
|
||||
/**
|
||||
* Attributes for query generation.
|
||||
|
|
@ -92,6 +93,10 @@ class Query extends VariableBase
|
|||
{
|
||||
// Initialize the query string.
|
||||
$result = 'SELECT ';
|
||||
if ($this->select_distinct)
|
||||
{
|
||||
$result .= 'DISTINCT ';
|
||||
}
|
||||
|
||||
// Compose the column list.
|
||||
$columns = array();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue