Difficult to say without seeing how you're adding the contain block to your $paginate array.
On Sun, Aug 16, 2009 at 2:11 PM, Dave Maharaj :: WidePixels.com<[email protected]> wrote: > > I cant seem to get 'contain' in my pagination. > > controller: > function index() > { > $bookmarks = > $this->Bookmark->__getBookmarks($this->Auth->user('id')); > $data = $this->paginate('Bookmark', array('Bookmark.id' => $bookmarks)); > $this->set('bookmarks', $data); > } > > I need to add this: > > 'contain' => array( > 'Job' => array( > 'conditions' =>array( > 'Job.status' => 0 , > 'Job.rank <=' => $rank), > 'fields' =>array( > 'Job.title', > 'Job.rank', > 'Job.created', > SUBSTR('Job.description', 0, 50), > 'Job.id', > 'Job.quickapply') > )) > > What ever I try I end up with > SQL Error: 1054: Unknown column 'contain' in 'where clause' > > Ideas where I am going wrong? > > Thanks, > > Dave > > > > > --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "CakePHP" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---
