Is it possible for CakePHP's Containable behavior to request an aggregate column value during a find()
? For example, in model Item
containing numeric columns quarks
and cogs
:
$this->Item->contain('quarks + cogs AS total');
Is it possible for CakePHP's Containable behavior to request an aggregate column value during a find()
? For example, in model Item
containing numeric columns quarks
and cogs
:
$this->Item->contain('quarks + cogs AS total');
Alright then...
This should work: http://stackoverflow.com/questions/1592391/cakephp-mathematic-calculation-field/1592550#1592550
:)