There was an error while loading. Please reload this page.
This method agroups rows to summarize.
public function having(string $column, string $comparator, string|int|bool|float $value): self; public function having(string $sql): self;
PHP's way:
$repository->having('COUNT(id)', '>', 1);
SQL's Representation:
HAVING COUNT(id) > 1
$repository->having('SUM(quantity) > 1000');
HAVING SUM(quantity) > 1000
🡄 Group By | Sorting 🡆
Home