public function Sql::addGroupBy in Zircon Profile 8
Same name and namespace in other branches
- 8.0 core/modules/views/src/Plugin/views/query/Sql.php \Drupal\views\Plugin\views\query\Sql::addGroupBy()
Add a simple GROUP BY clause to the query. The caller is responsible for ensuring that the fields are fully qualified and the table is properly added.
1 call to Sql::addGroupBy()
- Sql::query in core/
modules/ views/ src/ Plugin/ views/ query/ Sql.php - Generate a query and a countquery from all of the information supplied to the object.
File
- core/
modules/ views/ src/ Plugin/ views/ query/ Sql.php, line 971 - Contains \Drupal\views\Plugin\views\query\Sql.
Class
- Sql
- Views query plugin for an SQL query.
Namespace
Drupal\views\Plugin\views\queryCode
public function addGroupBy($clause) {
// Only add it if it's not already in there.
if (!in_array($clause, $this->groupby)) {
$this->groupby[] = $clause;
}
}