EloquentBuilder extends Builder
UserFrosting's custom Eloquent Builder Class.
Tags
Table of Contents
withSum() | Add subselect queries to sum the relations. | self |
---|---|---|
withMax() | Add subselect queries to max the relations. | self |
withMin() | Add subselect queries to min the relations. | self |
withAvg() | Add subselect queries to min the relations. | self |
withAggregate() | use the MySQL aggregate functions including AVG COUNT, SUM, MAX and MIN. | self |
Methods
withSum()
Add subselect queries to sum the relations.
public
withSum(
$relations :
mixed
)
: self
Parameters
- $relations : mixed
Return values
selfwithMax()
Add subselect queries to max the relations.
public
withMax(
$relations :
mixed
)
: self
Parameters
- $relations : mixed
Return values
selfwithMin()
Add subselect queries to min the relations.
public
withMin(
$relations :
mixed
)
: self
Parameters
- $relations : mixed
Return values
selfwithAvg()
Add subselect queries to min the relations.
public
withAvg(
$relations :
mixed
)
: self
Parameters
- $relations : mixed
Return values
selfwithAggregate()
use the MySQL aggregate functions including AVG COUNT, SUM, MAX and MIN.
public
withAggregate(
$relations :
array
[, $function :
string
= 'COUNT' ]
)
: self
Parameters
- $relations : array
- $function : string = 'COUNT'