Friday, September 25, 2009

neighbors sort

Hi

Is there a way I can sort a query and then have the find (neighbors)
based on that sort?

I'm trying to sort my results by title and then would like prev/next
elements returned by neighbors to be the prev/next title in alpha
order. However, neighbors is returing the prev/next ids which are not
in alpha order.

$this->Game->find('neighbors',array
('fields'=>'Game.title','order'=>'Game.title ASC'));

Thanks!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to cake-php+unsubscribe@googlegroups.com
For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

No comments: