Re: HasOne relation between model with DB like datasource a model with notDB like datasource

2010-05-14 Thread Jeremy Burns
I would do two finds and merge the array afterwards. Assuming ModelA hasOne ModelB, do a find on ModelA, pick up the value of the matching id in ModelB, then do a find first on ModelB where id = $id. Jeremy Burns jeremybu...@me.com On 14 May 2010, at 12:06, marco.rizze...@gmail.com wrote: > H

HasOne relation between model with DB like datasource a model with notDB like datasource

2010-05-14 Thread marco.rizze...@gmail.com
Hi I have to define a hasOne relation between model (model A) with DB like datasource a model (model B) with datasource that isn't a DB. If I have this controller operation: pr($this->ModelA->find('all')); die(); I have noted that CakePHP products a single sql que